create relation with holder- and contact-data, and search for contact emailAddress + relation mark #136

Merged
hsh-michaelhoennig merged 12 commits from feature/create-relation-with-holder-and-contact-data into master 2024-12-13 14:09:03 +01:00
2 changed files with 1 additions and 2 deletions
Showing only changes of commit a0560d2bfd - Show all commits

View File

@ -48,7 +48,6 @@ public class HsOfficeContactController implements HsOfficeContactsApi {
? contactRepo.findContactByEmailAddressRegEx(emailAddressRegEx) ? contactRepo.findContactByEmailAddressRegEx(emailAddressRegEx)
: contactRepo.findContactByOptionalCaptionLike(caption); : contactRepo.findContactByOptionalCaptionLike(caption);
final var resources = mapper.mapList(entities, HsOfficeContactResource.class); final var resources = mapper.mapList(entities, HsOfficeContactResource.class);
return ResponseEntity.ok(resources); return ResponseEntity.ok(resources);
} }

View File

@ -34,7 +34,7 @@ public class SubscribeExistingPersonAndContactToMailinglist extends UseCase<Subs
); );
obtain("Contact: %{subscriberEMailAddress}", () -> obtain("Contact: %{subscriberEMailAddress}", () ->
httpGet("/api/hs/office/contacts?emailAddress=%{subscriberEMailAddress}") httpGet("/api/hs/office/contacts?emailAddressRegEx=%{subscriberEMailAddress}")
.expecting(HttpStatus.OK).expecting(ContentType.JSON), .expecting(HttpStatus.OK).expecting(ContentType.JSON),
response -> response.expectArrayElements(1).getFromBody("[0].uuid"), response -> response.expectArrayElements(1).getFromBody("[0].uuid"),
"In real scenarios there are most likely multiple results and you have to choose the right one." "In real scenarios there are most likely multiple results and you have to choose the right one."