remove _CONTACT from relationship types

This commit is contained in:
Michael Hoennig 2024-01-16 15:46:56 +01:00
parent 683c2f0ce4
commit 2e609884bf
4 changed files with 10 additions and 10 deletions

View File

@ -3,6 +3,6 @@ package net.hostsharing.hsadminng.hs.office.relationship;
public enum HsOfficeRelationshipType {
UNKNOWN,
REPRESENTATIVE,
ACCOUNTING_CONTACT,
TECHNICAL_CONTACT
ACCOUNTING,
OPERATIONS
}

View File

@ -7,8 +7,8 @@ components:
type: string
enum:
- REPRESENTATIVE
- ACCOUNTING_CONTACT
- TECHNICAL_CONTACT
- ACCOUNTING
- TECHNICAL
HsOfficeRelationship:
type: object

View File

@ -4,7 +4,7 @@
--changeset hs-office-relationship-MAIN-TABLE:1 endDelimiter:--//
-- ----------------------------------------------------------------------------
CREATE TYPE HsOfficeRelationshipType AS ENUM ('UNKNOWN', 'REPRESENTATIVE', 'ACCOUNTING_CONTACT', 'TECHNICAL_CONTACT');
CREATE TYPE HsOfficeRelationshipType AS ENUM ('UNKNOWN', 'REPRESENTATIVE', 'ACCOUNTING', 'OPERATIONS');
CREATE CAST (character varying as HsOfficeRelationshipType) WITH INOUT AS IMPLICIT;

View File

@ -153,7 +153,7 @@ class HsOfficeRelationshipControllerAcceptanceTest {
"contactUuid": "%s"
}
""".formatted(
HsOfficeRelationshipTypeResource.ACCOUNTING_CONTACT,
HsOfficeRelationshipTypeResource.ACCOUNTING,
givenAnchorPerson.getUuid(),
givenHolderPerson.getUuid(),
givenContact.getUuid()))
@ -164,7 +164,7 @@ class HsOfficeRelationshipControllerAcceptanceTest {
.statusCode(201)
.contentType(ContentType.JSON)
.body("uuid", isUuidValid())
.body("relType", is("ACCOUNTING_CONTACT"))
.body("relType", is("ACCOUNTING"))
.body("relAnchor.tradeName", is("Third OHG"))
.body("relHolder.givenName", is("Paul"))
.body("contact.label", is("forth contact"))
@ -197,7 +197,7 @@ class HsOfficeRelationshipControllerAcceptanceTest {
"contactUuid": "%s"
}
""".formatted(
HsOfficeRelationshipTypeResource.ACCOUNTING_CONTACT,
HsOfficeRelationshipTypeResource.ACCOUNTING,
givenAnchorPersonUuid,
givenHolderPerson.getUuid(),
givenContact.getUuid()))
@ -230,7 +230,7 @@ class HsOfficeRelationshipControllerAcceptanceTest {
"contactUuid": "%s"
}
""".formatted(
HsOfficeRelationshipTypeResource.ACCOUNTING_CONTACT,
HsOfficeRelationshipTypeResource.ACCOUNTING,
givenAnchorPerson.getUuid(),
givenHolderPersonUuid,
givenContact.getUuid()))
@ -263,7 +263,7 @@ class HsOfficeRelationshipControllerAcceptanceTest {
"contactUuid": "%s"
}
""".formatted(
HsOfficeRelationshipTypeResource.ACCOUNTING_CONTACT,
HsOfficeRelationshipTypeResource.ACCOUNTING,
givenAnchorPerson.getUuid(),
givenHolderPerson.getUuid(),
givenContactUuid))