From 3979d53c8362df28fbac94e8850405de6c97ec6d Mon Sep 17 00:00:00 2001 From: Benedetta-fabbri Date: Mon, 20 Jan 2025 17:45:14 +0100 Subject: [PATCH] fix model of organization and openapi generated --- openapi/generated.openapi.json | 618 ++++++++---------- .../pu/organization/model/Organization.java | 13 +- 2 files changed, 285 insertions(+), 346 deletions(-) diff --git a/openapi/generated.openapi.json b/openapi/generated.openapi.json index fe7c1d9..f7dbd62 100644 --- a/openapi/generated.openapi.json +++ b/openapi/generated.openapi.json @@ -1366,156 +1366,6 @@ }, "components" : { "schemas" : { - "CollectionModelTaxonomyCodeDTO" : { - "type" : "object", - "properties" : { - "_embedded" : { - "type" : "object", - "properties" : { - "taxonomyCodeDTOes" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/TaxonomyCodeDTO" - } - } - } - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, - "TaxonomyCodeDTO" : { - "type" : "object", - "properties" : { - "organizationType" : { - "type" : "string" - }, - "organizationTypeDescription" : { - "type" : "string" - }, - "macroAreaCode" : { - "type" : "string" - }, - "macroAreaName" : { - "type" : "string" - }, - "macroAreaDescription" : { - "type" : "string" - }, - "serviceTypeCode" : { - "type" : "string" - }, - "serviceType" : { - "type" : "string" - }, - "serviceTypeDescription" : { - "type" : "string" - }, - "collectionReason" : { - "type" : "string" - }, - "taxonomyCode" : { - "type" : "string" - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, - "Links" : { - "type" : "object", - "additionalProperties" : { - "$ref" : "#/components/schemas/Link" - } - }, - "CollectionModelTaxonomyCollectionReasonDTO" : { - "type" : "object", - "properties" : { - "_embedded" : { - "type" : "object", - "properties" : { - "taxonomyCollectionReasonDTOes" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/TaxonomyCollectionReasonDTO" - } - } - } - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, - "TaxonomyCollectionReasonDTO" : { - "type" : "object", - "properties" : { - "organizationType" : { - "type" : "string" - }, - "organizationTypeDescription" : { - "type" : "string" - }, - "macroAreaCode" : { - "type" : "string" - }, - "macroAreaName" : { - "type" : "string" - }, - "macroAreaDescription" : { - "type" : "string" - }, - "serviceTypeCode" : { - "type" : "string" - }, - "serviceType" : { - "type" : "string" - }, - "serviceTypeDescription" : { - "type" : "string" - }, - "collectionReason" : { - "type" : "string" - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, - "CollectionModelTaxonomyOrganizationTypeDTO" : { - "type" : "object", - "properties" : { - "_embedded" : { - "type" : "object", - "properties" : { - "taxonomyOrganizationTypeDTOes" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/TaxonomyOrganizationTypeDTO" - } - } - } - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, - "TaxonomyOrganizationTypeDTO" : { - "type" : "object", - "properties" : { - "organizationType" : { - "type" : "string" - }, - "organizationTypeDescription" : { - "type" : "string" - }, - "_links" : { - "$ref" : "#/components/schemas/Links" - } - } - }, "AbstractJsonSchemaPropertyObject" : { "type" : "object", "properties" : { @@ -1582,6 +1432,12 @@ } } }, + "Links" : { + "type" : "object", + "additionalProperties" : { + "$ref" : "#/components/schemas/Link" + } + }, "RepresentationModelObject" : { "type" : "object", "properties" : { @@ -1590,7 +1446,33 @@ } } }, - "Taxonomy" : { + "PersonalisationFe" : { + "type" : "object", + "properties" : { + "headerAssistanceUrl" : { + "type" : "string" + }, + "logoFooterImg" : { + "type" : "string" + }, + "footerDescText" : { + "type" : "string" + }, + "footerPrivacyInfoUrl" : { + "type" : "string" + }, + "footerGDPRUrl" : { + "type" : "string" + }, + "footerTermsCondUrl" : { + "type" : "string" + }, + "footerAccessibilityUrl" : { + "type" : "string" + } + } + }, + "Broker" : { "type" : "object", "properties" : { "creationDate" : { @@ -1604,47 +1486,44 @@ "updateOperatorExternalId" : { "type" : "string" }, - "taxonomyId" : { + "brokerId" : { "type" : "integer", "format" : "int64" }, - "organizationType" : { - "type" : "string" - }, - "organizationTypeDescription" : { - "type" : "string" - }, - "macroAreaCode" : { - "type" : "string" + "organizationId" : { + "type" : "integer", + "format" : "int64" }, - "macroAreaName" : { + "brokerFiscalCode" : { "type" : "string" }, - "macroAreaDescription" : { + "brokerName" : { "type" : "string" }, - "serviceTypeCode" : { - "type" : "string" + "pagoPaInteractionModel" : { + "type" : "string", + "enum" : [ "SYNC", "SYNC_ACA", "SYNC$GPDPRELOAD", "SYNC_ACA$GPDPRELOAD", "ASYNC_GPD" ] }, - "serviceType" : { + "stationId" : { "type" : "string" }, - "serviceTypeDescription" : { + "broadcastStationId" : { "type" : "string" }, - "collectionReason" : { - "type" : "string" + "syncKey" : { + "type" : "string", + "format" : "byte" }, - "startDateValidity" : { + "gpdKey" : { "type" : "string", - "format" : "date-time" + "format" : "byte" }, - "endDateOfValidity" : { + "acaKey" : { "type" : "string", - "format" : "date-time" + "format" : "byte" }, - "taxonomyCode" : { - "type" : "string" + "personalisationFe" : { + "$ref" : "#/components/schemas/PersonalisationFe" }, "_links" : { "$ref" : "#/components/schemas/Links" @@ -1672,16 +1551,16 @@ } } }, - "PagedModelTaxonomy" : { + "PagedModelBroker" : { "type" : "object", "properties" : { "_embedded" : { "type" : "object", "properties" : { - "taxonomies" : { + "brokers" : { "type" : "array", "items" : { - "$ref" : "#/components/schemas/Taxonomy" + "$ref" : "#/components/schemas/Broker" } } } @@ -1694,6 +1573,39 @@ } } }, + "CollectionModelTaxonomyOrganizationTypeDTO" : { + "type" : "object", + "properties" : { + "_embedded" : { + "type" : "object", + "properties" : { + "taxonomyOrganizationTypeDTOes" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/TaxonomyOrganizationTypeDTO" + } + } + } + }, + "_links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "TaxonomyOrganizationTypeDTO" : { + "type" : "object", + "properties" : { + "organizationType" : { + "type" : "string" + }, + "organizationTypeDescription" : { + "type" : "string" + }, + "_links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, "Organization" : { "type" : "object", "properties" : { @@ -1724,7 +1636,7 @@ "orgTypeCode" : { "type" : "string" }, - "adminEmail" : { + "orgEmail" : { "type" : "string" }, "postalIban" : { @@ -1737,36 +1649,6 @@ "type" : "string", "format" : "byte" }, - "beneficiaryOrgName" : { - "type" : "string" - }, - "beneficiaryOrgAddress" : { - "type" : "string" - }, - "beneficiaryOrgCivic" : { - "type" : "string" - }, - "beneficiaryOrgPostalCode" : { - "type" : "string" - }, - "beneficiaryOrgLocation" : { - "type" : "string" - }, - "beneficiaryOrgProvince" : { - "type" : "string" - }, - "beneficiaryOrgNation" : { - "type" : "string" - }, - "beneficiaryOrgPhoneNumber" : { - "type" : "string" - }, - "beneficiaryOrgWebSite" : { - "type" : "string" - }, - "beneficiaryOrgEmail" : { - "type" : "string" - }, "segregationCode" : { "type" : "string" }, @@ -1791,6 +1673,10 @@ "type" : "integer", "format" : "int64" }, + "ioApiKey" : { + "type" : "string", + "format" : "byte" + }, "flagNotifyIo" : { "type" : "boolean" }, @@ -1818,9 +1704,66 @@ }, "_links" : { "$ref" : "#/components/schemas/Links" - }, - "page" : { - "$ref" : "#/components/schemas/PageMetadata" + }, + "page" : { + "$ref" : "#/components/schemas/PageMetadata" + } + } + }, + "CollectionModelTaxonomyCodeDTO" : { + "type" : "object", + "properties" : { + "_embedded" : { + "type" : "object", + "properties" : { + "taxonomyCodeDTOes" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/TaxonomyCodeDTO" + } + } + } + }, + "_links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "TaxonomyCodeDTO" : { + "type" : "object", + "properties" : { + "organizationType" : { + "type" : "string" + }, + "organizationTypeDescription" : { + "type" : "string" + }, + "macroAreaCode" : { + "type" : "string" + }, + "macroAreaName" : { + "type" : "string" + }, + "macroAreaDescription" : { + "type" : "string" + }, + "serviceTypeCode" : { + "type" : "string" + }, + "serviceType" : { + "type" : "string" + }, + "serviceTypeDescription" : { + "type" : "string" + }, + "collectionReason" : { + "type" : "string" + }, + "taxonomyCode" : { + "type" : "string" + }, + "_links" : { + "$ref" : "#/components/schemas/Links" } } }, @@ -1875,33 +1818,7 @@ } } }, - "PersonalisationFe" : { - "type" : "object", - "properties" : { - "headerAssistanceUrl" : { - "type" : "string" - }, - "logoFooterImg" : { - "type" : "string" - }, - "footerDescText" : { - "type" : "string" - }, - "footerPrivacyInfoUrl" : { - "type" : "string" - }, - "footerGDPRUrl" : { - "type" : "string" - }, - "footerTermsCondUrl" : { - "type" : "string" - }, - "footerAccessibilityUrl" : { - "type" : "string" - } - } - }, - "Broker" : { + "OrgSilService" : { "type" : "object", "properties" : { "creationDate" : { @@ -1915,7 +1832,7 @@ "updateOperatorExternalId" : { "type" : "string" }, - "brokerId" : { + "orgSilServiceId" : { "type" : "integer", "format" : "int64" }, @@ -1923,52 +1840,43 @@ "type" : "integer", "format" : "int64" }, - "brokerFiscalCode" : { + "applicationName" : { "type" : "string" }, - "brokerName" : { + "notifyOutcomePushUrl" : { "type" : "string" }, - "pagoPaInteractionModel" : { - "type" : "string", - "enum" : [ "SYNC", "SYNC_ACA", "SYNC$GPDPRELOAD", "SYNC_ACA$GPDPRELOAD", "ASYNC_GPD" ] + "flagLegacy" : { + "type" : "boolean" }, - "stationId" : { + "legacyJwtId" : { "type" : "string" }, - "broadcastStationId" : { + "legacyJwtMail" : { "type" : "string" }, - "syncKey" : { - "type" : "string", - "format" : "byte" - }, - "gpdKey" : { - "type" : "string", - "format" : "byte" + "legacyJwtSecretKeyId" : { + "type" : "string" }, - "acaKey" : { + "legacyJwtSecretKey" : { "type" : "string", "format" : "byte" }, - "personalisationFe" : { - "$ref" : "#/components/schemas/PersonalisationFe" - }, "_links" : { "$ref" : "#/components/schemas/Links" } } }, - "PagedModelBroker" : { + "PagedModelOrgSilService" : { "type" : "object", "properties" : { "_embedded" : { "type" : "object", "properties" : { - "brokers" : { + "orgSilServices" : { "type" : "array", "items" : { - "$ref" : "#/components/schemas/Broker" + "$ref" : "#/components/schemas/OrgSilService" } } } @@ -1981,99 +1889,120 @@ } } }, - "OrgSilService" : { + "CollectionModelTaxonomyCollectionReasonDTO" : { "type" : "object", "properties" : { - "creationDate" : { - "type" : "string", - "format" : "date-time" - }, - "updateDate" : { - "type" : "string", - "format" : "date-time" + "_embedded" : { + "type" : "object", + "properties" : { + "taxonomyCollectionReasonDTOes" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/TaxonomyCollectionReasonDTO" + } + } + } }, - "updateOperatorExternalId" : { + "_links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "TaxonomyCollectionReasonDTO" : { + "type" : "object", + "properties" : { + "organizationType" : { "type" : "string" }, - "orgSilServiceId" : { - "type" : "integer", - "format" : "int64" - }, - "organizationId" : { - "type" : "integer", - "format" : "int64" + "organizationTypeDescription" : { + "type" : "string" }, - "applicationName" : { + "macroAreaCode" : { "type" : "string" }, - "notifyOutcomePushUrl" : { + "macroAreaName" : { "type" : "string" }, - "flagLegacy" : { - "type" : "boolean" + "macroAreaDescription" : { + "type" : "string" }, - "legacyJwtId" : { + "serviceTypeCode" : { "type" : "string" }, - "legacyJwtMail" : { + "serviceType" : { "type" : "string" }, - "legacyJwtSecretKeyId" : { + "serviceTypeDescription" : { "type" : "string" }, - "legacyJwtSecretKey" : { - "type" : "string", - "format" : "byte" + "collectionReason" : { + "type" : "string" }, "_links" : { "$ref" : "#/components/schemas/Links" } } }, - "PagedModelOrgSilService" : { + "CollectionModelTaxonomyMacroAreaCodeDTO" : { "type" : "object", "properties" : { "_embedded" : { "type" : "object", "properties" : { - "orgSilServices" : { + "taxonomyMacroAreaCodeDTOes" : { "type" : "array", "items" : { - "$ref" : "#/components/schemas/OrgSilService" + "$ref" : "#/components/schemas/TaxonomyMacroAreaCodeDTO" } } } }, "_links" : { "$ref" : "#/components/schemas/Links" - }, - "page" : { - "$ref" : "#/components/schemas/PageMetadata" } } }, - "CollectionModelTaxonomyMacroAreaCodeDTO" : { + "TaxonomyMacroAreaCodeDTO" : { "type" : "object", "properties" : { - "_embedded" : { - "type" : "object", - "properties" : { - "taxonomyMacroAreaCodeDTOes" : { - "type" : "array", - "items" : { - "$ref" : "#/components/schemas/TaxonomyMacroAreaCodeDTO" - } - } - } + "organizationType" : { + "type" : "string" + }, + "organizationTypeDescription" : { + "type" : "string" + }, + "macroAreaCode" : { + "type" : "string" + }, + "macroAreaName" : { + "type" : "string" + }, + "macroAreaDescription" : { + "type" : "string" }, "_links" : { "$ref" : "#/components/schemas/Links" } } }, - "TaxonomyMacroAreaCodeDTO" : { + "Taxonomy" : { "type" : "object", "properties" : { + "creationDate" : { + "type" : "string", + "format" : "date-time" + }, + "updateDate" : { + "type" : "string", + "format" : "date-time" + }, + "updateOperatorExternalId" : { + "type" : "string" + }, + "taxonomyId" : { + "type" : "integer", + "format" : "int64" + }, "organizationType" : { "type" : "string" }, @@ -2089,8 +2018,53 @@ "macroAreaDescription" : { "type" : "string" }, + "serviceTypeCode" : { + "type" : "string" + }, + "serviceType" : { + "type" : "string" + }, + "serviceTypeDescription" : { + "type" : "string" + }, + "collectionReason" : { + "type" : "string" + }, + "startDateValidity" : { + "type" : "string", + "format" : "date-time" + }, + "endDateOfValidity" : { + "type" : "string", + "format" : "date-time" + }, + "taxonomyCode" : { + "type" : "string" + }, + "_links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "PagedModelTaxonomy" : { + "type" : "object", + "properties" : { + "_embedded" : { + "type" : "object", + "properties" : { + "taxonomies" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Taxonomy" + } + } + } + }, "_links" : { "$ref" : "#/components/schemas/Links" + }, + "page" : { + "$ref" : "#/components/schemas/PageMetadata" } } }, @@ -2225,7 +2199,7 @@ "orgTypeCode" : { "type" : "string" }, - "adminEmail" : { + "orgEmail" : { "type" : "string" }, "postalIban" : { @@ -2238,36 +2212,6 @@ "type" : "string", "format" : "byte" }, - "beneficiaryOrgName" : { - "type" : "string" - }, - "beneficiaryOrgAddress" : { - "type" : "string" - }, - "beneficiaryOrgCivic" : { - "type" : "string" - }, - "beneficiaryOrgPostalCode" : { - "type" : "string" - }, - "beneficiaryOrgLocation" : { - "type" : "string" - }, - "beneficiaryOrgProvince" : { - "type" : "string" - }, - "beneficiaryOrgNation" : { - "type" : "string" - }, - "beneficiaryOrgPhoneNumber" : { - "type" : "string" - }, - "beneficiaryOrgWebSite" : { - "type" : "string" - }, - "beneficiaryOrgEmail" : { - "type" : "string" - }, "segregationCode" : { "type" : "string" }, @@ -2292,6 +2236,10 @@ "type" : "integer", "format" : "int64" }, + "ioApiKey" : { + "type" : "string", + "format" : "byte" + }, "flagNotifyIo" : { "type" : "boolean" }, diff --git a/src/main/java/it/gov/pagopa/pu/organization/model/Organization.java b/src/main/java/it/gov/pagopa/pu/organization/model/Organization.java index f546954..4da9d11 100644 --- a/src/main/java/it/gov/pagopa/pu/organization/model/Organization.java +++ b/src/main/java/it/gov/pagopa/pu/organization/model/Organization.java @@ -26,20 +26,10 @@ public class Organization extends BaseEntity implements Serializable { private String orgFiscalCode; private String orgName; private String orgTypeCode; - private String adminEmail; + private String orgEmail; private String postalIban; private String iban; private byte[] password; - private String beneficiaryOrgName; - private String beneficiaryOrgAddress; - private String beneficiaryOrgCivic; - private String beneficiaryOrgPostalCode; - private String beneficiaryOrgLocation; - private String beneficiaryOrgProvince; - private String beneficiaryOrgNation; - private String beneficiaryOrgPhoneNumber; - private String beneficiaryOrgWebSite; - private String beneficiaryOrgEmail; private String segregationCode; private String cbillInterBankCode; private String orgLogo; @@ -48,6 +38,7 @@ public class Organization extends BaseEntity implements Serializable { private String additionalLanguage; private LocalDate startDate; private Long brokerId; + private byte[] ioApiKey; private boolean flagNotifyIo; private boolean flagNotifyOutcomePush;