memberNumber as partnerNumber+memberNumberSuffix #13

Merged
hsh-michaelhoennig merged 78 commits from memberNumberSuffix-and-partnerNumber into master 2024-01-24 15:57:16 +01:00
3 changed files with 24 additions and 2 deletions
Showing only changes of commit d4785b472c - Show all commits

View File

@ -22,6 +22,7 @@ class HsOfficePartnerDetailsEntityPatcher implements EntityPatcher<HsOfficePartn
OptionalFromJson.of(resource.getRegistrationOffice()).ifPresent(entity::setRegistrationOffice);
OptionalFromJson.of(resource.getRegistrationNumber()).ifPresent(entity::setRegistrationNumber);
OptionalFromJson.of(resource.getBirthday()).ifPresent(entity::setBirthday);
OptionalFromJson.of(resource.getBirthPlace()).ifPresent(entity::setBirthPlace);
OptionalFromJson.of(resource.getBirthName()).ifPresent(entity::setBirthName);
OptionalFromJson.of(resource.getDateOfDeath()).ifPresent(entity::setDateOfDeath);
}

View File

@ -32,6 +32,9 @@ components:
birthName:
type: string
nullable: true
birthPlace:
type: string
nullable: true
birthday:
type: string
format: date
@ -68,6 +71,9 @@ components:
birthName:
type: string
nullable: true
birthPlace:
type: string
nullable: true
birthday:
type: string
format: date
@ -106,6 +112,9 @@ components:
birthName:
type: string
nullable: true
birthPlace:
type: string
nullable: true
birthday:
type: string
format: date

View File

@ -28,8 +28,9 @@ class HsOfficePartnerDetailsEntityPatcherUnitTest extends PatchUnitTestBase<
> {
private static final UUID INITIAL_PARTNER_UUID = UUID.randomUUID();
private static final UUID INITIAL_CONTACT_UUID = UUID.randomUUID();
private static final UUID INITIAL_PERSON_UUID = UUID.randomUUID();
private static final String INITIAL_BIRTHPLACE = null;
private static final String PATCHED_BIRTHPLACE = "Essen (Ruhr)";
private static final LocalDate INITIAL_BIRTHDAY = LocalDate.parse("1900-01-01");
private static final LocalDate PATCHED_BIRTHDAY = LocalDate.parse("1990-12-31");
@ -54,6 +55,7 @@ class HsOfficePartnerDetailsEntityPatcherUnitTest extends PatchUnitTestBase<
entity.setUuid(INITIAL_PARTNER_UUID);
entity.setRegistrationOffice("initial Reg-Office");
entity.setRegistrationNumber("initial Reg-Number");
entity.setBirthPlace(INITIAL_BIRTHPLACE);
entity.setBirthday(INITIAL_BIRTHDAY);
entity.setBirthName("initial birth name");
entity.setDateOfDeath(INITIAL_DAY_OF_DEATH);
@ -78,6 +80,16 @@ class HsOfficePartnerDetailsEntityPatcherUnitTest extends PatchUnitTestBase<
HsOfficePartnerDetailsPatchResource::setRegistrationOffice,
"patched Reg-Office",
HsOfficePartnerDetailsEntity::setRegistrationOffice),
new JsonNullableProperty<>(
"birthplace",
HsOfficePartnerDetailsPatchResource::setBirthPlace,
PATCHED_BIRTHPLACE,
HsOfficePartnerDetailsEntity::setBirthPlace),
new JsonNullableProperty<>(
"birthname",
HsOfficePartnerDetailsPatchResource::setBirthName,
"patched birth name",
HsOfficePartnerDetailsEntity::setBirthName),
new JsonNullableProperty<>(
"birthday",
HsOfficePartnerDetailsPatchResource::setBirthday,