From 86aff14a64687caf119ce0ea1ce1e39ca9fe0962 Mon Sep 17 00:00:00 2001 From: sgiannopoulos Date: Fri, 3 May 2024 16:41:08 +0300 Subject: [PATCH] refactor namespaces --- .../AuthorizationContentResolverImpl.java | 2 +- .../DescriptionElasticBuilder.java | 8 +- .../elasticbuilder/DmpElasticBuilder.java | 2 +- .../NestedCollaboratorElasticBuilder.java | 2 +- .../NestedDescriptionElasticBuilder.java | 4 +- .../nested/NestedDmpElasticBuilder.java | 2 +- ...ityRemovalIntegrationEventHandlerImpl.java | 6 +- ...ityTouchedIntegrationEventHandlerImpl.java | 2 +- ...serRemovalIntegrationEventHandlerImpl.java | 5 - ...serTouchedIntegrationEventHandlerImpl.java | 8 +- .../org/opencdmp/model/DescriptionTag.java | 1 + .../model/DescriptionTemplateType.java | 2 +- .../model/DmpDescriptionTemplate.java | 2 + .../main/java/org/opencdmp/model/DmpUser.java | 5 +- .../main/java/org/opencdmp/model/Lock.java | 1 + .../model/PublicDescriptionTemplate.java | 7 -- .../opencdmp/model/RecentActivityItem.java | 8 +- .../model/RecentActivityItemLookup.java | 3 +- .../java/org/opencdmp/model/StorageFile.java | 1 + .../src/main/java/org/opencdmp/model/Tag.java | 3 +- .../java/org/opencdmp/model/TenantUser.java | 1 + .../org/opencdmp/model/UserContactInfo.java | 1 + .../model/UserDescriptionTemplate.java | 4 +- .../java/org/opencdmp/model/UserRole.java | 2 + .../ActionConfirmation.java | 8 +- .../model/builder/DescriptionTagBuilder.java | 3 +- .../builder/DmpAssociatedUserBuilder.java | 1 + .../DmpDescriptionTemplateBuilder.java | 25 ++-- .../model/builder/DmpUserBuilder.java | 19 +-- .../opencdmp/model/builder/LockBuilder.java | 5 +- .../model/builder/PublicDmpUserBuilder.java | 2 +- .../model/builder/PublicUserBuilder.java | 1 - .../builder/RecentActivityItemBuilder.java | 22 ++-- .../model/builder/StorageFileBuilder.java | 1 + .../opencdmp/model/builder/TagBuilder.java | 2 +- .../model/builder/TenantUserBuilder.java | 2 +- .../builder/UserAdditionalInfoBuilder.java | 18 +-- .../opencdmp/model/builder/UserBuilder.java | 37 +++--- .../model/builder/UserContactInfoBuilder.java | 5 +- .../UserDescriptionTemplateBuilder.java | 7 +- .../model/builder/UserRoleBuilder.java | 2 +- .../ActionConfirmationBuilder.java | 16 +-- .../DescriptionCommonModelBuilder.java | 4 +- .../description/FieldCommonModelBuilder.java | 2 +- .../DefinitionCommonModelBuilder.java | 1 - .../MultiplicityCommonModelBuilder.java | 1 - .../PageCommonModelBuilder.java | 2 - .../ReferenceTypeDataCommonModelBuilder.java | 13 +-- .../dmp/DmpCommonModelBuilder.java | 3 + .../ExtraFieldCommonModelBuilder.java | 4 - .../dmpblueprint/FieldCommonModelBuilder.java | 4 - .../ReferenceTypeFieldCommonModelBuilder.java | 1 - .../DescriptionBuilder.java | 40 ++++--- .../ExternalIdentifierBuilder.java | 6 +- .../FieldBuilder.java | 8 +- .../PropertyDefinitionBuilder.java | 6 +- .../PropertyDefinitionFieldSetBuilder.java | 5 +- ...PropertyDefinitionFieldSetItemBuilder.java | 8 +- .../DescriptionReferenceBuilder.java | 33 +++--- .../DefaultValueBuilder.java | 4 +- .../DefinitionBuilder.java | 4 +- .../DescriptionTemplateBuilder.java | 8 +- .../FieldBuilder.java | 4 +- .../FieldSetBuilder.java | 30 ++--- .../MultiplicityBuilder.java | 4 +- .../PageBuilder.java | 5 +- .../RuleBuilder.java | 4 +- .../SectionBuilder.java | 4 +- .../fielddata/BaseFieldDataBuilder.java | 4 +- .../LabelAndMultiplicityDataBuilder.java | 4 +- .../fielddata/LabelDataBuilder.java | 4 +- .../fielddata/RadioBoxDataBuilder.java | 4 +- .../fielddata/ReferenceTypeDataBuilder.java | 16 ++- .../fielddata/SelectDataBuilder.java | 4 +- .../fielddata/UploadDataBuilder.java | 4 +- .../DmpBlueprintValueBuilder.java | 15 ++- .../model/builder/{ => dmp}/DmpBuilder.java | 34 ++++-- .../DmpContactBuilder.java | 22 ++-- .../DmpPropertiesBuilder.java | 14 +-- .../DefinitionBuilder.java | 4 +- .../DescriptionTemplateBuilder.java | 4 +- .../DmpBlueprintBuilder.java | 6 +- .../ExtraFieldBuilder.java | 4 +- .../FieldBuilder.java | 4 +- .../ReferenceFieldBuilder.java | 18 ++- .../SectionBuilder.java | 25 ++-- .../SystemFieldBuilder.java | 4 +- .../DmpReferenceBuilder.java | 33 +++--- ...FetcherBaseSourceConfigurationBuilder.java | 18 +-- .../QueryCaseConfigBuilder.java | 18 +-- .../PrefillingSourceBuilder.java | 21 ++-- .../PrefillingSourceDefinitionBuilder.java | 16 +-- ...refillingSourceDefinitionFieldBuilder.java | 14 +-- ...ourceDefinitionFixedValueFieldBuilder.java | 14 +-- .../DefinitionBuilder.java | 14 +-- .../FieldBuilder.java | 14 +-- .../{ => reference}/ReferenceBuilder.java | 38 +++--- .../ReferenceTypeBuilder.java | 21 ++-- .../ReferenceTypeDefinitionBuilder.java | 25 ++-- .../ReferenceTypeFieldBuilder.java | 14 +-- .../UserCredentialBuilder.java | 26 ++--- .../censorship/DescriptionTagCensor.java | 2 +- .../DmpDescriptionTemplateCensor.java | 3 +- .../model/censorship/DmpUserCensor.java | 3 +- .../censorship/PublicDescriptionCensor.java | 4 - .../PublicDescriptionTemplateCensor.java | 4 - .../PublicDmpDescriptionTemplateCensor.java | 4 - .../censorship/PublicReferenceCensor.java | 5 - .../censorship/RecentActivityItemCensor.java | 2 + .../censorship/SupportiveMaterialCensor.java | 2 - .../opencdmp/model/censorship/TagCensor.java | 2 - .../censorship/UserAdditionalInfoCensor.java | 3 +- .../opencdmp/model/censorship/UserCensor.java | 3 +- .../censorship/UserContactInfoCensor.java | 1 + .../UserDescriptionTemplateCensor.java | 3 +- .../model/censorship/UserRoleCensor.java | 3 +- .../deposit/DepositConfigurationCensor.java | 3 - .../{ => description}/DescriptionCensor.java | 9 +- .../FieldCensor.java | 2 +- .../PropertyDefinitionCensor.java | 7 +- .../PropertyDefinitionFieldSetCensor.java | 5 +- .../PropertyDefinitionFieldSetItemCensor.java | 5 +- .../DescriptionReferenceCensor.java | 8 +- .../DefaultValueCensor.java | 2 +- .../DefinitionCensor.java | 4 +- .../DescriptionTemplateCensor.java | 8 +- .../FieldCensor.java | 4 +- .../FieldDataCensor.java | 3 +- .../FieldSetCensor.java | 6 +- .../MultiplicityCensor.java | 2 +- .../PageCensor.java | 5 +- .../RuleCensor.java | 2 +- .../SectionCensor.java | 4 +- .../DmpBlueprintValueCensor.java | 2 +- .../model/censorship/{ => dmp}/DmpCensor.java | 7 +- .../DmpContactCensor.java | 4 +- .../DmpPropertiesCensor.java | 4 +- .../DefinitionCensor.java | 4 +- .../DescriptionTemplatesCensor.java | 2 +- .../DmpBlueprintCensor.java | 6 +- .../FieldCensor.java | 2 +- .../SectionCensor.java | 4 +- .../DmpReferenceCensor.java | 8 +- .../PrefillingCensor.java | 3 +- .../PrefillingSourceCensor.java | 7 +- .../DefinitionCensor.java | 4 +- .../FieldCensor.java | 2 +- .../{ => reference}/ReferenceCensor.java | 9 +- .../AuthenticationConfigurationCensor.java | 2 +- .../QueryCaseConfigCensor.java | 3 +- .../QueryConfigCensor.java | 2 +- .../ReferenceTypeCensor.java | 6 +- .../ReferenceTypeDefinitionCensor.java | 4 +- .../ReferenceTypeFieldCensor.java | 2 +- ...enceTypeSourceBaseConfigurationCensor.java | 3 +- .../ReferenceTypeStaticOptionCensor.java | 3 +- ...esultFieldsMappingConfigurationCensor.java | 2 +- .../ResultsConfigurationCensor.java | 2 +- .../TenantConfigurationCensor.java | 2 - .../UserCredentialCensor.java | 7 +- .../UserCredentialDataCensor.java | 1 - .../opencdmp/model/deleter/DmpDeleter.java | 5 +- .../model/{ => description}/Description.java | 8 +- .../ExternalIdentifier.java | 2 +- .../Field.java | 4 +- .../PropertyDefinition.java | 3 +- .../PropertyDefinitionFieldSet.java | 2 +- .../PropertyDefinitionFieldSetItem.java | 4 +- .../DescriptionReference.java | 6 +- .../DefaultValue.java | 2 +- .../Definition.java | 2 +- .../DescriptionTemplate.java | 7 +- .../Field.java | 4 +- .../FieldSet.java | 2 +- .../Multiplicity.java | 6 +- .../Page.java | 2 +- .../Rule.java | 2 +- .../Section.java | 2 +- .../fielddata/BaseFieldData.java | 2 +- .../fielddata/LabelAndMultiplicityData.java | 2 +- .../fielddata/LabelData.java | 7 ++ .../fielddata/RadioBoxData.java | 2 +- .../fielddata/ReferenceTypeData.java | 6 +- .../fielddata/SelectData.java | 2 +- .../fielddata/UploadData.java | 2 +- .../fielddata/LabelData.java | 7 -- .../org/opencdmp/model/{ => dmp}/Dmp.java | 8 +- .../DmpBlueprintValue.java | 2 +- .../{dmpproperties => dmp}/DmpContact.java | 2 +- .../{dmpproperties => dmp}/DmpProperties.java | 2 +- .../Definition.java | 2 +- .../DescriptionTemplate.java | 2 +- .../{ => dmpblueprint}/DmpBlueprint.java | 4 +- .../ExtraField.java | 2 +- .../Field.java | 2 +- .../ReferenceTypeField.java | 6 +- .../Section.java | 4 +- .../SystemField.java | 2 +- .../{ => dmpreference}/DmpReference.java | 5 +- ...xternalFetcherBaseSourceConfiguration.java | 2 +- .../externalfetcher/QueryCaseConfig.java | 2 +- ...iptionFieldSetToDatasetFieldSetMapper.java | 2 +- .../DescriptionFieldToDatasetFieldMapper.java | 2 +- .../DescriptionPageToDatasetPageMapper.java | 4 +- ...criptionSectionToDatasetSectionMapper.java | 2 +- ...mplateToPublicApiDatasetProfileMapper.java | 4 +- ...iptionToPublicApiDatasetListingMapper.java | 2 +- .../DescriptionToPublicApiDatasetMapper.java | 2 +- .../DmpToPublicApiDmpListingMapper.java | 2 +- .../publicapi/DmpToPublicApiDmpMapper.java | 2 +- .../DmpBlueprintValuePersist.java | 2 +- .../PrefillingSource.java | 4 +- .../PrefillingSourceDefinition.java | 2 +- .../PrefillingSourceDefinitionField.java | 2 +- ...illingSourceDefinitionFixedValueField.java | 2 +- .../AssociatedProfilePublicModel.java | 4 +- .../DatasetProfilePublicModel.java | 3 +- .../DataRepositoryPublicModel.java | 6 +- .../ExternalDatasetPublicListingModel.java | 6 +- .../datasetwizard/RegistryPublicModel.java | 6 +- .../datasetwizard/ServicePublicModel.java | 7 +- .../grant/GrantPublicOverviewModel.java | 8 +- .../organisation/OrganizationPublicModel.java | 4 +- .../researcher/ResearcherPublicModel.java | 4 +- .../publicapi/user/UserInfoPublicModel.java | 2 +- .../Definition.java | 2 +- .../Field.java | 2 +- .../model/{ => reference}/Reference.java | 6 +- .../{ => referencetype}/ReferenceType.java | 4 +- .../ReferenceTypeDefinition.java | 2 +- .../ReferenceTypeField.java | 2 +- .../org/opencdmp/model/{ => user}/User.java | 7 +- .../model/{ => user}/UserAdditionalInfo.java | 7 +- .../{ => usercredential}/UserCredential.java | 3 +- .../query/ActionConfirmationQuery.java | 6 +- .../org/opencdmp/query/DescriptionQuery.java | 2 +- .../query/DescriptionReferenceQuery.java | 7 +- .../query/DescriptionTemplateQuery.java | 3 +- .../query/DescriptionTemplateTypeQuery.java | 4 - .../org/opencdmp/query/DmpBlueprintQuery.java | 3 +- .../java/org/opencdmp/query/DmpQuery.java | 2 +- .../org/opencdmp/query/DmpReferenceQuery.java | 2 +- .../opencdmp/query/PrefillingSourceQuery.java | 2 +- .../org/opencdmp/query/ReferenceQuery.java | 2 +- .../opencdmp/query/ReferenceTypeQuery.java | 4 +- .../opencdmp/query/UserCredentialQuery.java | 2 +- .../java/org/opencdmp/query/UserQuery.java | 2 +- .../query/lookup/ReferenceSearchLookup.java | 2 +- .../ActionConfirmationService.java | 2 +- .../ActionConfirmationServiceImpl.java | 6 +- .../dashborad/DashboardServiceImpl.java | 3 +- .../description/DescriptionService.java | 3 +- .../description/DescriptionServiceImpl.java | 7 +- .../DescriptionTemplateService.java | 2 +- .../DescriptionTemplateServiceImpl.java | 14 +-- .../org/opencdmp/service/dmp/DmpService.java | 2 +- .../opencdmp/service/dmp/DmpServiceImpl.java | 108 +++++++++--------- .../dmpblueprint/DmpBlueprintService.java | 2 +- .../dmpblueprint/DmpBlueprintServiceImpl.java | 10 +- .../elastic/ElasticQueryHelperService.java | 2 + .../ElasticQueryHelperServiceImpl.java | 16 +-- .../service/elastic/ElasticServiceImpl.java | 4 +- .../ExternalFetcherServiceImpl.java | 4 +- .../criteria/ExternalReferenceCriteria.java | 2 +- .../BaseFieldDataHelperService.java | 2 +- .../FieldDataHelperService.java | 2 +- ...AndMultiplicityFieldDataHelperService.java | 5 +- .../LabelFieldDataHelperService.java | 4 +- .../RadioBoxFieldDataHelperService.java | 7 +- .../ReferenceTypeFieldDataHelperService.java | 4 +- .../SelectFieldDataHelperService.java | 7 +- .../UploadFieldDataHelperService.java | 7 +- .../FileTransformerServiceImpl.java | 4 +- .../maintenance/MaintenanceServiceImpl.java | 2 +- .../PrefillingSourceService.java | 4 +- .../PrefillingSourceServiceImpl.java | 25 ++-- .../service/reference/ReferenceService.java | 2 +- .../reference/ReferenceServiceImpl.java | 61 +++++----- .../referencetype/ReferenceTypeService.java | 2 +- .../ReferenceTypeServiceImpl.java | 38 +++--- .../opencdmp/service/user/UserService.java | 2 +- .../service/user/UserServiceImpl.java | 4 +- .../controllers/DashboardController.java | 1 + .../controllers/DescriptionController.java | 6 +- .../DescriptionTemplateController.java | 10 +- .../controllers/DmpBlueprintController.java | 6 +- .../opencdmp/controllers/DmpController.java | 45 ++++---- .../PrefillingSourceController.java | 12 +- .../controllers/ReferenceController.java | 28 ++--- .../controllers/ReferenceTypeController.java | 30 ++--- .../opencdmp/controllers/UserController.java | 2 +- ...ublicDatasetsDescriptionDocumentation.java | 16 ++- .../publicapi/PublicDmpsDocumentation.java | 92 +++++++-------- .../interceptors/user/UserInterceptor.java | 3 +- 294 files changed, 1029 insertions(+), 1069 deletions(-) rename backend/core/src/main/java/org/opencdmp/model/{ => actionconfirmation}/ActionConfirmation.java (89%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => actionconfirmation}/ActionConfirmationBuilder.java (92%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => descriptionproperties}/DescriptionBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptionpropertiesdefinition => descriptionproperties}/ExternalIdentifierBuilder.java (91%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptionpropertiesdefinition => descriptionproperties}/FieldBuilder.java (97%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptionpropertiesdefinition => descriptionproperties}/PropertyDefinitionBuilder.java (92%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptionpropertiesdefinition => descriptionproperties}/PropertyDefinitionFieldSetBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptionpropertiesdefinition => descriptionproperties}/PropertyDefinitionFieldSetItemBuilder.java (90%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => descriptionreference}/DescriptionReferenceBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/DefaultValueBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/DefinitionBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => descriptiontemplate}/DescriptionTemplateBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/FieldBuilder.java (97%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/FieldSetBuilder.java (67%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/MultiplicityBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/PageBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/RuleBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/SectionBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/BaseFieldDataBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/LabelAndMultiplicityDataBuilder.java (88%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/LabelDataBuilder.java (86%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/RadioBoxDataBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/ReferenceTypeDataBuilder.java (81%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/SelectDataBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/UploadDataBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpproperties => dmp}/DmpBlueprintValueBuilder.java (92%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => dmp}/DmpBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpproperties => dmp}/DmpContactBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpproperties => dmp}/DmpPropertiesBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/DefinitionBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/DescriptionTemplateBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => dmpblueprint}/DmpBlueprintBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/ExtraFieldBuilder.java (90%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/FieldBuilder.java (96%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/ReferenceFieldBuilder.java (81%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/SectionBuilder.java (91%) rename backend/core/src/main/java/org/opencdmp/model/builder/{dmpblueprintdefinition => dmpblueprint}/SystemFieldBuilder.java (90%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => dmpreference}/DmpReferenceBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => prefillingsource}/PrefillingSourceBuilder.java (92%) rename backend/core/src/main/java/org/opencdmp/model/builder/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinitionBuilder.java (95%) rename backend/core/src/main/java/org/opencdmp/model/builder/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinitionFieldBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinitionFixedValueFieldBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{referencedefinition => reference}/DefinitionBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{referencedefinition => reference}/FieldBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => reference}/ReferenceBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => referencetype}/ReferenceTypeBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{referencetypedefinition => referencetype}/ReferenceTypeDefinitionBuilder.java (94%) rename backend/core/src/main/java/org/opencdmp/model/builder/{referencetypedefinition => referencetype}/ReferenceTypeFieldBuilder.java (93%) rename backend/core/src/main/java/org/opencdmp/model/builder/{ => usercredential}/UserCredentialBuilder.java (92%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => description}/DescriptionCensor.java (89%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptionproperties => description}/FieldCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptionproperties => description}/PropertyDefinitionCensor.java (86%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptionproperties => description}/PropertyDefinitionFieldSetCensor.java (90%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptionproperties => description}/PropertyDefinitionFieldSetItemCensor.java (90%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => descriptionreference}/DescriptionReferenceCensor.java (87%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/DefaultValueCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/DefinitionCensor.java (92%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => descriptiontemplate}/DescriptionTemplateCensor.java (87%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/FieldCensor.java (94%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/FieldDataCensor.java (91%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/FieldSetCensor.java (88%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/MultiplicityCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/PageCensor.java (89%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/RuleCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{descriptiontemplatedefinition => descriptiontemplate}/SectionCensor.java (92%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpproperties => dmp}/DmpBlueprintValueCensor.java (96%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => dmp}/DmpCensor.java (92%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpproperties => dmp}/DmpContactCensor.java (94%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpproperties => dmp}/DmpPropertiesCensor.java (94%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpblueprintdefinition => dmpblueprint}/DefinitionCensor.java (93%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpblueprintdefinition => dmpblueprint}/DescriptionTemplatesCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => dmpblueprint}/DmpBlueprintCensor.java (91%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpblueprintdefinition => dmpblueprint}/FieldCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{dmpblueprintdefinition => dmpblueprint}/SectionCensor.java (94%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => dmpreference}/DmpReferenceCensor.java (88%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => prefillingsource}/PrefillingCensor.java (93%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => prefillingsource}/PrefillingSourceCensor.java (87%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencedefinition => reference}/DefinitionCensor.java (93%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencedefinition => reference}/FieldCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => reference}/ReferenceCensor.java (87%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/AuthenticationConfigurationCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/QueryCaseConfigCensor.java (93%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/QueryConfigCensor.java (96%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => referencetype}/ReferenceTypeCensor.java (91%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ReferenceTypeDefinitionCensor.java (93%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ReferenceTypeFieldCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ReferenceTypeSourceBaseConfigurationCensor.java (96%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ReferenceTypeStaticOptionCensor.java (92%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ResultFieldsMappingConfigurationCensor.java (95%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{referencetypedefinition => referencetype}/ResultsConfigurationCensor.java (96%) rename backend/core/src/main/java/org/opencdmp/model/censorship/{ => usercredential}/UserCredentialCensor.java (89%) rename backend/core/src/main/java/org/opencdmp/model/{ => description}/Description.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{descriptionproperties => description}/ExternalIdentifier.java (89%) rename backend/core/src/main/java/org/opencdmp/model/{descriptionproperties => description}/Field.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{descriptionproperties => description}/PropertyDefinition.java (83%) rename backend/core/src/main/java/org/opencdmp/model/{descriptionproperties => description}/PropertyDefinitionFieldSet.java (87%) rename backend/core/src/main/java/org/opencdmp/model/{descriptionproperties => description}/PropertyDefinitionFieldSetItem.java (86%) rename backend/core/src/main/java/org/opencdmp/model/{ => descriptionreference}/DescriptionReference.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/DefaultValue.java (92%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Definition.java (80%) rename backend/core/src/main/java/org/opencdmp/model/{ => descriptiontemplate}/DescriptionTemplate.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Field.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/FieldSet.java (97%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Multiplicity.java (85%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Page.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Rule.java (94%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/Section.java (96%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/BaseFieldData.java (87%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/LabelAndMultiplicityData.java (82%) create mode 100644 backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelData.java rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/RadioBoxData.java (91%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/ReferenceTypeData.java (81%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/SelectData.java (92%) rename backend/core/src/main/java/org/opencdmp/model/{descriptiontemplatedefinition => descriptiontemplate}/fielddata/UploadData.java (93%) delete mode 100644 backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelData.java rename backend/core/src/main/java/org/opencdmp/model/{ => dmp}/Dmp.java (96%) rename backend/core/src/main/java/org/opencdmp/model/{dmpproperties => dmp}/DmpBlueprintValue.java (92%) rename backend/core/src/main/java/org/opencdmp/model/{dmpproperties => dmp}/DmpContact.java (96%) rename backend/core/src/main/java/org/opencdmp/model/{dmpproperties => dmp}/DmpProperties.java (94%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/Definition.java (84%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/DescriptionTemplate.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{ => dmpblueprint}/DmpBlueprint.java (97%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/ExtraField.java (88%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/Field.java (97%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/ReferenceTypeField.java (83%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/Section.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{dmpblueprintdefinition => dmpblueprint}/SystemField.java (89%) rename backend/core/src/main/java/org/opencdmp/model/{ => dmpreference}/DmpReference.java (94%) rename backend/core/src/main/java/org/opencdmp/model/{ => prefillingsource}/PrefillingSource.java (94%) rename backend/core/src/main/java/org/opencdmp/model/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinition.java (96%) rename backend/core/src/main/java/org/opencdmp/model/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinitionField.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{prefillingsourcedefinition => prefillingsource}/PrefillingSourceDefinitionFixedValueField.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{referencedefinition => reference}/Definition.java (84%) rename backend/core/src/main/java/org/opencdmp/model/{referencedefinition => reference}/Field.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{ => reference}/Reference.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{ => referencetype}/ReferenceType.java (95%) rename backend/core/src/main/java/org/opencdmp/model/{referencetypedefinition => referencetype}/ReferenceTypeDefinition.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{referencetypedefinition => referencetype}/ReferenceTypeField.java (94%) rename backend/core/src/main/java/org/opencdmp/model/{ => user}/User.java (93%) rename backend/core/src/main/java/org/opencdmp/model/{ => user}/UserAdditionalInfo.java (91%) rename backend/core/src/main/java/org/opencdmp/model/{ => usercredential}/UserCredential.java (93%) diff --git a/backend/core/src/main/java/org/opencdmp/authorization/authorizationcontentresolver/AuthorizationContentResolverImpl.java b/backend/core/src/main/java/org/opencdmp/authorization/authorizationcontentresolver/AuthorizationContentResolverImpl.java index 7f28686f9..2b770cea6 100644 --- a/backend/core/src/main/java/org/opencdmp/authorization/authorizationcontentresolver/AuthorizationContentResolverImpl.java +++ b/backend/core/src/main/java/org/opencdmp/authorization/authorizationcontentresolver/AuthorizationContentResolverImpl.java @@ -9,7 +9,7 @@ import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DmpDescriptionTemplateEntity; import org.opencdmp.data.DmpEntity; import org.opencdmp.data.DmpUserEntity; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.DmpDescriptionTemplate; import org.opencdmp.model.DmpUser; import org.opencdmp.query.DescriptionQuery; diff --git a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DescriptionElasticBuilder.java b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DescriptionElasticBuilder.java index 1b958fbab..62aab6ad6 100644 --- a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DescriptionElasticBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DescriptionElasticBuilder.java @@ -5,7 +5,6 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DescriptionReferenceEntity; import org.opencdmp.data.DescriptionTagEntity; -import org.opencdmp.data.DmpDescriptionTemplateEntity; import org.opencdmp.elastic.data.DescriptionElasticEntity; import org.opencdmp.elastic.data.nested.*; import org.opencdmp.elastic.elasticbuilder.nested.NestedDescriptionTemplateElasticBuilder; @@ -13,14 +12,13 @@ import org.opencdmp.elastic.elasticbuilder.nested.NestedDmpElasticBuilder; import org.opencdmp.elastic.elasticbuilder.nested.NestedReferenceElasticBuilder; import org.opencdmp.elastic.elasticbuilder.nested.NestedTagElasticBuilder; import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionBuilder; -import org.opencdmp.model.builder.ReferenceBuilder; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.query.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.BaseFieldSet; -import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; diff --git a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DmpElasticBuilder.java b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DmpElasticBuilder.java index abc3d8dec..013ced316 100644 --- a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DmpElasticBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/DmpElasticBuilder.java @@ -6,7 +6,7 @@ import org.opencdmp.data.*; import org.opencdmp.elastic.data.DmpElasticEntity; import org.opencdmp.elastic.data.nested.*; import org.opencdmp.elastic.elasticbuilder.nested.*; -import org.opencdmp.model.DmpReference; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.query.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedCollaboratorElasticBuilder.java b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedCollaboratorElasticBuilder.java index f7f9a07e7..a43f08b0e 100644 --- a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedCollaboratorElasticBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedCollaboratorElasticBuilder.java @@ -10,7 +10,7 @@ import org.opencdmp.data.DmpUserEntity; import org.opencdmp.data.UserEntity; import org.opencdmp.elastic.data.nested.NestedCollaboratorElasticEntity; import org.opencdmp.elastic.elasticbuilder.BaseElasticBuilder; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.UserQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; diff --git a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDescriptionElasticBuilder.java b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDescriptionElasticBuilder.java index 43afba1cc..1e0d28269 100644 --- a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDescriptionElasticBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDescriptionElasticBuilder.java @@ -10,9 +10,9 @@ import org.opencdmp.elastic.data.nested.NestedDescriptionTemplateElasticEntity; import org.opencdmp.elastic.data.nested.NestedReferenceElasticEntity; import org.opencdmp.elastic.data.nested.NestedTagElasticEntity; import org.opencdmp.elastic.elasticbuilder.BaseElasticBuilder; -import org.opencdmp.model.DescriptionReference; +import org.opencdmp.model.descriptionreference.DescriptionReference; import org.opencdmp.model.DescriptionTag; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.query.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDmpElasticBuilder.java b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDmpElasticBuilder.java index 044e5f288..d7a7b6583 100644 --- a/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDmpElasticBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/elastic/elasticbuilder/nested/NestedDmpElasticBuilder.java @@ -8,7 +8,7 @@ import org.opencdmp.data.DmpUserEntity; import org.opencdmp.data.EntityDoiEntity; import org.opencdmp.elastic.data.nested.*; import org.opencdmp.elastic.elasticbuilder.BaseElasticBuilder; -import org.opencdmp.model.DmpReference; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.query.DmpReferenceQuery; import org.opencdmp.query.DmpUserQuery; import org.opencdmp.query.EntityDoiQuery; diff --git a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentityremoval/AnnotationEntityRemovalIntegrationEventHandlerImpl.java b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentityremoval/AnnotationEntityRemovalIntegrationEventHandlerImpl.java index 99d7594c8..73f8e73c5 100644 --- a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentityremoval/AnnotationEntityRemovalIntegrationEventHandlerImpl.java +++ b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentityremoval/AnnotationEntityRemovalIntegrationEventHandlerImpl.java @@ -1,15 +1,11 @@ package org.opencdmp.integrationevent.outbox.annotationentityremoval; -import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.data.DescriptionEntity; -import org.opencdmp.data.DmpUserEntity; import org.opencdmp.integrationevent.outbox.OutboxIntegrationEvent; import org.opencdmp.integrationevent.outbox.OutboxService; -import org.opencdmp.model.Description; -import org.opencdmp.model.DmpUser; +import org.opencdmp.model.description.Description; import org.opencdmp.query.DescriptionQuery; -import org.opencdmp.query.DmpUserQuery; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentitytouch/AnnotationEntityTouchedIntegrationEventHandlerImpl.java b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentitytouch/AnnotationEntityTouchedIntegrationEventHandlerImpl.java index 374734e3b..c6044cb11 100644 --- a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentitytouch/AnnotationEntityTouchedIntegrationEventHandlerImpl.java +++ b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/annotationentitytouch/AnnotationEntityTouchedIntegrationEventHandlerImpl.java @@ -5,7 +5,7 @@ import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DmpUserEntity; import org.opencdmp.integrationevent.outbox.OutboxIntegrationEvent; import org.opencdmp.integrationevent.outbox.OutboxService; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.DmpUser; import org.opencdmp.query.DescriptionQuery; import org.opencdmp.query.DmpUserQuery; diff --git a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/userremoval/UserRemovalIntegrationEventHandlerImpl.java b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/userremoval/UserRemovalIntegrationEventHandlerImpl.java index 7bcdd904c..dc0a65b33 100644 --- a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/userremoval/UserRemovalIntegrationEventHandlerImpl.java +++ b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/userremoval/UserRemovalIntegrationEventHandlerImpl.java @@ -1,13 +1,8 @@ package org.opencdmp.integrationevent.outbox.userremoval; import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.data.UserEntity; import org.opencdmp.integrationevent.outbox.OutboxIntegrationEvent; import org.opencdmp.integrationevent.outbox.OutboxService; -import org.opencdmp.integrationevent.outbox.usertouched.UserTouchedIntegrationEvent; -import org.opencdmp.model.User; -import org.opencdmp.query.UserQuery; -import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/usertouched/UserTouchedIntegrationEventHandlerImpl.java b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/usertouched/UserTouchedIntegrationEventHandlerImpl.java index 701fa7606..6c425621d 100644 --- a/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/usertouched/UserTouchedIntegrationEventHandlerImpl.java +++ b/backend/core/src/main/java/org/opencdmp/integrationevent/outbox/usertouched/UserTouchedIntegrationEventHandlerImpl.java @@ -4,15 +4,12 @@ import org.opencdmp.commons.JsonHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.user.AdditionalInfoEntity; import org.opencdmp.data.*; -import org.opencdmp.elastic.data.DmpElasticEntity; -import org.opencdmp.elastic.elasticbuilder.DmpElasticBuilder; import org.opencdmp.integrationevent.outbox.OutboxIntegrationEvent; import org.opencdmp.integrationevent.outbox.OutboxService; import org.opencdmp.model.*; -import org.opencdmp.model.builder.UserAdditionalInfoBuilder; +import org.opencdmp.model.user.User; +import org.opencdmp.model.usercredential.UserCredential; import org.opencdmp.query.*; -import gr.cite.tools.data.query.Ordering; -import gr.cite.tools.data.query.Paging; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyNotFoundException; import gr.cite.tools.fieldset.BaseFieldSet; @@ -22,7 +19,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.MessageSource; import org.springframework.context.annotation.Scope; import org.springframework.context.i18n.LocaleContextHolder; -import org.springframework.data.elasticsearch.core.mapping.IndexCoordinates; import org.springframework.stereotype.Component; import javax.management.InvalidApplicationException; diff --git a/backend/core/src/main/java/org/opencdmp/model/DescriptionTag.java b/backend/core/src/main/java/org/opencdmp/model/DescriptionTag.java index 3123a1330..b1d17e5ca 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DescriptionTag.java +++ b/backend/core/src/main/java/org/opencdmp/model/DescriptionTag.java @@ -1,6 +1,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.model.description.Description; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplateType.java b/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplateType.java index f51aec8fb..29c2cb455 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplateType.java +++ b/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplateType.java @@ -2,7 +2,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.DescriptionTemplateTypeStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.descriptiontemplate.Definition; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/DmpDescriptionTemplate.java b/backend/core/src/main/java/org/opencdmp/model/DmpDescriptionTemplate.java index 085bd4a6c..a803cdb35 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DmpDescriptionTemplate.java +++ b/backend/core/src/main/java/org/opencdmp/model/DmpDescriptionTemplate.java @@ -1,6 +1,8 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/DmpUser.java b/backend/core/src/main/java/org/opencdmp/model/DmpUser.java index d97017170..a61dced2a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DmpUser.java +++ b/backend/core/src/main/java/org/opencdmp/model/DmpUser.java @@ -2,9 +2,8 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.DmpUserRole; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.data.converters.enums.IsActiveConverter; -import org.opencdmp.data.UserEntity; -import jakarta.persistence.*; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/Lock.java b/backend/core/src/main/java/org/opencdmp/model/Lock.java index 74cbf05ae..44d679a2f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/Lock.java +++ b/backend/core/src/main/java/org/opencdmp/model/Lock.java @@ -1,6 +1,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.LockTargetType; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/PublicDescriptionTemplate.java b/backend/core/src/main/java/org/opencdmp/model/PublicDescriptionTemplate.java index 6707661da..382f621ed 100644 --- a/backend/core/src/main/java/org/opencdmp/model/PublicDescriptionTemplate.java +++ b/backend/core/src/main/java/org/opencdmp/model/PublicDescriptionTemplate.java @@ -1,12 +1,5 @@ package org.opencdmp.model; -import org.opencdmp.commons.enums.DescriptionTemplateStatus; -import org.opencdmp.commons.enums.DescriptionTemplateVersionStatus; -import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; - -import java.time.Instant; -import java.util.List; import java.util.UUID; public class PublicDescriptionTemplate { diff --git a/backend/core/src/main/java/org/opencdmp/model/RecentActivityItem.java b/backend/core/src/main/java/org/opencdmp/model/RecentActivityItem.java index f3b0af3b5..96c92f6d0 100644 --- a/backend/core/src/main/java/org/opencdmp/model/RecentActivityItem.java +++ b/backend/core/src/main/java/org/opencdmp/model/RecentActivityItem.java @@ -1,12 +1,8 @@ package org.opencdmp.model; -import org.opencdmp.commons.enums.DmpBlueprintStatus; -import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.enums.RecentActivityItemType; -import org.opencdmp.model.dmpblueprintdefinition.Definition; - -import java.time.Instant; -import java.util.UUID; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; public class RecentActivityItem { private RecentActivityItemType type; diff --git a/backend/core/src/main/java/org/opencdmp/model/RecentActivityItemLookup.java b/backend/core/src/main/java/org/opencdmp/model/RecentActivityItemLookup.java index fff8d5dbb..793bdc42f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/RecentActivityItemLookup.java +++ b/backend/core/src/main/java/org/opencdmp/model/RecentActivityItemLookup.java @@ -4,10 +4,11 @@ import org.opencdmp.commons.enums.DescriptionStatus; import org.opencdmp.commons.enums.DmpStatus; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.enums.RecentActivityOrder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.query.lookup.DescriptionLookup; import org.opencdmp.query.lookup.DmpLookup; import org.opencdmp.query.lookup.DmpUserLookup; -import gr.cite.tools.data.query.Lookup; import gr.cite.tools.data.query.Ordering; import gr.cite.tools.data.query.Paging; import gr.cite.tools.fieldset.BaseFieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/StorageFile.java b/backend/core/src/main/java/org/opencdmp/model/StorageFile.java index 113dd2bc1..6a51f882d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/StorageFile.java +++ b/backend/core/src/main/java/org/opencdmp/model/StorageFile.java @@ -1,6 +1,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.StorageType; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/Tag.java b/backend/core/src/main/java/org/opencdmp/model/Tag.java index e50aff7ab..289eef89e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/Tag.java +++ b/backend/core/src/main/java/org/opencdmp/model/Tag.java @@ -1,10 +1,9 @@ package org.opencdmp.model; -import org.opencdmp.commons.enums.DescriptionStatus; import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.model.user.User; import java.time.Instant; -import java.util.List; import java.util.UUID; public class Tag { diff --git a/backend/core/src/main/java/org/opencdmp/model/TenantUser.java b/backend/core/src/main/java/org/opencdmp/model/TenantUser.java index 631dd02da..7f85e7bc5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/TenantUser.java +++ b/backend/core/src/main/java/org/opencdmp/model/TenantUser.java @@ -1,6 +1,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/UserContactInfo.java b/backend/core/src/main/java/org/opencdmp/model/UserContactInfo.java index 21636bfa3..fc0b3c3ae 100644 --- a/backend/core/src/main/java/org/opencdmp/model/UserContactInfo.java +++ b/backend/core/src/main/java/org/opencdmp/model/UserContactInfo.java @@ -1,6 +1,7 @@ package org.opencdmp.model; import org.opencdmp.commons.enums.ContactInfoType; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/UserDescriptionTemplate.java b/backend/core/src/main/java/org/opencdmp/model/UserDescriptionTemplate.java index 8bc6e4fff..cf330728b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/UserDescriptionTemplate.java +++ b/backend/core/src/main/java/org/opencdmp/model/UserDescriptionTemplate.java @@ -1,9 +1,9 @@ package org.opencdmp.model; -import org.opencdmp.commons.enums.DescriptionTemplateStatus; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.enums.UserDescriptionTemplateRole; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/UserRole.java b/backend/core/src/main/java/org/opencdmp/model/UserRole.java index d32108511..f7facfdb5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/UserRole.java +++ b/backend/core/src/main/java/org/opencdmp/model/UserRole.java @@ -1,5 +1,7 @@ package org.opencdmp.model; +import org.opencdmp.model.user.User; + import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/ActionConfirmation.java b/backend/core/src/main/java/org/opencdmp/model/actionconfirmation/ActionConfirmation.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/ActionConfirmation.java rename to backend/core/src/main/java/org/opencdmp/model/actionconfirmation/ActionConfirmation.java index bcc7dc3b1..38aa694f1 100644 --- a/backend/core/src/main/java/org/opencdmp/model/ActionConfirmation.java +++ b/backend/core/src/main/java/org/opencdmp/model/actionconfirmation/ActionConfirmation.java @@ -1,13 +1,9 @@ -package org.opencdmp.model; +package org.opencdmp.model.actionconfirmation; import org.opencdmp.commons.enums.ActionConfirmationStatus; import org.opencdmp.commons.enums.ActionConfirmationType; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.actionconfirmation.DmpInvitation; -import org.opencdmp.model.actionconfirmation.MergeAccountConfirmation; -import org.opencdmp.model.actionconfirmation.RemoveCredentialRequest; -import org.opencdmp.model.persist.actionconfirmation.MergeAccountConfirmationPersist; -import org.opencdmp.model.persist.actionconfirmation.RemoveCredentialRequestPersist; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTagBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTagBuilder.java index ac57bb810..fb915da9d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTagBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTagBuilder.java @@ -4,7 +4,8 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DescriptionTagEntity; -import org.opencdmp.model.Description; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.description.Description; import org.opencdmp.model.DescriptionTag; import org.opencdmp.model.Tag; import org.opencdmp.query.DescriptionQuery; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpAssociatedUserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/DmpAssociatedUserBuilder.java index 50512e717..7cd041aad 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpAssociatedUserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/DmpAssociatedUserBuilder.java @@ -5,6 +5,7 @@ import org.opencdmp.commons.enums.ContactInfoType; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.UserEntity; import org.opencdmp.model.*; +import org.opencdmp.model.user.User; import org.opencdmp.query.UserContactInfoQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpDescriptionTemplateBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/DmpDescriptionTemplateBuilder.java index a0d60100b..c9421a7ca 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpDescriptionTemplateBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/DmpDescriptionTemplateBuilder.java @@ -1,15 +1,5 @@ package org.opencdmp.model.builder; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.DescriptionTemplateVersionStatus; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DmpDescriptionTemplateEntity; -import org.opencdmp.data.DmpEntity; -import org.opencdmp.model.*; -import org.opencdmp.query.DescriptionTemplateQuery; -import org.opencdmp.query.DmpQuery; -import org.opencdmp.query.DmpUserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -17,6 +7,19 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.DescriptionTemplateVersionStatus; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.DmpDescriptionTemplateEntity; +import org.opencdmp.model.DescriptionTemplateType; +import org.opencdmp.model.DmpDescriptionTemplate; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.query.DescriptionTemplateQuery; +import org.opencdmp.query.DmpQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -27,7 +30,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpDescriptionTemplateBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpUserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/DmpUserBuilder.java index 5a87943a0..723ec7a01 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpUserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/DmpUserBuilder.java @@ -1,12 +1,5 @@ package org.opencdmp.model.builder; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DmpUserEntity; -import org.opencdmp.model.*; -import org.opencdmp.query.DmpQuery; -import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -14,6 +7,16 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.DmpUserEntity; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.user.User; +import org.opencdmp.query.DmpQuery; +import org.opencdmp.query.UserQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -24,7 +27,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpUserBuilder extends BaseBuilder{ private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/LockBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/LockBuilder.java index c38464cb8..0e37c1702 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/LockBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/LockBuilder.java @@ -1,14 +1,11 @@ package org.opencdmp.model.builder; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.XmlHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.LockEntity; import org.opencdmp.model.Lock; -import org.opencdmp.model.Tenant; -import org.opencdmp.model.User; -import org.opencdmp.query.TenantQuery; +import org.opencdmp.model.user.User; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/PublicDmpUserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/PublicDmpUserBuilder.java index 6f6bc22a7..85d7432c4 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/PublicDmpUserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/PublicDmpUserBuilder.java @@ -6,7 +6,7 @@ import org.opencdmp.data.DmpUserEntity; import org.opencdmp.model.PublicDmp; import org.opencdmp.model.PublicDmpUser; import org.opencdmp.model.PublicUser; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.DmpQuery; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/PublicUserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/PublicUserBuilder.java index ceb608699..3fb48fff5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/PublicUserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/PublicUserBuilder.java @@ -4,7 +4,6 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.UserEntity; import org.opencdmp.model.PublicUser; -import org.opencdmp.model.User; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/RecentActivityItemBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/RecentActivityItemBuilder.java index 08e6358a4..54f04f19e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/RecentActivityItemBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/RecentActivityItemBuilder.java @@ -1,14 +1,5 @@ package org.opencdmp.model.builder; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.DescriptionTemplateVersionStatus; -import org.opencdmp.commons.enums.RecentActivityItemType; -import org.opencdmp.commons.types.dashborad.RecentActivityItemEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.*; -import org.opencdmp.query.DescriptionQuery; -import org.opencdmp.query.DescriptionTemplateQuery; -import org.opencdmp.query.DmpQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -16,6 +7,17 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.RecentActivityItemType; +import org.opencdmp.commons.types.dashborad.RecentActivityItemEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.RecentActivityItem; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.query.DescriptionQuery; +import org.opencdmp.query.DmpQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -26,7 +28,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class RecentActivityItemBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/StorageFileBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/StorageFileBuilder.java index e6c29b7fb..3c42a64eb 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/StorageFileBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/StorageFileBuilder.java @@ -5,6 +5,7 @@ import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.StorageFileEntity; import org.opencdmp.model.*; +import org.opencdmp.model.user.User; import org.opencdmp.query.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/TagBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/TagBuilder.java index df5cac30f..58817dc1f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/TagBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/TagBuilder.java @@ -5,7 +5,7 @@ import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.TagEntity; import org.opencdmp.model.Tag; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/TenantUserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/TenantUserBuilder.java index a973db7bb..9a210ac66 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/TenantUserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/TenantUserBuilder.java @@ -6,7 +6,7 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.TenantUserEntity; import org.opencdmp.model.Tenant; import org.opencdmp.model.TenantUser; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.TenantQuery; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserAdditionalInfoBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/UserAdditionalInfoBuilder.java index 2c51db334..c11a92bd5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserAdditionalInfoBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/UserAdditionalInfoBuilder.java @@ -1,13 +1,5 @@ package org.opencdmp.model.builder; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.user.AdditionalInfoEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DescriptionReferenceEntity; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.UserAdditionalInfo; -import org.opencdmp.query.ReferenceQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -15,6 +7,14 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.user.AdditionalInfoEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.user.UserAdditionalInfo; +import org.opencdmp.query.ReferenceQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -25,7 +25,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class UserAdditionalInfoBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/UserBuilder.java index 08c053502..70a37046d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/UserBuilder.java @@ -1,31 +1,36 @@ package org.opencdmp.model.builder; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.data.query.QueryFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.exception.MyForbiddenException; +import gr.cite.tools.fieldset.BaseFieldSet; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.authorization.AuthorizationProperties; import org.opencdmp.commons.JsonHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.user.AdditionalInfoEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.TenantEntity; import org.opencdmp.data.TenantEntityManager; import org.opencdmp.data.UserEntity; -import org.opencdmp.model.*; -import org.opencdmp.query.*; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.exception.MyForbiddenException; -import gr.cite.tools.exception.MyNotFoundException; -import gr.cite.tools.fieldset.BaseFieldSet; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.TenantUser; +import org.opencdmp.model.UserContactInfo; +import org.opencdmp.model.UserRole; +import org.opencdmp.model.builder.usercredential.UserCredentialBuilder; +import org.opencdmp.model.user.User; +import org.opencdmp.model.usercredential.UserCredential; +import org.opencdmp.query.TenantUserQuery; +import org.opencdmp.query.UserContactInfoQuery; +import org.opencdmp.query.UserCredentialQuery; +import org.opencdmp.query.UserRoleQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.MessageSource; import org.springframework.context.annotation.Scope; -import org.springframework.context.i18n.LocaleContextHolder; import org.springframework.stereotype.Component; import javax.management.InvalidApplicationException; @@ -33,7 +38,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class UserBuilder extends BaseBuilder { private final QueryFactory queryFactory; @@ -158,10 +163,10 @@ public class UserBuilder extends BaseBuilder { Map> itemMap; FieldSet clone = new BaseFieldSet(fields.getFields()).ensure(this.asIndexer(UserRole._user, User._id)); - if (!tenantScope.isSet()) throw new MyForbiddenException("tenant scope required"); + if (!this.tenantScope.isSet()) throw new MyForbiddenException("tenant scope required"); UserRoleQuery query = this.queryFactory.query(UserRoleQuery.class).authorize(this.authorize).roles(this.authorizationProperties.getAllowedTenantRoles()).userIds(data.stream().map(UserEntity::getId).distinct().collect(Collectors.toList())); - if (tenantScope.isDefaultTenant()) query.tenantIsSet(false); + if (this.tenantScope.isDefaultTenant()) query.tenantIsSet(false); else { try { query.tenantIsSet(true).tenantIds(this.tenantScope.getTenant()); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserContactInfoBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/UserContactInfoBuilder.java index 7b9f0de29..3da92f5dd 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserContactInfoBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/UserContactInfoBuilder.java @@ -3,11 +3,8 @@ package org.opencdmp.model.builder; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.UserContactInfoEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.model.UserContactInfo; -import org.opencdmp.model.User; -import org.opencdmp.query.DescriptionQuery; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserDescriptionTemplateBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/UserDescriptionTemplateBuilder.java index f40f0ba77..9526d271c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserDescriptionTemplateBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/UserDescriptionTemplateBuilder.java @@ -1,13 +1,12 @@ package org.opencdmp.model.builder; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.XmlHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.UserDescriptionTemplateEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.DescriptionTemplate; -import org.opencdmp.model.User; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.user.User; import org.opencdmp.model.UserDescriptionTemplate; import org.opencdmp.query.DescriptionTemplateQuery; import org.opencdmp.query.UserQuery; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserRoleBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/UserRoleBuilder.java index 340994120..32ff03d21 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserRoleBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/UserRoleBuilder.java @@ -4,7 +4,7 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.UserRoleEntity; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.model.UserRole; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/ActionConfirmationBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/actionconfirmation/ActionConfirmationBuilder.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/builder/ActionConfirmationBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/actionconfirmation/ActionConfirmationBuilder.java index c875dccda..23548af37 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/ActionConfirmationBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/actionconfirmation/ActionConfirmationBuilder.java @@ -1,22 +1,17 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.actionconfirmation; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.XmlHandlingService; -import org.opencdmp.commons.enums.ActionConfirmationType; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.actionconfirmation.DmpInvitationEntity; import org.opencdmp.commons.types.actionconfirmation.MergeAccountConfirmationEntity; import org.opencdmp.commons.types.actionconfirmation.RemoveCredentialRequestEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.ActionConfirmationEntity; -import org.opencdmp.data.tenant.TenantScopedBaseEntity; -import org.opencdmp.model.ActionConfirmation; -import org.opencdmp.model.Tenant; -import org.opencdmp.model.User; -import org.opencdmp.model.builder.actionconfirmation.DmpInvitationBuilder; -import org.opencdmp.model.builder.actionconfirmation.MergeAccountConfirmationBuilder; -import org.opencdmp.model.builder.actionconfirmation.RemoveCredentialRequestBuilder; -import org.opencdmp.query.TenantQuery; +import org.opencdmp.model.actionconfirmation.ActionConfirmation; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.UserBuilder; +import org.opencdmp.model.user.User; import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; @@ -31,7 +26,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import javax.management.InvalidApplicationException; import java.util.*; import java.util.stream.Collectors; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/DescriptionCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/DescriptionCommonModelBuilder.java index c3b143aa3..5801bf25d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/DescriptionCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/DescriptionCommonModelBuilder.java @@ -14,7 +14,7 @@ import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DescriptionTemplateEntity; import org.opencdmp.data.DmpDescriptionTemplateEntity; import org.opencdmp.data.DmpEntity; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.model.DmpDescriptionTemplate; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; @@ -129,7 +129,7 @@ public class DescriptionCommonModelBuilder extends BaseCommonModelBuilder itemMap = new HashMap<>(); DescriptionTemplateQuery q = this.queryFactory.query(DescriptionTemplateQuery.class).authorize(this.authorize).ids(data.stream().map(DescriptionEntity::getDescriptionTemplateId).distinct().collect(Collectors.toList())); - List items = q.collectAs(new BaseFieldSet().ensure(org.opencdmp.model.DescriptionTemplate._id).ensure(DescriptionTemplate._definition)); + List items = q.collectAs(new BaseFieldSet().ensure(DescriptionTemplate._id).ensure(DescriptionTemplate._definition)); for (DescriptionTemplateEntity item : items){ DefinitionEntity definition = this.xmlHandlingService.fromXmlSafe(DefinitionEntity.class, item.getDefinition()); itemMap.put(item.getId(), definition); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/FieldCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/FieldCommonModelBuilder.java index c5443a5e8..1782946d4 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/FieldCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/description/FieldCommonModelBuilder.java @@ -18,7 +18,7 @@ import org.opencdmp.commons.types.description.FieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.ReferenceEntity; import org.opencdmp.data.StorageFileEntity; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.model.StorageFile; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/DefinitionCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/DefinitionCommonModelBuilder.java index 11d37f108..4e4dc843e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/DefinitionCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/DefinitionCommonModelBuilder.java @@ -6,7 +6,6 @@ import org.opencdmp.commons.types.descriptiontemplate.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; -import org.opencdmp.model.builder.descriptiontemplatedefinition.PageBuilder; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/MultiplicityCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/MultiplicityCommonModelBuilder.java index 502064cbc..4584574ba 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/MultiplicityCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/MultiplicityCommonModelBuilder.java @@ -6,7 +6,6 @@ import org.opencdmp.commons.types.descriptiontemplate.MultiplicityEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; -import org.opencdmp.model.descriptiontemplatedefinition.Multiplicity; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/PageCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/PageCommonModelBuilder.java index 3e698c598..6750a1094 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/PageCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/PageCommonModelBuilder.java @@ -6,8 +6,6 @@ import org.opencdmp.commons.types.descriptiontemplate.PageEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; -import org.opencdmp.model.builder.descriptiontemplatedefinition.SectionBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Page; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/fielddata/ReferenceTypeDataCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/fielddata/ReferenceTypeDataCommonModelBuilder.java index 7f91eb49e..88d251471 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/fielddata/ReferenceTypeDataCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/descriptiontemplate/fielddata/ReferenceTypeDataCommonModelBuilder.java @@ -1,14 +1,13 @@ package org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata; -import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.ReferenceTypeDataModel; -import org.opencdmp.commons.types.descriptiontemplate.fielddata.ReferenceTypeDataEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.builder.commonmodels.ReferenceTypeCommonModelBuilder; -import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.ReferenceTypeDataModel; +import org.opencdmp.commons.types.descriptiontemplate.fielddata.ReferenceTypeDataEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.commonmodels.ReferenceTypeCommonModelBuilder; +import org.opencdmp.query.ReferenceTypeQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -16,7 +15,7 @@ import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class ReferenceTypeDataCommonModelBuilder extends BaseFieldDataCommonModelBuilder { private final QueryFactory queryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmp/DmpCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmp/DmpCommonModelBuilder.java index eb72d23a9..c719e1562 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmp/DmpCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmp/DmpCommonModelBuilder.java @@ -21,6 +21,9 @@ import org.opencdmp.model.builder.commonmodels.*; import org.opencdmp.model.builder.commonmodels.description.DescriptionCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.dmpblueprint.DmpBlueprintCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.dmpreference.DmpReferenceCommonModelBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.query.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.Ordering; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ExtraFieldCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ExtraFieldCommonModelBuilder.java index febd7f27b..dc4f34670 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ExtraFieldCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ExtraFieldCommonModelBuilder.java @@ -4,11 +4,7 @@ import org.opencdmp.commonmodels.enums.DmpBlueprintExtraFieldDataType; import org.opencdmp.commonmodels.models.dmpblueprint.ExtraFieldModel; import org.opencdmp.commons.types.dmpblueprint.ExtraFieldEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.dmpblueprintdefinition.ExtraField; import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.LoggerService; -import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/FieldCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/FieldCommonModelBuilder.java index 04902ffc6..620c302c3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/FieldCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/FieldCommonModelBuilder.java @@ -7,11 +7,7 @@ import org.opencdmp.commons.types.dmpblueprint.FieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.commonmodels.BaseCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.CommonModelBuilderItemResponse; -import org.opencdmp.model.builder.commonmodels.dmp.DmpBlueprintValueCommonModelBuilder; -import org.opencdmp.model.dmpblueprintdefinition.Field; -import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ReferenceTypeFieldCommonModelBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ReferenceTypeFieldCommonModelBuilder.java index 3f940565e..a136caac5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ReferenceTypeFieldCommonModelBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/commonmodels/dmpblueprint/ReferenceTypeFieldCommonModelBuilder.java @@ -4,7 +4,6 @@ import org.opencdmp.commonmodels.models.dmpblueprint.ReferenceTypeFieldModel; import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.commonmodels.ReferenceTypeCommonModelBuilder; -import org.opencdmp.model.dmpblueprintdefinition.ReferenceTypeField; import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/DescriptionBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/DescriptionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/DescriptionBuilder.java index a4a565b76..3af1df6ea 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/DescriptionBuilder.java @@ -1,5 +1,13 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.descriptionproperties; +import gr.cite.commons.web.authz.service.AuthorizationService; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.data.query.QueryFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.fieldset.BaseFieldSet; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AffiliatedResource; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.authorization.authorizationcontentresolver.AuthorizationContentResolver; @@ -11,19 +19,21 @@ import org.opencdmp.commons.types.descriptiontemplate.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DescriptionTemplateEntity; -import org.opencdmp.data.DmpEntity; -import org.opencdmp.data.UserRoleEntity; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.descriptionpropertiesdefinition.PropertyDefinitionBuilder; +import org.opencdmp.model.DescriptionTag; +import org.opencdmp.model.DmpDescriptionTemplate; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.DescriptionTagBuilder; +import org.opencdmp.model.builder.DmpDescriptionTemplateBuilder; +import org.opencdmp.model.builder.UserBuilder; +import org.opencdmp.model.builder.descriptionreference.DescriptionReferenceBuilder; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.user.User; import org.opencdmp.query.*; -import gr.cite.commons.web.authz.service.AuthorizationService; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.BaseFieldSet; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -34,7 +44,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DescriptionBuilder extends BaseBuilder { private final QueryFactory queryFactory; @@ -229,7 +239,7 @@ public class DescriptionBuilder extends BaseBuilder itemMap = new HashMap<>(); DescriptionTemplateQuery q = this.queryFactory.query(DescriptionTemplateQuery.class).authorize(this.authorize).ids(data.stream().map(DescriptionEntity::getDescriptionTemplateId).distinct().collect(Collectors.toList())); - List items = q.collectAs(new BaseFieldSet().ensure(org.opencdmp.model.DescriptionTemplate._id).ensure(DescriptionTemplate._definition)); + List items = q.collectAs(new BaseFieldSet().ensure(DescriptionTemplate._id).ensure(DescriptionTemplate._definition)); for (DescriptionTemplateEntity item : items){ DefinitionEntity definition =this.xmlHandlingService.fromXmlSafe(DefinitionEntity.class, item.getDefinition()); itemMap.put(item.getId(), definition); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/ExternalIdentifierBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/ExternalIdentifierBuilder.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/ExternalIdentifierBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/ExternalIdentifierBuilder.java index 4eda026ed..e0be319f8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/ExternalIdentifierBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/ExternalIdentifierBuilder.java @@ -1,12 +1,10 @@ -package org.opencdmp.model.builder.descriptionpropertiesdefinition; +package org.opencdmp.model.builder.descriptionproperties; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.description.ExternalIdentifierEntity; -import org.opencdmp.commons.types.description.FieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptionproperties.ExternalIdentifier; -import org.opencdmp.model.descriptionproperties.Field; +import org.opencdmp.model.description.ExternalIdentifier; import org.opencdmp.service.fielddatahelper.FieldDataHelperServiceProvider; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/FieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/FieldBuilder.java similarity index 97% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/FieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/FieldBuilder.java index 8da9927ef..2529174f7 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/FieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/FieldBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptionpropertiesdefinition; +package org.opencdmp.model.builder.descriptionproperties; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; @@ -13,10 +13,10 @@ import org.opencdmp.commons.types.description.FieldEntity; import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.commons.types.descriptiontemplate.fielddata.SelectDataEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Reference; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.ReferenceBuilder; -import org.opencdmp.model.descriptionproperties.Field; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.description.Field; +import org.opencdmp.model.reference.Reference; import org.opencdmp.query.ReferenceQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionBuilder.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionBuilder.java index 0df623c70..5f1b4e0df 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptionpropertiesdefinition; +package org.opencdmp.model.builder.descriptionproperties; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.description.PropertyDefinitionEntity; @@ -6,8 +6,6 @@ import org.opencdmp.commons.types.descriptiontemplate.DefinitionEntity; import org.opencdmp.commons.types.descriptiontemplate.FieldSetEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; -import org.opencdmp.model.persist.descriptionproperties.PropertyDefinitionPersist; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; @@ -18,7 +16,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; +import org.opencdmp.model.description.PropertyDefinition; import java.util.*; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetBuilder.java index 975dfbcc0..a895ee45c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetBuilder.java @@ -1,12 +1,11 @@ -package org.opencdmp.model.builder.descriptionpropertiesdefinition; +package org.opencdmp.model.builder.descriptionproperties; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.description.PropertyDefinitionFieldSetEntity; import org.opencdmp.commons.types.descriptiontemplate.FieldSetEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptionproperties.PropertyDefinitionFieldSet; -import org.opencdmp.model.persist.descriptionproperties.PropertyDefinitionFieldSetPersist; +import org.opencdmp.model.description.PropertyDefinitionFieldSet; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetItemBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetItemBuilder.java similarity index 90% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetItemBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetItemBuilder.java index b59f1716b..f5758012c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptionpropertiesdefinition/PropertyDefinitionFieldSetItemBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionproperties/PropertyDefinitionFieldSetItemBuilder.java @@ -1,16 +1,12 @@ -package org.opencdmp.model.builder.descriptionpropertiesdefinition; +package org.opencdmp.model.builder.descriptionproperties; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.description.PropertyDefinitionEntity; import org.opencdmp.commons.types.description.PropertyDefinitionFieldSetItemEntity; import org.opencdmp.commons.types.descriptiontemplate.FieldEntity; import org.opencdmp.commons.types.descriptiontemplate.FieldSetEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DescriptionTemplate; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; -import org.opencdmp.model.descriptionproperties.PropertyDefinitionFieldSetItem; -import org.opencdmp.model.persist.descriptionproperties.PropertyDefinitionFieldSetItemPersist; +import org.opencdmp.model.description.PropertyDefinitionFieldSetItem; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionReferenceBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionreference/DescriptionReferenceBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/DescriptionReferenceBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptionreference/DescriptionReferenceBuilder.java index 368ff3cbd..0b306697c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionReferenceBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptionreference/DescriptionReferenceBuilder.java @@ -1,20 +1,5 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.descriptionreference; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.JsonHandlingService; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.commons.types.descriptionreference.DescriptionReferenceDataEntity; -import org.opencdmp.commons.types.dmpreference.DmpReferenceDataEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DescriptionReferenceEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.builder.descriptionreference.DescriptionReferenceDataBuilder; -import org.opencdmp.model.builder.dmpreference.DmpReferenceDataBuilder; -import org.opencdmp.query.DescriptionQuery; -import org.opencdmp.query.ReferenceQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -22,6 +7,20 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.JsonHandlingService; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.commons.types.descriptionreference.DescriptionReferenceDataEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.DescriptionReferenceEntity; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.query.DescriptionQuery; +import org.opencdmp.query.ReferenceQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -32,7 +31,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DescriptionReferenceBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefaultValueBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefaultValueBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefaultValueBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefaultValueBuilder.java index 10007622d..6d1fd9be9 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefaultValueBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefaultValueBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; @@ -9,7 +9,7 @@ import org.opencdmp.commons.enums.FieldType; import org.opencdmp.commons.types.descriptiontemplate.DefaultValueEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.DefaultValue; +import org.opencdmp.model.descriptiontemplate.DefaultValue; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefinitionBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefinitionBuilder.java index 60bced0b0..381ecabec 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/DefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DefinitionBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.descriptiontemplate.Definition; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTemplateBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DescriptionTemplateBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTemplateBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DescriptionTemplateBuilder.java index 06c235748..b9efbed9b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DescriptionTemplateBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/DescriptionTemplateBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.descriptiontemplate; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.XmlHandlingService; @@ -6,10 +6,12 @@ import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.descriptiontemplate.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DescriptionTemplateEntity; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.DescriptionTemplateTypeBuilder; +import org.opencdmp.model.builder.UserDescriptionTemplateBuilder; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.model.DescriptionTemplateType; import org.opencdmp.model.UserDescriptionTemplate; -import org.opencdmp.model.builder.descriptiontemplatedefinition.DefinitionBuilder; import org.opencdmp.query.DescriptionTemplateTypeQuery; import org.opencdmp.query.UserDescriptionTemplateQuery; import gr.cite.tools.data.builder.BuilderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldBuilder.java similarity index 97% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldBuilder.java index df13e2242..013dab95e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; @@ -9,7 +9,7 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.FieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Field; +import org.opencdmp.model.descriptiontemplate.Field; import org.opencdmp.service.fielddatahelper.FieldDataHelperService; import org.opencdmp.service.fielddatahelper.FieldDataHelperServiceProvider; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldSetBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldSetBuilder.java similarity index 67% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldSetBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldSetBuilder.java index 3ec837008..a996d4be7 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/FieldSetBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/FieldSetBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; @@ -19,7 +19,7 @@ import java.util.*; @Component @Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) -public class FieldSetBuilder extends BaseBuilder { +public class FieldSetBuilder extends BaseBuilder { private final BuilderFactory builderFactory; private EnumSet authorize = EnumSet.of(AuthorizationFlags.None); @@ -37,25 +37,25 @@ public class FieldSetBuilder extends BaseBuilder build(FieldSet fields, List data) throws MyApplicationException { + public List build(FieldSet fields, List data) throws MyApplicationException { this.logger.debug("building for {} items requesting {} fields", Optional.ofNullable(data).map(List::size).orElse(0), Optional.ofNullable(fields).map(FieldSet::getFields).map(Set::size).orElse(0)); this.logger.trace(new DataLogEntry("requested fields", fields)); if (fields == null || data == null || fields.isEmpty()) return new ArrayList<>(); - FieldSet fieldsFields = fields.extractPrefixed(this.asPrefix(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._fields)); - FieldSet multiplicityFields = fields.extractPrefixed(this.asPrefix(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._multiplicity)); + FieldSet fieldsFields = fields.extractPrefixed(this.asPrefix(org.opencdmp.model.descriptiontemplate.FieldSet._fields)); + FieldSet multiplicityFields = fields.extractPrefixed(this.asPrefix(org.opencdmp.model.descriptiontemplate.FieldSet._multiplicity)); - List models = new ArrayList<>(); + List models = new ArrayList<>(); for (FieldSetEntity d : data) { - org.opencdmp.model.descriptiontemplatedefinition.FieldSet m = new org.opencdmp.model.descriptiontemplatedefinition.FieldSet(); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._id))) m.setId(d.getId()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._ordinal))) m.setOrdinal(d.getOrdinal()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._title))) m.setTitle(d.getTitle()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._description))) m.setDescription(d.getDescription()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._extendedDescription))) m.setExtendedDescription(d.getExtendedDescription()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._additionalInformation))) m.setAdditionalInformation(d.getAdditionalInformation()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._hasCommentField))) m.setHasCommentField(d.getHasCommentField()); - if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._hasMultiplicity))) m.setHasMultiplicity(d.getHasMultiplicity()); + org.opencdmp.model.descriptiontemplate.FieldSet m = new org.opencdmp.model.descriptiontemplate.FieldSet(); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._id))) m.setId(d.getId()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._ordinal))) m.setOrdinal(d.getOrdinal()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._title))) m.setTitle(d.getTitle()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._description))) m.setDescription(d.getDescription()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._extendedDescription))) m.setExtendedDescription(d.getExtendedDescription()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._additionalInformation))) m.setAdditionalInformation(d.getAdditionalInformation()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._hasCommentField))) m.setHasCommentField(d.getHasCommentField()); + if (fields.hasField(this.asIndexer(org.opencdmp.model.descriptiontemplate.FieldSet._hasMultiplicity))) m.setHasMultiplicity(d.getHasMultiplicity()); if (!multiplicityFields.isEmpty() && d.getMultiplicity() != null) m.setMultiplicity(this.builderFactory.builder(MultiplicityBuilder.class).authorize(this.authorize).build(multiplicityFields, d.getMultiplicity())); if (!fieldsFields.isEmpty() && d.getFields() != null) m.setFields(this.builderFactory.builder(FieldBuilder.class).authorize(this.authorize).build(fieldsFields, d.getFields())); models.add(m); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/MultiplicityBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/MultiplicityBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/MultiplicityBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/MultiplicityBuilder.java index bc7c8e251..93790e1bd 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/MultiplicityBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/MultiplicityBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.MultiplicityEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Multiplicity; +import org.opencdmp.model.descriptiontemplate.Multiplicity; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/PageBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/PageBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/PageBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/PageBuilder.java index b08242320..b34cfc17e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/PageBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/PageBuilder.java @@ -1,11 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.PageEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; -import org.opencdmp.model.descriptiontemplatedefinition.Page; +import org.opencdmp.model.descriptiontemplate.Page; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/RuleBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/RuleBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/RuleBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/RuleBuilder.java index 64b325af3..916b615a1 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/RuleBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/RuleBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; @@ -11,7 +11,7 @@ import org.opencdmp.commons.enums.FieldType; import org.opencdmp.commons.types.descriptiontemplate.RuleEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Rule; +import org.opencdmp.model.descriptiontemplate.Rule; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/SectionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/SectionBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/SectionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/SectionBuilder.java index 2d6034869..d106ee150 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/SectionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/SectionBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition; +package org.opencdmp.model.builder.descriptiontemplate; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; @@ -9,7 +9,7 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.SectionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.Section; +import org.opencdmp.model.descriptiontemplate.Section; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/BaseFieldDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/BaseFieldDataBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/BaseFieldDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/BaseFieldDataBuilder.java index d896d8817..80970728f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/BaseFieldDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/BaseFieldDataBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.fielddata.BaseFieldDataEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.BaseFieldData; +import org.opencdmp.model.descriptiontemplate.fielddata.BaseFieldData; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelAndMultiplicityDataBuilder.java similarity index 88% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelAndMultiplicityDataBuilder.java index 98a0a2f7f..61906c711 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelAndMultiplicityDataBuilder.java @@ -1,8 +1,8 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.LabelAndMultiplicityData; +import org.opencdmp.model.descriptiontemplate.fielddata.LabelAndMultiplicityData; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelDataBuilder.java similarity index 86% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelDataBuilder.java index 9d6da2925..df49a210f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/LabelDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/LabelDataBuilder.java @@ -1,8 +1,8 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelDataEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.LabelData; +import org.opencdmp.model.descriptiontemplate.fielddata.LabelData; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/RadioBoxDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/RadioBoxDataBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/RadioBoxDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/RadioBoxDataBuilder.java index 541fc6f6e..671b9b92c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/RadioBoxDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/RadioBoxDataBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.fielddata.RadioBoxDataEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.RadioBoxData; +import org.opencdmp.model.descriptiontemplate.fielddata.RadioBoxData; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/ReferenceTypeDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/ReferenceTypeDataBuilder.java similarity index 81% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/ReferenceTypeDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/ReferenceTypeDataBuilder.java index fbdfedf66..2b9912103 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/ReferenceTypeDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/ReferenceTypeDataBuilder.java @@ -1,16 +1,14 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; -import org.opencdmp.commons.types.descriptiontemplate.fielddata.ReferenceTypeDataEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.builder.dmpblueprintdefinition.ReferenceFieldBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.ReferenceTypeData; -import org.opencdmp.model.dmpblueprintdefinition.ReferenceTypeField; -import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.commons.types.descriptiontemplate.fielddata.ReferenceTypeDataEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.ReferenceTypeData; +import org.opencdmp.query.ReferenceTypeQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -18,7 +16,7 @@ import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class ReferenceTypeDataBuilder extends BaseFieldDataBuilder { private final QueryFactory queryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/SelectDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/SelectDataBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/SelectDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/SelectDataBuilder.java index 51d65d6d0..d0e735375 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/SelectDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/SelectDataBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.fielddata.SelectDataEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.SelectData; +import org.opencdmp.model.descriptiontemplate.fielddata.SelectData; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/UploadDataBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/UploadDataBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/UploadDataBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/UploadDataBuilder.java index 6f5e78f9e..6f20583d0 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplatedefinition/fielddata/UploadDataBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/descriptiontemplate/fielddata/UploadDataBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.builder.descriptiontemplate.fielddata; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.fielddata.UploadDataEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.UploadData; +import org.opencdmp.model.descriptiontemplate.fielddata.UploadData; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpBlueprintValueBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBlueprintValueBuilder.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpBlueprintValueBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBlueprintValueBuilder.java index a119fa9fe..04c18a361 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpBlueprintValueBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBlueprintValueBuilder.java @@ -1,15 +1,14 @@ -package org.opencdmp.model.builder.dmpproperties; +package org.opencdmp.model.builder.dmp; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.dmp.DmpBlueprintValueEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.dmpproperties.DmpBlueprintValue; -import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.dmp.DmpBlueprintValueEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.dmp.DmpBlueprintValue; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +18,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component("descriptionpropertiesdefinitionDmpBlueprintValuebuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpBlueprintValueBuilder extends BaseBuilder { private EnumSet authorize = EnumSet.of(AuthorizationFlags.None); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/DmpBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBuilder.java index 62986d7a0..5fac8a022 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpBuilder.java @@ -1,5 +1,13 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.dmp; +import gr.cite.commons.web.authz.service.AuthorizationService; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.data.query.QueryFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.fieldset.BaseFieldSet; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AffiliatedResource; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.authorization.authorizationcontentresolver.AuthorizationContentResolver; @@ -9,17 +17,19 @@ import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.dmp.DmpPropertiesEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DmpEntity; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.dmpproperties.DmpPropertiesBuilder; +import org.opencdmp.model.DmpDescriptionTemplate; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.EntityDoi; +import org.opencdmp.model.builder.*; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.builder.dmpblueprint.DmpBlueprintBuilder; +import org.opencdmp.model.builder.dmpreference.DmpReferenceBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.user.User; import org.opencdmp.query.*; -import gr.cite.commons.web.authz.service.AuthorizationService; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.BaseFieldSet; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -30,7 +40,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpBuilder extends BaseBuilder { private final QueryFactory queryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpContactBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpContactBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpContactBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpContactBuilder.java index 7bb227d96..5dbe02f08 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpContactBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpContactBuilder.java @@ -1,14 +1,5 @@ -package org.opencdmp.model.builder.dmpproperties; +package org.opencdmp.model.builder.dmp; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.dmp.DmpContactEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpAssociatedUser; -import org.opencdmp.model.User; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.DmpAssociatedUserBuilder; -import org.opencdmp.model.dmpproperties.DmpContact; -import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -16,6 +7,15 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.dmp.DmpContactEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.DmpAssociatedUser; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.DmpAssociatedUserBuilder; +import org.opencdmp.model.dmp.DmpContact; +import org.opencdmp.model.user.User; +import org.opencdmp.query.UserQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -26,7 +26,7 @@ import java.util.*; import java.util.stream.Collectors; @Component("dmpcontactbuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpContactBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpPropertiesBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpPropertiesBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpPropertiesBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpPropertiesBuilder.java index edd86213e..c6129dfb3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpproperties/DmpPropertiesBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmp/DmpPropertiesBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.dmpproperties; +package org.opencdmp.model.builder.dmp; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.dmp.DmpPropertiesEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.dmpproperties.DmpProperties; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.dmp.DmpPropertiesEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.dmp.DmpProperties; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component("dmppropertiesbuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpPropertiesBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DefinitionBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DefinitionBuilder.java index 9a40c352b..4f7fe9582 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DefinitionBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.dmpblueprint.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.dmpblueprintdefinition.Definition; +import org.opencdmp.model.dmpblueprint.Definition; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DescriptionTemplateBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DescriptionTemplateBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DescriptionTemplateBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DescriptionTemplateBuilder.java index 3683be28f..9fa377322 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/DescriptionTemplateBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DescriptionTemplateBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.dmpblueprint.DescriptionTemplateEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.dmpblueprintdefinition.DescriptionTemplate; +import org.opencdmp.model.dmpblueprint.DescriptionTemplate; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpBlueprintBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DmpBlueprintBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/DmpBlueprintBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DmpBlueprintBuilder.java index 38e265c97..c5181f4f6 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpBlueprintBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/DmpBlueprintBuilder.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.XmlHandlingService; @@ -6,8 +6,8 @@ import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.dmpblueprint.DefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DmpBlueprintEntity; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.builder.dmpblueprintdefinition.DefinitionBuilder; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ExtraFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ExtraFieldBuilder.java similarity index 90% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ExtraFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ExtraFieldBuilder.java index 3653a03b7..3d9eb8c3b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ExtraFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ExtraFieldBuilder.java @@ -1,8 +1,8 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.commons.types.dmpblueprint.ExtraFieldEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.dmpblueprintdefinition.ExtraField; +import org.opencdmp.model.dmpblueprint.ExtraField; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/FieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/FieldBuilder.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/FieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/FieldBuilder.java index 6fa2a6b87..c9a6e2556 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/FieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/FieldBuilder.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.dmpblueprint.FieldEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.dmpblueprintdefinition.Field; +import org.opencdmp.model.dmpblueprint.Field; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ReferenceFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ReferenceFieldBuilder.java similarity index 81% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ReferenceFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ReferenceFieldBuilder.java index 14977014d..ea29ef29d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/ReferenceFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/ReferenceFieldBuilder.java @@ -1,18 +1,14 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; -import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Dmp; -import org.opencdmp.model.PublicReferenceType; -import org.opencdmp.model.builder.PublicReferenceTypeBuilder; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.dmpblueprintdefinition.ReferenceTypeField; -import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.dmpblueprint.ReferenceTypeField; +import org.opencdmp.query.ReferenceTypeQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -20,7 +16,7 @@ import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class ReferenceFieldBuilder extends FieldBuilder { private final QueryFactory queryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SectionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SectionBuilder.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SectionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SectionBuilder.java index 1f83fc599..35f298ae5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SectionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SectionBuilder.java @@ -1,20 +1,23 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.DmpBlueprintFieldCategory; -import org.opencdmp.commons.types.dmpblueprint.*; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.PrefillingSourceEntity; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.PrefillingSourceBuilder; -import org.opencdmp.model.dmpblueprintdefinition.Section; -import org.opencdmp.query.PrefillingSourceQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.DmpBlueprintFieldCategory; +import org.opencdmp.commons.types.dmpblueprint.ExtraFieldEntity; +import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; +import org.opencdmp.commons.types.dmpblueprint.SectionEntity; +import org.opencdmp.commons.types.dmpblueprint.SystemFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.PrefillingSourceEntity; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.prefillingsource.PrefillingSourceBuilder; +import org.opencdmp.model.dmpblueprint.Section; +import org.opencdmp.query.PrefillingSourceQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -24,7 +27,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component("dmpblueprintdefinitionsectionbuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class SectionBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SystemFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SystemFieldBuilder.java similarity index 90% rename from backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SystemFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SystemFieldBuilder.java index c5705d139..594a2275a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprintdefinition/SystemFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpblueprint/SystemFieldBuilder.java @@ -1,8 +1,8 @@ -package org.opencdmp.model.builder.dmpblueprintdefinition; +package org.opencdmp.model.builder.dmpblueprint; import org.opencdmp.commons.types.dmpblueprint.SystemFieldEntity; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.dmpblueprintdefinition.SystemField; +import org.opencdmp.model.dmpblueprint.SystemField; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/DmpReferenceBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/dmpreference/DmpReferenceBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/DmpReferenceBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/dmpreference/DmpReferenceBuilder.java index 1ccc754f6..202a7c4fe 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/DmpReferenceBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/dmpreference/DmpReferenceBuilder.java @@ -1,20 +1,5 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.dmpreference; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.JsonHandlingService; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.commons.types.description.PropertyDefinitionEntity; -import org.opencdmp.commons.types.dmpreference.DmpReferenceDataEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DmpReferenceEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.Dmp; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.builder.descriptionpropertiesdefinition.PropertyDefinitionBuilder; -import org.opencdmp.model.builder.dmpreference.DmpReferenceDataBuilder; -import org.opencdmp.query.DmpQuery; -import org.opencdmp.query.ReferenceQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -22,6 +7,20 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.JsonHandlingService; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.commons.types.dmpreference.DmpReferenceDataEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.DmpReferenceEntity; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.query.DmpQuery; +import org.opencdmp.query.ReferenceQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -32,7 +31,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DmpReferenceBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/ExternalFetcherBaseSourceConfigurationBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/ExternalFetcherBaseSourceConfigurationBuilder.java index a17d5de2f..fb5dbf43c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/ExternalFetcherBaseSourceConfigurationBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/ExternalFetcherBaseSourceConfigurationBuilder.java @@ -1,13 +1,5 @@ package org.opencdmp.model.builder.externalfetcher; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.externalfetcher.ExternalFetcherBaseSourceConfigurationEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.externalfetcher.ExternalFetcherBaseSourceConfiguration; -import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -15,6 +7,14 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.externalfetcher.ExternalFetcherBaseSourceConfigurationEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.externalfetcher.ExternalFetcherBaseSourceConfiguration; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.query.ReferenceTypeQuery; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; @@ -24,7 +24,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public abstract class ExternalFetcherBaseSourceConfigurationBuilder extends BaseBuilder { protected EnumSet authorize = EnumSet.of(AuthorizationFlags.None); diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/QueryCaseConfigBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/QueryCaseConfigBuilder.java index 1c3323e04..2f8afe738 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/QueryCaseConfigBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/externalfetcher/QueryCaseConfigBuilder.java @@ -1,13 +1,5 @@ package org.opencdmp.model.builder.externalfetcher; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.externalfetcher.QueryCaseConfigEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.externalfetcher.QueryCaseConfig; -import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -15,6 +7,14 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.externalfetcher.QueryCaseConfigEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.externalfetcher.QueryCaseConfig; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.query.ReferenceTypeQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -25,7 +25,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class QueryCaseConfigBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/PrefillingSourceBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceBuilder.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/builder/PrefillingSourceBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceBuilder.java index c8fb2a7db..66ef0f474 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/PrefillingSourceBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceBuilder.java @@ -1,19 +1,18 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.prefillingsource; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.XmlHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.PrefillingSourceEntity; -import org.opencdmp.model.PrefillingSource; -import org.opencdmp.model.builder.prefillingsourcedefinition.PrefillingSourceDefinitionBuilder; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.prefillingsource.PrefillingSource; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -23,8 +22,8 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) -public class PrefillingSourceBuilder extends BaseBuilder{ +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) +public class PrefillingSourceBuilder extends BaseBuilder { private final BuilderFactory builderFactory; private final XmlHandlingService xmlHandlingService; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionBuilder.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionBuilder.java index 3850e98d4..6acd7fae2 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionBuilder.java @@ -1,17 +1,17 @@ -package org.opencdmp.model.builder.prefillingsourcedefinition; +package org.opencdmp.model.builder.prefillingsource; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.builder.BaseBuilder; import org.opencdmp.model.builder.externalfetcher.ExternalFetcherApiSourceConfigurationBuilder; import org.opencdmp.model.externalfetcher.ExternalFetcherApiSourceConfiguration; -import org.opencdmp.model.prefillingsourcedefinition.PrefillingSourceDefinition; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.prefillingsource.PrefillingSourceDefinition; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -21,7 +21,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PrefillingSourceDefinitionBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFieldBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFieldBuilder.java index 4a5f4aa50..9a01974d9 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFieldBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.prefillingsourcedefinition; +package org.opencdmp.model.builder.prefillingsource; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionFieldEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.prefillingsourcedefinition.PrefillingSourceDefinitionField; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.prefillingsource.PrefillingSourceDefinitionField; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PrefillingSourceDefinitionFieldBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFixedValueFieldBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFixedValueFieldBuilder.java index 3483a99f7..231c41dd8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/prefillingsource/PrefillingSourceDefinitionFixedValueFieldBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.prefillingsourcedefinition; +package org.opencdmp.model.builder.prefillingsource; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionFixedValueFieldEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.prefillingsourcedefinition.PrefillingSourceDefinitionFixedValueField; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.prefillingsource.PrefillingSourceDefinitionFixedValueFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.prefillingsource.PrefillingSourceDefinitionFixedValueField; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PrefillingSourceDefinitionFixedValueFieldBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/DefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/reference/DefinitionBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/DefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/reference/DefinitionBuilder.java index f82986672..986333e37 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/DefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/reference/DefinitionBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.referencedefinition; +package org.opencdmp.model.builder.reference; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.reference.DefinitionEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.referencedefinition.Definition; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.reference.DefinitionEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.reference.Definition; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component("referencedefinitionbuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class DefinitionBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/FieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/reference/FieldBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/FieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/reference/FieldBuilder.java index dac1d4f71..33a1d0512 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/referencedefinition/FieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/reference/FieldBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.referencedefinition; +package org.opencdmp.model.builder.reference; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.reference.FieldEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.referencedefinition.Field; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.reference.FieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.reference.Field; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component("referencedefinitionfieldbuilder") -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class FieldBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/ReferenceBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/reference/ReferenceBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/ReferenceBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/reference/ReferenceBuilder.java index 6f6a2105e..4a1245d94 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/ReferenceBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/reference/ReferenceBuilder.java @@ -1,20 +1,5 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.reference; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.XmlHandlingService; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.commons.types.reference.DefinitionEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.DescriptionEntity; -import org.opencdmp.data.ReferenceEntity; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.User; -import org.opencdmp.model.builder.referencedefinition.DefinitionBuilder; -import org.opencdmp.query.DmpReferenceQuery; -import org.opencdmp.query.ReferenceTypeQuery; -import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -22,6 +7,23 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.XmlHandlingService; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.commons.types.reference.DefinitionEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.ReferenceEntity; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.UserBuilder; +import org.opencdmp.model.builder.dmpreference.DmpReferenceBuilder; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.model.user.User; +import org.opencdmp.query.DmpReferenceQuery; +import org.opencdmp.query.ReferenceTypeQuery; +import org.opencdmp.query.UserQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -32,8 +34,8 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) -public class ReferenceBuilder extends BaseBuilder{ +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) +public class ReferenceBuilder extends BaseBuilder { private final BuilderFactory builderFactory; private final QueryFactory queryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/ReferenceTypeBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/ReferenceTypeBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeBuilder.java index 3eec29f4b..b927f3524 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/ReferenceTypeBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeBuilder.java @@ -1,19 +1,18 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.referencetype; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.exception.MyApplicationException; +import gr.cite.tools.fieldset.FieldSet; +import gr.cite.tools.logging.DataLogEntry; +import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.XmlHandlingService; import org.opencdmp.commons.scope.tenant.TenantScope; import org.opencdmp.commons.types.referencetype.ReferenceTypeDefinitionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.ReferenceTypeEntity; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.referencetypedefinition.ReferenceTypeDefinitionBuilder; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.exception.MyApplicationException; -import gr.cite.tools.fieldset.FieldSet; -import gr.cite.tools.logging.DataLogEntry; -import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.referencetype.ReferenceType; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -23,8 +22,8 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) -public class ReferenceTypeBuilder extends BaseBuilder{ +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) +public class ReferenceTypeBuilder extends BaseBuilder { private final BuilderFactory builderFactory; private final XmlHandlingService xmlHandlingService; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeDefinitionBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeDefinitionBuilder.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeDefinitionBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeDefinitionBuilder.java index 1b7771a26..c2a691cbb 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeDefinitionBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeDefinitionBuilder.java @@ -1,21 +1,20 @@ -package org.opencdmp.model.builder.referencetypedefinition; +package org.opencdmp.model.builder.referencetype; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.ExternalFetcherSourceType; -import org.opencdmp.commons.types.referencetype.ReferenceTypeDefinitionEntity; -import org.opencdmp.commons.types.externalfetcher.ExternalFetcherApiSourceConfigurationEntity; -import org.opencdmp.commons.types.externalfetcher.ExternalFetcherStaticOptionSourceConfigurationEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.builder.externalfetcher.ExternalFetcherApiSourceConfigurationBuilder; -import org.opencdmp.model.builder.externalfetcher.ExternalFetcherStaticOptionSourceConfigurationBuilder; -import org.opencdmp.model.referencetypedefinition.ReferenceTypeDefinition; -import org.opencdmp.model.externalfetcher.ExternalFetcherBaseSourceConfiguration; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.ExternalFetcherSourceType; +import org.opencdmp.commons.types.externalfetcher.ExternalFetcherApiSourceConfigurationEntity; +import org.opencdmp.commons.types.externalfetcher.ExternalFetcherStaticOptionSourceConfigurationEntity; +import org.opencdmp.commons.types.referencetype.ReferenceTypeDefinitionEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.externalfetcher.ExternalFetcherApiSourceConfigurationBuilder; +import org.opencdmp.model.builder.externalfetcher.ExternalFetcherStaticOptionSourceConfigurationBuilder; +import org.opencdmp.model.referencetype.ReferenceTypeDefinition; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -25,7 +24,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class ReferenceTypeDefinitionBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeFieldBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeFieldBuilder.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeFieldBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeFieldBuilder.java index a50defde7..af50ed317 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/referencetypedefinition/ReferenceTypeFieldBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/referencetype/ReferenceTypeFieldBuilder.java @@ -1,15 +1,15 @@ -package org.opencdmp.model.builder.referencetypedefinition; +package org.opencdmp.model.builder.referencetype; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.types.referencetype.ReferenceTypeFieldEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.BaseBuilder; -import org.opencdmp.model.referencetypedefinition.ReferenceTypeField; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.types.referencetype.ReferenceTypeFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.referencetype.ReferenceTypeField; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -19,7 +19,7 @@ import org.springframework.stereotype.Component; import java.util.*; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class ReferenceTypeFieldBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/builder/UserCredentialBuilder.java b/backend/core/src/main/java/org/opencdmp/model/builder/usercredential/UserCredentialBuilder.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/builder/UserCredentialBuilder.java rename to backend/core/src/main/java/org/opencdmp/model/builder/usercredential/UserCredentialBuilder.java index 5f465e943..d858409f8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/builder/UserCredentialBuilder.java +++ b/backend/core/src/main/java/org/opencdmp/model/builder/usercredential/UserCredentialBuilder.java @@ -1,17 +1,5 @@ -package org.opencdmp.model.builder; +package org.opencdmp.model.builder.usercredential; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.JsonHandlingService; -import org.opencdmp.commons.types.description.PropertyDefinitionEntity; -import org.opencdmp.commons.types.usercredential.UserCredentialDataEntity; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.UserCredentialEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.User; -import org.opencdmp.model.UserCredential; -import org.opencdmp.model.builder.descriptionpropertiesdefinition.PropertyDefinitionBuilder; -import org.opencdmp.model.builder.usercredential.UserCredentialDataBuilder; -import org.opencdmp.query.UserQuery; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyApplicationException; @@ -19,6 +7,16 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.JsonHandlingService; +import org.opencdmp.commons.types.usercredential.UserCredentialDataEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.UserCredentialEntity; +import org.opencdmp.model.builder.BaseBuilder; +import org.opencdmp.model.builder.UserBuilder; +import org.opencdmp.model.user.User; +import org.opencdmp.model.usercredential.UserCredential; +import org.opencdmp.query.UserQuery; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; @@ -29,7 +27,7 @@ import java.util.*; import java.util.stream.Collectors; @Component -@Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) +@Scope(ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class UserCredentialBuilder extends BaseBuilder { private final BuilderFactory builderFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTagCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTagCensor.java index 5803da746..42c4f6cfd 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTagCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTagCensor.java @@ -2,13 +2,13 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DescriptionReference; import org.opencdmp.model.DescriptionTag; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.description.DescriptionCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpDescriptionTemplateCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/DmpDescriptionTemplateCensor.java index 99b1c5a3d..f10c9cbbf 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpDescriptionTemplateCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/DmpDescriptionTemplateCensor.java @@ -3,12 +3,13 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.DmpDescriptionTemplate; -import org.opencdmp.model.DmpReference; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.descriptiontemplate.DescriptionTemplateCensor; +import org.opencdmp.model.censorship.dmp.DmpCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpUserCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/DmpUserCensor.java index 6397e2776..61a37b93e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpUserCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/DmpUserCensor.java @@ -2,14 +2,13 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpDescriptionTemplate; import org.opencdmp.model.DmpUser; -import org.opencdmp.model.UserDescriptionTemplate; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.dmp.DmpCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionCensor.java index 5a37835f1..50ad32f4e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionCensor.java @@ -2,9 +2,7 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; import org.opencdmp.model.PublicDescription; -import org.opencdmp.model.censorship.descriptionproperties.PropertyDefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; @@ -15,8 +13,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import java.util.UUID; - @Component @Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PublicDescriptionCensor extends BaseCensor { diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionTemplateCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionTemplateCensor.java index 6e35a4483..2aa2e5fd4 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionTemplateCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDescriptionTemplateCensor.java @@ -2,8 +2,6 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.PublicDescriptionTemplate; -import org.opencdmp.model.censorship.descriptiontemplatedefinition.DefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; @@ -14,8 +12,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import java.util.UUID; - @Component @Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PublicDescriptionTemplateCensor extends BaseCensor { diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDmpDescriptionTemplateCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDmpDescriptionTemplateCensor.java index 514cf8d55..20895c2e2 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDmpDescriptionTemplateCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicDmpDescriptionTemplateCensor.java @@ -2,8 +2,6 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpDescriptionTemplate; -import org.opencdmp.model.DmpReference; import org.opencdmp.model.PublicDmpDescriptionTemplate; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; @@ -15,8 +13,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import java.util.UUID; - @Component @Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PublicDmpDescriptionTemplateCensor extends BaseCensor{ diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicReferenceCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicReferenceCensor.java index c773be935..3bb05b5a8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PublicReferenceCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/PublicReferenceCensor.java @@ -2,10 +2,7 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.PublicDmpUser; import org.opencdmp.model.PublicReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.censorship.referencedefinition.DefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; @@ -16,8 +13,6 @@ import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; -import java.util.UUID; - @Component @Scope(value = ConfigurableBeanFactory.SCOPE_PROTOTYPE) public class PublicReferenceCensor extends BaseCensor { diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/RecentActivityItemCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/RecentActivityItemCensor.java index ac21b57ea..dd1bbe2a2 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/RecentActivityItemCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/RecentActivityItemCensor.java @@ -7,6 +7,8 @@ import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.description.DescriptionCensor; +import org.opencdmp.model.censorship.dmp.DmpCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/SupportiveMaterialCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/SupportiveMaterialCensor.java index dbfb8884d..a770d4066 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/SupportiveMaterialCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/SupportiveMaterialCensor.java @@ -2,8 +2,6 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.censorship.dmpblueprintdefinition.DefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/TagCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/TagCensor.java index a849b9d06..36a534f0a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/TagCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/TagCensor.java @@ -2,9 +2,7 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Reference; import org.opencdmp.model.Tag; -import org.opencdmp.model.censorship.referencedefinition.DefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserAdditionalInfoCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/UserAdditionalInfoCensor.java index fd001f7b6..3caacc012 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserAdditionalInfoCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/UserAdditionalInfoCensor.java @@ -3,7 +3,8 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.UserAdditionalInfo; +import org.opencdmp.model.censorship.reference.ReferenceCensor; +import org.opencdmp.model.user.UserAdditionalInfo; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/UserCensor.java index bd47c1a44..a707be2a8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/UserCensor.java @@ -3,7 +3,8 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.User; +import org.opencdmp.model.censorship.usercredential.UserCredentialCensor; +import org.opencdmp.model.user.User; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserContactInfoCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/UserContactInfoCensor.java index dbf5e402c..b61dbebba 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserContactInfoCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/UserContactInfoCensor.java @@ -9,6 +9,7 @@ import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.descriptionreference.DescriptionReferenceCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserDescriptionTemplateCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/UserDescriptionTemplateCensor.java index b63632725..106202290 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserDescriptionTemplateCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/UserDescriptionTemplateCensor.java @@ -2,14 +2,13 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DescriptionTemplate; import org.opencdmp.model.UserDescriptionTemplate; -import org.opencdmp.model.censorship.descriptiontemplatedefinition.DefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.descriptiontemplate.DescriptionTemplateCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserRoleCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/UserRoleCensor.java index 1a6720e1a..cc8725cb8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserRoleCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/UserRoleCensor.java @@ -3,13 +3,12 @@ package org.opencdmp.model.censorship; import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; -import org.opencdmp.model.censorship.descriptionproperties.PropertyDefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.descriptionreference.DescriptionReferenceCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/deposit/DepositConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/deposit/DepositConfigurationCensor.java index c09ad03fd..d2a5c9825 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/deposit/DepositConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/deposit/DepositConfigurationCensor.java @@ -2,11 +2,8 @@ package org.opencdmp.model.censorship.deposit; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; import org.opencdmp.model.censorship.*; -import org.opencdmp.model.censorship.descriptionproperties.PropertyDefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; -import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/description/DescriptionCensor.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/description/DescriptionCensor.java index 57a227fb9..b25876add 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/description/DescriptionCensor.java @@ -1,9 +1,12 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.description; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; -import org.opencdmp.model.censorship.descriptionproperties.PropertyDefinitionCensor; +import org.opencdmp.model.censorship.*; +import org.opencdmp.model.censorship.descriptionreference.DescriptionReferenceCensor; +import org.opencdmp.model.censorship.descriptiontemplate.DescriptionTemplateCensor; +import org.opencdmp.model.censorship.dmp.DmpCensor; +import org.opencdmp.model.description.Description; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/FieldCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/description/FieldCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/FieldCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/description/FieldCensor.java index fd2e0e147..4788f7bab 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/FieldCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/description/FieldCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptionproperties; +package org.opencdmp.model.censorship.description; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionCensor.java similarity index 86% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionCensor.java index 4b745d41b..03c26356a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionCensor.java @@ -1,12 +1,9 @@ -package org.opencdmp.model.censorship.descriptionproperties; +package org.opencdmp.model.censorship.description; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.censorship.dmpblueprintdefinition.SectionCensor; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; -import org.opencdmp.model.dmpblueprintdefinition.Definition; +import org.opencdmp.model.description.PropertyDefinition; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetCensor.java similarity index 90% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetCensor.java index 75d73c772..a9de7e3bf 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetCensor.java @@ -1,10 +1,9 @@ -package org.opencdmp.model.censorship.descriptionproperties; +package org.opencdmp.model.censorship.description; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; -import org.opencdmp.model.descriptionproperties.PropertyDefinitionFieldSet; +import org.opencdmp.model.description.PropertyDefinitionFieldSet; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetItemCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetItemCensor.java similarity index 90% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetItemCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetItemCensor.java index 50e173d04..6fe8b9cdd 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionproperties/PropertyDefinitionFieldSetItemCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/description/PropertyDefinitionFieldSetItemCensor.java @@ -1,10 +1,9 @@ -package org.opencdmp.model.censorship.descriptionproperties; +package org.opencdmp.model.censorship.description; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; -import org.opencdmp.model.descriptionproperties.PropertyDefinitionFieldSetItem; +import org.opencdmp.model.description.PropertyDefinitionFieldSetItem; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionReferenceCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionreference/DescriptionReferenceCensor.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionReferenceCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptionreference/DescriptionReferenceCensor.java index b8f9168c5..8070ad54d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionReferenceCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptionreference/DescriptionReferenceCensor.java @@ -1,9 +1,11 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.descriptionreference; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.censorship.descriptionreference.DescriptionReferenceDataCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.censorship.reference.ReferenceCensor; +import org.opencdmp.model.censorship.description.DescriptionCensor; +import org.opencdmp.model.descriptionreference.DescriptionReference; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefaultValueCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefaultValueCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefaultValueCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefaultValueCensor.java index 517c0d991..51fc4073e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefaultValueCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefaultValueCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefinitionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefinitionCensor.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefinitionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefinitionCensor.java index b487deb53..98e156803 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/DefinitionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DefinitionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.descriptiontemplate.Definition; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTemplateCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DescriptionTemplateCensor.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTemplateCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DescriptionTemplateCensor.java index 8ff0ea9f5..fd08cfc45 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DescriptionTemplateCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/DescriptionTemplateCensor.java @@ -1,9 +1,11 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DescriptionTemplate; -import org.opencdmp.model.censorship.descriptiontemplatedefinition.DefinitionCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.censorship.DescriptionTemplateTypeCensor; +import org.opencdmp.model.censorship.UserDescriptionTemplateCensor; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldCensor.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldCensor.java index 87b6a374d..d9f77f52e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; @@ -8,7 +8,7 @@ import gr.cite.tools.logging.LoggerService; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptiontemplatedefinition.Field; +import org.opencdmp.model.descriptiontemplate.Field; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldDataCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldDataCensor.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldDataCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldDataCensor.java index 196df4a6a..2f332802e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldDataCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldDataCensor.java @@ -1,10 +1,9 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; import gr.cite.commons.web.authz.service.AuthorizationService; -import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldSetCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldSetCensor.java similarity index 88% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldSetCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldSetCensor.java index 156ad8eaf..db946389b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/FieldSetCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/FieldSetCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; @@ -38,10 +38,10 @@ public class FieldSetCensor extends BaseCensor { this.authService.authorizeForce(Permission.BrowseDescriptionTemplate); - FieldSet multiplicityFields = fields.extractPrefixed(this.asIndexerPrefix(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._multiplicity)); + FieldSet multiplicityFields = fields.extractPrefixed(this.asIndexerPrefix(org.opencdmp.model.descriptiontemplate.FieldSet._multiplicity)); this.censorFactory.censor(MultiplicityCensor.class).censor(multiplicityFields, userId); - FieldSet fieldsFields = fields.extractPrefixed(this.asIndexerPrefix(org.opencdmp.model.descriptiontemplatedefinition.FieldSet._fields)); + FieldSet fieldsFields = fields.extractPrefixed(this.asIndexerPrefix(org.opencdmp.model.descriptiontemplate.FieldSet._fields)); this.censorFactory.censor(FieldCensor.class).censor(fieldsFields, userId); } diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/MultiplicityCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/MultiplicityCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/MultiplicityCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/MultiplicityCensor.java index 442ffede4..061a2cd88 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/MultiplicityCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/MultiplicityCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/PageCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/PageCensor.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/PageCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/PageCensor.java index 9dc53fb07..e6cb94fb5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/PageCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/PageCensor.java @@ -1,10 +1,9 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; -import org.opencdmp.model.descriptiontemplatedefinition.Page; +import org.opencdmp.model.descriptiontemplate.Page; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/RuleCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/RuleCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/RuleCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/RuleCensor.java index 771da7e8a..6fa1e922e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/RuleCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/RuleCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/SectionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/SectionCensor.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/SectionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/SectionCensor.java index 36982a222..a2180287f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplatedefinition/SectionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/descriptiontemplate/SectionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.descriptiontemplatedefinition; +package org.opencdmp.model.censorship.descriptiontemplate; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.descriptiontemplatedefinition.Section; +import org.opencdmp.model.descriptiontemplate.Section; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpBlueprintValueCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpBlueprintValueCensor.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpBlueprintValueCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpBlueprintValueCensor.java index d029c2095..e1335e529 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpBlueprintValueCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpBlueprintValueCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.dmpproperties; +package org.opencdmp.model.censorship.dmp; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpCensor.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DmpCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpCensor.java index a28961bde..d0cb6b249 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpCensor.java @@ -1,9 +1,10 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.dmp; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Dmp; -import org.opencdmp.model.censorship.dmpproperties.DmpPropertiesCensor; +import org.opencdmp.model.censorship.*; +import org.opencdmp.model.censorship.dmpreference.DmpReferenceCensor; +import org.opencdmp.model.dmp.Dmp; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpContactCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpContactCensor.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpContactCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpContactCensor.java index b060d4ae1..e3174e650 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpContactCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpContactCensor.java @@ -1,10 +1,10 @@ -package org.opencdmp.model.censorship.dmpproperties; +package org.opencdmp.model.censorship.dmp; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; import org.opencdmp.model.censorship.UserCensor; -import org.opencdmp.model.dmpproperties.DmpContact; +import org.opencdmp.model.dmp.DmpContact; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpPropertiesCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpPropertiesCensor.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpPropertiesCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpPropertiesCensor.java index c4a8612ba..5435f03c7 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpproperties/DmpPropertiesCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmp/DmpPropertiesCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.dmpproperties; +package org.opencdmp.model.censorship.dmp; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.dmpproperties.DmpProperties; +import org.opencdmp.model.dmp.DmpProperties; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DefinitionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DefinitionCensor.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DefinitionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DefinitionCensor.java index 7dd7634c9..f1e1e74a7 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DefinitionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DefinitionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.dmpblueprintdefinition; +package org.opencdmp.model.censorship.dmpblueprint; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.dmpblueprintdefinition.Definition; +import org.opencdmp.model.dmpblueprint.Definition; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DescriptionTemplatesCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DescriptionTemplatesCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DescriptionTemplatesCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DescriptionTemplatesCensor.java index af2eee758..d80001199 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/DescriptionTemplatesCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DescriptionTemplatesCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.dmpblueprintdefinition; +package org.opencdmp.model.censorship.dmpblueprint; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpBlueprintCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DmpBlueprintCensor.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DmpBlueprintCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DmpBlueprintCensor.java index 5ffa6ccfb..63203ab76 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpBlueprintCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/DmpBlueprintCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.dmpblueprint; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.censorship.dmpblueprintdefinition.DefinitionCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/FieldCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/FieldCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/FieldCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/FieldCensor.java index 7ae569354..8c09e109e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/FieldCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/FieldCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.dmpblueprintdefinition; +package org.opencdmp.model.censorship.dmpblueprint; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/SectionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/SectionCensor.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/SectionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/SectionCensor.java index d553bf928..5fbb97034 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprintdefinition/SectionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpblueprint/SectionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.dmpblueprintdefinition; +package org.opencdmp.model.censorship.dmpblueprint; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.dmpblueprintdefinition.Section; +import org.opencdmp.model.dmpblueprint.Section; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpReferenceCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpreference/DmpReferenceCensor.java similarity index 88% rename from backend/core/src/main/java/org/opencdmp/model/censorship/DmpReferenceCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/dmpreference/DmpReferenceCensor.java index 804ac363d..d8d6e4df9 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/DmpReferenceCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/dmpreference/DmpReferenceCensor.java @@ -1,9 +1,11 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.dmpreference; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.censorship.dmpreference.DmpReferenceDataCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.censorship.reference.ReferenceCensor; +import org.opencdmp.model.censorship.dmp.DmpCensor; +import org.opencdmp.model.dmpreference.DmpReference; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingCensor.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingCensor.java index 71197f8e8..113093baa 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.prefillingsource; import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; @@ -7,6 +7,7 @@ import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; +import org.opencdmp.model.censorship.BaseCensor; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingSourceCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingSourceCensor.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingSourceCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingSourceCensor.java index 195e18e55..5069a4863 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/PrefillingSourceCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/prefillingsource/PrefillingSourceCensor.java @@ -1,9 +1,10 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.prefillingsource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.PrefillingSource; -import org.opencdmp.model.censorship.referencetypedefinition.ReferenceTypeDefinitionCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.prefillingsource.PrefillingSource; +import org.opencdmp.model.censorship.referencetype.ReferenceTypeDefinitionCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/DefinitionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/DefinitionCensor.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/DefinitionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/reference/DefinitionCensor.java index 300bb0e35..9e0c99d50 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/DefinitionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/DefinitionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.referencedefinition; +package org.opencdmp.model.censorship.reference; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.referencedefinition.Definition; +import org.opencdmp.model.reference.Definition; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/FieldCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/FieldCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/FieldCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/reference/FieldCensor.java index a71978019..3d94db1b3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencedefinition/FieldCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/FieldCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencedefinition; +package org.opencdmp.model.censorship.reference; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/ReferenceCensor.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/reference/ReferenceCensor.java index 9f53d76df..1930f5bf9 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/reference/ReferenceCensor.java @@ -1,9 +1,12 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.reference; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Reference; -import org.opencdmp.model.censorship.referencedefinition.DefinitionCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.censorship.referencetype.ReferenceTypeCensor; +import org.opencdmp.model.censorship.UserCensor; +import org.opencdmp.model.censorship.dmpreference.DmpReferenceCensor; +import org.opencdmp.model.reference.Reference; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/AuthenticationConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/AuthenticationConfigurationCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/AuthenticationConfigurationCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/AuthenticationConfigurationCensor.java index 392ef2234..e63a04b79 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/AuthenticationConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/AuthenticationConfigurationCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryCaseConfigCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryCaseConfigCensor.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryCaseConfigCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryCaseConfigCensor.java index 1414033e7..3025824ac 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryCaseConfigCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryCaseConfigCensor.java @@ -1,9 +1,8 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.censorship.ReferenceTypeCensor; import org.opencdmp.model.externalfetcher.QueryCaseConfig; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryConfigCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryConfigCensor.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryConfigCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryConfigCensor.java index bb7b4ea40..34b08331c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/QueryConfigCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/QueryConfigCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceTypeCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeCensor.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceTypeCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeCensor.java index ce3bb8036..8dd20aa43 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/ReferenceTypeCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.censorship.referencetypedefinition.ReferenceTypeDefinitionCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.referencetype.ReferenceType; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeDefinitionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeDefinitionCensor.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeDefinitionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeDefinitionCensor.java index cd3711367..cbc09bd1e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeDefinitionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeDefinitionCensor.java @@ -1,9 +1,9 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.referencetypedefinition.ReferenceTypeDefinition; +import org.opencdmp.model.referencetype.ReferenceTypeDefinition; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeFieldCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeFieldCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeFieldCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeFieldCensor.java index b6018fe36..e6606e205 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeFieldCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeFieldCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeSourceBaseConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeSourceBaseConfigurationCensor.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeSourceBaseConfigurationCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeSourceBaseConfigurationCensor.java index 9d1563f85..25fc260bc 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeSourceBaseConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeSourceBaseConfigurationCensor.java @@ -1,9 +1,8 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.censorship.ReferenceTypeCensor; import org.opencdmp.model.externalfetcher.ExternalFetcherBaseSourceConfiguration; import org.opencdmp.model.externalfetcher.ExternalFetcherApiSourceConfiguration; import org.opencdmp.model.externalfetcher.ExternalFetcherStaticOptionSourceConfiguration; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeStaticOptionCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeStaticOptionCensor.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeStaticOptionCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeStaticOptionCensor.java index 09191a71d..4c0cd7fa3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ReferenceTypeStaticOptionCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ReferenceTypeStaticOptionCensor.java @@ -1,10 +1,9 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; import gr.cite.commons.web.authz.service.AuthorizationService; -import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.DataLogEntry; import gr.cite.tools.logging.LoggerService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultFieldsMappingConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultFieldsMappingConfigurationCensor.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultFieldsMappingConfigurationCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultFieldsMappingConfigurationCensor.java index 1237b8d0f..9d2ff225e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultFieldsMappingConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultFieldsMappingConfigurationCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultsConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultsConfigurationCensor.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultsConfigurationCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultsConfigurationCensor.java index 571db77bb..ab60660b8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/referencetypedefinition/ResultsConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/referencetype/ResultsConfigurationCensor.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.censorship.referencetypedefinition; +package org.opencdmp.model.censorship.referencetype; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/tenantconfiguration/TenantConfigurationCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/tenantconfiguration/TenantConfigurationCensor.java index 4800a8b1c..e0f0acbba 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/tenantconfiguration/TenantConfigurationCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/tenantconfiguration/TenantConfigurationCensor.java @@ -2,9 +2,7 @@ package org.opencdmp.model.censorship.tenantconfiguration; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.Description; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.censorship.DescriptionReferenceCensor; import org.opencdmp.model.tenantconfiguration.TenantConfiguration; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/UserCredentialCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialCensor.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/censorship/UserCredentialCensor.java rename to backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialCensor.java index 97605fff9..d133ff50c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/UserCredentialCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialCensor.java @@ -1,10 +1,11 @@ -package org.opencdmp.model.censorship; +package org.opencdmp.model.censorship.usercredential; import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.UserCredential; -import org.opencdmp.model.censorship.usercredential.UserCredentialDataCensor; +import org.opencdmp.model.censorship.BaseCensor; +import org.opencdmp.model.usercredential.UserCredential; +import org.opencdmp.model.censorship.descriptionreference.DescriptionReferenceCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialDataCensor.java b/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialDataCensor.java index 959aeeb9e..182607f03 100644 --- a/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialDataCensor.java +++ b/backend/core/src/main/java/org/opencdmp/model/censorship/usercredential/UserCredentialDataCensor.java @@ -4,7 +4,6 @@ import org.opencdmp.authorization.OwnedResource; import org.opencdmp.authorization.Permission; import org.opencdmp.convention.ConventionService; import org.opencdmp.model.censorship.BaseCensor; -import org.opencdmp.model.censorship.DescriptionReferenceCensor; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.censor.CensorFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/deleter/DmpDeleter.java b/backend/core/src/main/java/org/opencdmp/model/deleter/DmpDeleter.java index 365c5049c..114481437 100644 --- a/backend/core/src/main/java/org/opencdmp/model/deleter/DmpDeleter.java +++ b/backend/core/src/main/java/org/opencdmp/model/deleter/DmpDeleter.java @@ -1,14 +1,13 @@ package org.opencdmp.model.deleter; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.DmpStatus; import org.opencdmp.commons.enums.DmpVersionStatus; import org.opencdmp.commons.enums.EntityType; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.data.*; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.DmpDescriptionTemplate; -import org.opencdmp.model.DmpReference; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.query.*; import org.opencdmp.service.elastic.ElasticService; import gr.cite.tools.data.deleter.Deleter; diff --git a/backend/core/src/main/java/org/opencdmp/model/Description.java b/backend/core/src/main/java/org/opencdmp/model/description/Description.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/Description.java rename to backend/core/src/main/java/org/opencdmp/model/description/Description.java index c9c777b7a..387664094 100644 --- a/backend/core/src/main/java/org/opencdmp/model/Description.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/Description.java @@ -1,8 +1,12 @@ -package org.opencdmp.model; +package org.opencdmp.model.description; import org.opencdmp.commons.enums.DescriptionStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.descriptionproperties.PropertyDefinition; +import org.opencdmp.model.*; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/ExternalIdentifier.java b/backend/core/src/main/java/org/opencdmp/model/description/ExternalIdentifier.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/descriptionproperties/ExternalIdentifier.java rename to backend/core/src/main/java/org/opencdmp/model/description/ExternalIdentifier.java index e647d6dfb..6ad9959ce 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/ExternalIdentifier.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/ExternalIdentifier.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptionproperties; +package org.opencdmp.model.description; public class ExternalIdentifier { diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/Field.java b/backend/core/src/main/java/org/opencdmp/model/description/Field.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/descriptionproperties/Field.java rename to backend/core/src/main/java/org/opencdmp/model/description/Field.java index 1aefc64bf..c133efb83 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/Field.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/Field.java @@ -1,7 +1,7 @@ -package org.opencdmp.model.descriptionproperties; +package org.opencdmp.model.description; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinition.java b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinition.java similarity index 83% rename from backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinition.java rename to backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinition.java index 361096999..2e7a0a7b3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinition.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinition.java @@ -1,7 +1,6 @@ -package org.opencdmp.model.descriptionproperties; +package org.opencdmp.model.description; -import java.util.List; import java.util.Map; public class PropertyDefinition { diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSet.java b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSet.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSet.java rename to backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSet.java index 2a35e284d..da5836bc4 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSet.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSet.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptionproperties; +package org.opencdmp.model.description; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSetItem.java b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSetItem.java similarity index 86% rename from backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSetItem.java rename to backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSetItem.java index 7e6c044b5..ca7a69d0e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptionproperties/PropertyDefinitionFieldSetItem.java +++ b/backend/core/src/main/java/org/opencdmp/model/description/PropertyDefinitionFieldSetItem.java @@ -1,6 +1,4 @@ -package org.opencdmp.model.descriptionproperties; - -import org.opencdmp.commons.types.description.FieldEntity; +package org.opencdmp.model.description; import java.util.Map; diff --git a/backend/core/src/main/java/org/opencdmp/model/DescriptionReference.java b/backend/core/src/main/java/org/opencdmp/model/descriptionreference/DescriptionReference.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/DescriptionReference.java rename to backend/core/src/main/java/org/opencdmp/model/descriptionreference/DescriptionReference.java index e2e6dfc8b..0f2714445 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DescriptionReference.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptionreference/DescriptionReference.java @@ -1,8 +1,8 @@ -package org.opencdmp.model; +package org.opencdmp.model.descriptionreference; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.descriptionreference.DescriptionReferenceData; -import org.opencdmp.model.dmpreference.DmpReferenceData; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.description.Description; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/DefaultValue.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DefaultValue.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/DefaultValue.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DefaultValue.java index 3adb139fc..23c3d3941 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/DefaultValue.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DefaultValue.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.time.Instant; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Definition.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Definition.java similarity index 80% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Definition.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Definition.java index 867db4c2d..7c70b162b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Definition.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Definition.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplate.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DescriptionTemplate.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/DescriptionTemplate.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DescriptionTemplate.java index 6e04ba948..4c9b4ebf1 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DescriptionTemplate.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/DescriptionTemplate.java @@ -1,10 +1,11 @@ -package org.opencdmp.model; +package org.opencdmp.model.descriptiontemplate; import org.opencdmp.commons.enums.DescriptionTemplateStatus; -import org.opencdmp.commons.enums.DescriptionTemplateTypeStatus; import org.opencdmp.commons.enums.DescriptionTemplateVersionStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.DescriptionTemplateType; +import org.opencdmp.model.UserDescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.Definition; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Field.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Field.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Field.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Field.java index b608f8d61..be357f406 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Field.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Field.java @@ -1,7 +1,7 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import org.opencdmp.commons.enums.FieldValidationType; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.BaseFieldData; +import org.opencdmp.model.descriptiontemplate.fielddata.BaseFieldData; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/FieldSet.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/FieldSet.java similarity index 97% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/FieldSet.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/FieldSet.java index ef8d82a05..6127fa76b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/FieldSet.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/FieldSet.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Multiplicity.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Multiplicity.java similarity index 85% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Multiplicity.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Multiplicity.java index 24b1b7b44..9bb574dde 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Multiplicity.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Multiplicity.java @@ -1,8 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; - -import org.opencdmp.commons.enums.DmpBlueprintFieldCategory; - -import java.util.UUID; +package org.opencdmp.model.descriptiontemplate; public class Multiplicity { diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Page.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Page.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Page.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Page.java index 368722a14..a7e6e90b1 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Page.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Page.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Rule.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Rule.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Rule.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Rule.java index 08fc27c52..0191e2cb3 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Rule.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Rule.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.time.Instant; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Section.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Section.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Section.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Section.java index 95b557e73..0613040d6 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/Section.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/Section.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition; +package org.opencdmp.model.descriptiontemplate; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/BaseFieldData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/BaseFieldData.java similarity index 87% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/BaseFieldData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/BaseFieldData.java index c085e69dd..b8e18bd16 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/BaseFieldData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/BaseFieldData.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; import org.opencdmp.commons.enums.FieldType; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelAndMultiplicityData.java similarity index 82% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelAndMultiplicityData.java index d27b0f6bd..1b8504a66 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelAndMultiplicityData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelAndMultiplicityData.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; public class LabelAndMultiplicityData extends BaseFieldData { public final static String _multipleSelect = "multipleSelect"; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelData.java new file mode 100644 index 000000000..ac434d2d3 --- /dev/null +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/LabelData.java @@ -0,0 +1,7 @@ +package org.opencdmp.model.descriptiontemplate.fielddata; + + + +public class LabelData extends BaseFieldData { + +} diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/RadioBoxData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/RadioBoxData.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/RadioBoxData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/RadioBoxData.java index 792c46338..37b657310 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/RadioBoxData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/RadioBoxData.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/ReferenceTypeData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/ReferenceTypeData.java similarity index 81% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/ReferenceTypeData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/ReferenceTypeData.java index 703955520..d339294ad 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/ReferenceTypeData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/ReferenceTypeData.java @@ -1,8 +1,6 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; -import org.opencdmp.model.ReferenceType; - -import java.util.UUID; +import org.opencdmp.model.referencetype.ReferenceType; public class ReferenceTypeData extends BaseFieldData { private Boolean multipleSelect; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/SelectData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/SelectData.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/SelectData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/SelectData.java index 37dc35fa0..47374fb4a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/SelectData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/SelectData.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/UploadData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/UploadData.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/UploadData.java rename to backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/UploadData.java index 57c0ff383..45d62542c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/UploadData.java +++ b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplate/fielddata/UploadData.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; +package org.opencdmp.model.descriptiontemplate.fielddata; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelData.java b/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelData.java deleted file mode 100644 index 7f9a44424..000000000 --- a/backend/core/src/main/java/org/opencdmp/model/descriptiontemplatedefinition/fielddata/LabelData.java +++ /dev/null @@ -1,7 +0,0 @@ -package org.opencdmp.model.descriptiontemplatedefinition.fielddata; - - - -public class LabelData extends BaseFieldData { - -} diff --git a/backend/core/src/main/java/org/opencdmp/model/Dmp.java b/backend/core/src/main/java/org/opencdmp/model/dmp/Dmp.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/Dmp.java rename to backend/core/src/main/java/org/opencdmp/model/dmp/Dmp.java index 4794ff56d..9c42c1a93 100644 --- a/backend/core/src/main/java/org/opencdmp/model/Dmp.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmp/Dmp.java @@ -1,10 +1,14 @@ -package org.opencdmp.model; +package org.opencdmp.model.dmp; import org.opencdmp.commons.enums.DmpAccessType; import org.opencdmp.commons.enums.DmpStatus; import org.opencdmp.commons.enums.DmpVersionStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.dmpproperties.DmpProperties; +import org.opencdmp.model.*; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.user.User; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpBlueprintValue.java b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpBlueprintValue.java similarity index 92% rename from backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpBlueprintValue.java rename to backend/core/src/main/java/org/opencdmp/model/dmp/DmpBlueprintValue.java index df1f1cc53..d8f4495a1 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpBlueprintValue.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpBlueprintValue.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpproperties; +package org.opencdmp.model.dmp; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpContact.java b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpContact.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpContact.java rename to backend/core/src/main/java/org/opencdmp/model/dmp/DmpContact.java index 6a817eb92..6ab20bc2f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpContact.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpContact.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpproperties; +package org.opencdmp.model.dmp; import org.opencdmp.model.DmpAssociatedUser; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpProperties.java b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpProperties.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpProperties.java rename to backend/core/src/main/java/org/opencdmp/model/dmp/DmpProperties.java index 69c7825ab..db9ebd404 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpproperties/DmpProperties.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmp/DmpProperties.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpproperties; +package org.opencdmp.model.dmp; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Definition.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Definition.java similarity index 84% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Definition.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Definition.java index a028e9cca..6f4d941be 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Definition.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Definition.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/DescriptionTemplate.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DescriptionTemplate.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/DescriptionTemplate.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DescriptionTemplate.java index 82671aba2..5f51c4a9e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/DescriptionTemplate.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DescriptionTemplate.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/DmpBlueprint.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DmpBlueprint.java similarity index 97% rename from backend/core/src/main/java/org/opencdmp/model/DmpBlueprint.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DmpBlueprint.java index 7ce1a5e11..a158f9b12 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DmpBlueprint.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/DmpBlueprint.java @@ -1,9 +1,9 @@ -package org.opencdmp.model; +package org.opencdmp.model.dmpblueprint; import org.opencdmp.commons.enums.DmpBlueprintStatus; import org.opencdmp.commons.enums.DmpBlueprintVersionStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.dmpblueprintdefinition.Definition; +import org.opencdmp.model.dmpblueprint.Definition; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ExtraField.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ExtraField.java similarity index 88% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ExtraField.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ExtraField.java index fe5b673d3..6dcbb749f 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ExtraField.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ExtraField.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; import org.opencdmp.commons.enums.DmpBlueprintExtraFieldDataType; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Field.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Field.java similarity index 97% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Field.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Field.java index 105dd3458..cc563fc9b 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Field.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Field.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; import org.opencdmp.commons.enums.DmpBlueprintFieldCategory; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ReferenceTypeField.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ReferenceTypeField.java similarity index 83% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ReferenceTypeField.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ReferenceTypeField.java index 769f0d3ee..df723d0a5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/ReferenceTypeField.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/ReferenceTypeField.java @@ -1,8 +1,6 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; -import org.opencdmp.model.ReferenceType; - -import java.util.UUID; +import org.opencdmp.model.referencetype.ReferenceType; public class ReferenceTypeField extends Field { diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Section.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Section.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Section.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Section.java index 3874b5326..f91850c2a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/Section.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/Section.java @@ -1,7 +1,7 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; -import org.opencdmp.model.PrefillingSource; +import org.opencdmp.model.prefillingsource.PrefillingSource; import java.util.List; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/SystemField.java b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/SystemField.java similarity index 89% rename from backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/SystemField.java rename to backend/core/src/main/java/org/opencdmp/model/dmpblueprint/SystemField.java index 8a9acfa1c..d518dcfb4 100644 --- a/backend/core/src/main/java/org/opencdmp/model/dmpblueprintdefinition/SystemField.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpblueprint/SystemField.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.dmpblueprintdefinition; +package org.opencdmp.model.dmpblueprint; import org.opencdmp.commons.enums.DmpBlueprintSystemFieldType; diff --git a/backend/core/src/main/java/org/opencdmp/model/DmpReference.java b/backend/core/src/main/java/org/opencdmp/model/dmpreference/DmpReference.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/DmpReference.java rename to backend/core/src/main/java/org/opencdmp/model/dmpreference/DmpReference.java index c0b7794ad..795c13b37 100644 --- a/backend/core/src/main/java/org/opencdmp/model/DmpReference.java +++ b/backend/core/src/main/java/org/opencdmp/model/dmpreference/DmpReference.java @@ -1,7 +1,8 @@ -package org.opencdmp.model; +package org.opencdmp.model.dmpreference; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.dmpreference.DmpReferenceData; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.dmp.Dmp; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/externalfetcher/ExternalFetcherBaseSourceConfiguration.java b/backend/core/src/main/java/org/opencdmp/model/externalfetcher/ExternalFetcherBaseSourceConfiguration.java index f08cf91f7..867dc3d46 100644 --- a/backend/core/src/main/java/org/opencdmp/model/externalfetcher/ExternalFetcherBaseSourceConfiguration.java +++ b/backend/core/src/main/java/org/opencdmp/model/externalfetcher/ExternalFetcherBaseSourceConfiguration.java @@ -1,7 +1,7 @@ package org.opencdmp.model.externalfetcher; import org.opencdmp.commons.enums.ExternalFetcherSourceType; -import org.opencdmp.model.ReferenceType; +import org.opencdmp.model.referencetype.ReferenceType; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/externalfetcher/QueryCaseConfig.java b/backend/core/src/main/java/org/opencdmp/model/externalfetcher/QueryCaseConfig.java index 2cb6fc6fb..4deeafb4e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/externalfetcher/QueryCaseConfig.java +++ b/backend/core/src/main/java/org/opencdmp/model/externalfetcher/QueryCaseConfig.java @@ -1,7 +1,7 @@ package org.opencdmp.model.externalfetcher; -import org.opencdmp.model.ReferenceType; +import org.opencdmp.model.referencetype.ReferenceType; public class QueryCaseConfig { diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldSetToDatasetFieldSetMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldSetToDatasetFieldSetMapper.java index ecc15e655..4dc0ee5b8 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldSetToDatasetFieldSetMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldSetToDatasetFieldSetMapper.java @@ -13,7 +13,7 @@ public class DescriptionFieldSetToDatasetFieldSetMapper { this.descriptionFieldToDatasetFieldMapper = descriptionFieldToDatasetFieldMapper; } - public FieldSet toPublicModel(org.opencdmp.model.descriptiontemplatedefinition.FieldSet fieldSet) { + public FieldSet toPublicModel(org.opencdmp.model.descriptiontemplate.FieldSet fieldSet) { FieldSet model = new FieldSet(); model.setId(fieldSet.getId()); model.setDescription(fieldSet.getDescription()); diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldToDatasetFieldMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldToDatasetFieldMapper.java index 9c1fe427b..1b1c47a40 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldToDatasetFieldMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionFieldToDatasetFieldMapper.java @@ -10,7 +10,7 @@ import org.springframework.stereotype.Component; @Component public class DescriptionFieldToDatasetFieldMapper { - public Field toPublicModel(org.opencdmp.model.descriptiontemplatedefinition.Field field) { + public Field toPublicModel(org.opencdmp.model.descriptiontemplate.Field field) { Field model = new Field(); model.setId(field.getId()); model.setOrdinal(field.getOrdinal()); diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionPageToDatasetPageMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionPageToDatasetPageMapper.java index 3149f22a3..dbed22f65 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionPageToDatasetPageMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionPageToDatasetPageMapper.java @@ -1,11 +1,9 @@ package org.opencdmp.model.mapper.publicapi; -import org.opencdmp.model.descriptiontemplatedefinition.Page; +import org.opencdmp.model.descriptiontemplate.Page; import org.opencdmp.model.publicapi.datasetwizard.DatasetProfilePage; import org.springframework.stereotype.Component; -import java.util.List; - @Component public class DescriptionPageToDatasetPageMapper { diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionSectionToDatasetSectionMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionSectionToDatasetSectionMapper.java index f1e292df0..02a17382a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionSectionToDatasetSectionMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionSectionToDatasetSectionMapper.java @@ -12,7 +12,7 @@ public class DescriptionSectionToDatasetSectionMapper { this.descriptionFieldSetToDatasetFieldSetMapper = descriptionFieldSetToDatasetFieldSetMapper; } - public Section toPublicModel(org.opencdmp.model.descriptiontemplatedefinition.Section section, int page) { + public Section toPublicModel(org.opencdmp.model.descriptiontemplate.Section section, int page) { Section model = new Section(); model.setId(section.getId()); model.setDescription(section.getDescription()); diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionTemplateToPublicApiDatasetProfileMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionTemplateToPublicApiDatasetProfileMapper.java index 68037e540..ae263438c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionTemplateToPublicApiDatasetProfileMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionTemplateToPublicApiDatasetProfileMapper.java @@ -1,7 +1,7 @@ package org.opencdmp.model.mapper.publicapi; -import org.opencdmp.model.DescriptionTemplate; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.Definition; import org.opencdmp.model.publicapi.datasetwizard.PagedDatasetProfile; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetListingMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetListingMapper.java index 356b62ab8..90aa07a9a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetListingMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetListingMapper.java @@ -1,6 +1,6 @@ package org.opencdmp.model.mapper.publicapi; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.publicapi.datasetprofile.DatasetProfilePublicModel; import org.opencdmp.model.publicapi.grant.GrantPublicOverviewModel; import org.opencdmp.model.publicapi.listingmodels.DatasetPublicListingModel; diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetMapper.java index 1a637c899..1cbf7d4f5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DescriptionToPublicApiDatasetMapper.java @@ -1,6 +1,6 @@ package org.opencdmp.model.mapper.publicapi; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.publicapi.datasetprofile.DatasetProfilePublicModel; import org.opencdmp.model.publicapi.datasetwizard.DataRepositoryPublicModel; import org.opencdmp.model.publicapi.datasetwizard.ExternalDatasetPublicListingModel; diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpListingMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpListingMapper.java index 324e3e387..671948f26 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpListingMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpListingMapper.java @@ -1,6 +1,6 @@ package org.opencdmp.model.mapper.publicapi; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.publicapi.listingmodels.DataManagementPlanPublicListingModel; import org.opencdmp.model.publicapi.researcher.ResearcherPublicModel; import org.opencdmp.model.publicapi.user.UserInfoPublicModel; diff --git a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpMapper.java b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpMapper.java index c1ea61e5e..49bef6619 100644 --- a/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpMapper.java +++ b/backend/core/src/main/java/org/opencdmp/model/mapper/publicapi/DmpToPublicApiDmpMapper.java @@ -1,7 +1,7 @@ package org.opencdmp.model.mapper.publicapi; import org.opencdmp.data.EntityDoiEntity; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.DmpDescriptionTemplate; import org.opencdmp.model.publicapi.associatedprofile.AssociatedProfilePublicModel; import org.opencdmp.model.publicapi.doi.DoiPublicModel; diff --git a/backend/core/src/main/java/org/opencdmp/model/persist/dmpproperties/DmpBlueprintValuePersist.java b/backend/core/src/main/java/org/opencdmp/model/persist/dmpproperties/DmpBlueprintValuePersist.java index 3c9012e5d..c94b4d633 100644 --- a/backend/core/src/main/java/org/opencdmp/model/persist/dmpproperties/DmpBlueprintValuePersist.java +++ b/backend/core/src/main/java/org/opencdmp/model/persist/dmpproperties/DmpBlueprintValuePersist.java @@ -6,7 +6,7 @@ import org.opencdmp.commons.types.dmpblueprint.DefinitionEntity; import org.opencdmp.commons.types.dmpblueprint.FieldEntity; import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; import org.opencdmp.commons.validation.BaseValidator; -import org.opencdmp.model.ReferenceType; +import org.opencdmp.model.referencetype.ReferenceType; import org.opencdmp.query.ReferenceTypeQuery; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.fieldset.BaseFieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/model/PrefillingSource.java b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSource.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/PrefillingSource.java rename to backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSource.java index 7b6e6327d..88d210c0a 100644 --- a/backend/core/src/main/java/org/opencdmp/model/PrefillingSource.java +++ b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSource.java @@ -1,7 +1,7 @@ -package org.opencdmp.model; +package org.opencdmp.model.prefillingsource; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.prefillingsourcedefinition.PrefillingSourceDefinition; +import org.opencdmp.model.prefillingsource.PrefillingSourceDefinition; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinition.java b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinition.java similarity index 96% rename from backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinition.java rename to backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinition.java index e31a1a5e8..8c79dc4d6 100644 --- a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinition.java +++ b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinition.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.prefillingsourcedefinition; +package org.opencdmp.model.prefillingsource; import org.opencdmp.model.externalfetcher.ExternalFetcherApiSourceConfiguration; diff --git a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionField.java b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionField.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionField.java rename to backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionField.java index 09cfd885b..0a71812a7 100644 --- a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionField.java +++ b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionField.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.prefillingsourcedefinition; +package org.opencdmp.model.prefillingsource; public class PrefillingSourceDefinitionField { diff --git a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueField.java b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionFixedValueField.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueField.java rename to backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionFixedValueField.java index 531c42cad..e9d658004 100644 --- a/backend/core/src/main/java/org/opencdmp/model/prefillingsourcedefinition/PrefillingSourceDefinitionFixedValueField.java +++ b/backend/core/src/main/java/org/opencdmp/model/prefillingsource/PrefillingSourceDefinitionFixedValueField.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.prefillingsourcedefinition; +package org.opencdmp.model.prefillingsource; public class PrefillingSourceDefinitionFixedValueField { private String systemFieldTarget; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/associatedprofile/AssociatedProfilePublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/associatedprofile/AssociatedProfilePublicModel.java index 75625d8b2..2f8135eee 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/associatedprofile/AssociatedProfilePublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/associatedprofile/AssociatedProfilePublicModel.java @@ -1,7 +1,7 @@ package org.opencdmp.model.publicapi.associatedprofile; -import org.opencdmp.model.DescriptionTemplate; -import org.opencdmp.model.DmpBlueprint; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import org.opencdmp.model.DmpDescriptionTemplate; import jakarta.xml.bind.annotation.*; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetprofile/DatasetProfilePublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetprofile/DatasetProfilePublicModel.java index f50de6bf9..c227b913d 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetprofile/DatasetProfilePublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetprofile/DatasetProfilePublicModel.java @@ -1,7 +1,6 @@ package org.opencdmp.model.publicapi.datasetprofile; -import org.opencdmp.data.DescriptionTemplateEntity; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/DataRepositoryPublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/DataRepositoryPublicModel.java index 5c09f349b..047016d06 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/DataRepositoryPublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/DataRepositoryPublicModel.java @@ -1,8 +1,8 @@ package org.opencdmp.model.publicapi.datasetwizard; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.publicapi.PublicApiProperties; import java.util.Objects; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ExternalDatasetPublicListingModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ExternalDatasetPublicListingModel.java index 7dffb9c08..f8d9215f5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ExternalDatasetPublicListingModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ExternalDatasetPublicListingModel.java @@ -1,8 +1,8 @@ package org.opencdmp.model.publicapi.datasetwizard; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.publicapi.PublicApiProperties; import java.util.Date; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/RegistryPublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/RegistryPublicModel.java index e35f3d275..3f34b99bd 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/RegistryPublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/RegistryPublicModel.java @@ -1,8 +1,8 @@ package org.opencdmp.model.publicapi.datasetwizard; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.publicapi.PublicApiProperties; import java.util.Objects; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ServicePublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ServicePublicModel.java index 86dd30ba7..ef24056d5 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ServicePublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/datasetwizard/ServicePublicModel.java @@ -1,11 +1,10 @@ package org.opencdmp.model.publicapi.datasetwizard; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.Reference; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.publicapi.PublicApiProperties; -import java.util.Date; import java.util.Objects; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/grant/GrantPublicOverviewModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/grant/GrantPublicOverviewModel.java index 7a946967a..92e142180 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/grant/GrantPublicOverviewModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/grant/GrantPublicOverviewModel.java @@ -1,10 +1,10 @@ package org.opencdmp.model.publicapi.grant; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.model.publicapi.funder.FunderPublicOverviewModel; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.publicapi.PublicApiProperties; import java.time.Instant; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/organisation/OrganizationPublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/organisation/OrganizationPublicModel.java index 33450d125..0cbb1d429 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/organisation/OrganizationPublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/organisation/OrganizationPublicModel.java @@ -1,7 +1,7 @@ package org.opencdmp.model.publicapi.organisation; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.service.publicapi.PublicApiProperties; import java.util.Objects; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/researcher/ResearcherPublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/researcher/ResearcherPublicModel.java index 047225a9b..d1507f326 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/researcher/ResearcherPublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/researcher/ResearcherPublicModel.java @@ -1,8 +1,8 @@ package org.opencdmp.model.publicapi.researcher; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; -import org.opencdmp.model.DmpReference; -import org.opencdmp.model.Reference; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.service.publicapi.PublicApiProperties; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/backend/core/src/main/java/org/opencdmp/model/publicapi/user/UserInfoPublicModel.java b/backend/core/src/main/java/org/opencdmp/model/publicapi/user/UserInfoPublicModel.java index d68e7f88e..66cfea071 100644 --- a/backend/core/src/main/java/org/opencdmp/model/publicapi/user/UserInfoPublicModel.java +++ b/backend/core/src/main/java/org/opencdmp/model/publicapi/user/UserInfoPublicModel.java @@ -1,7 +1,7 @@ package org.opencdmp.model.publicapi.user; import org.opencdmp.model.DmpUser; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/referencedefinition/Definition.java b/backend/core/src/main/java/org/opencdmp/model/reference/Definition.java similarity index 84% rename from backend/core/src/main/java/org/opencdmp/model/referencedefinition/Definition.java rename to backend/core/src/main/java/org/opencdmp/model/reference/Definition.java index 4bf54c52d..e958b4a2e 100644 --- a/backend/core/src/main/java/org/opencdmp/model/referencedefinition/Definition.java +++ b/backend/core/src/main/java/org/opencdmp/model/reference/Definition.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.referencedefinition; +package org.opencdmp.model.reference; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/referencedefinition/Field.java b/backend/core/src/main/java/org/opencdmp/model/reference/Field.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/referencedefinition/Field.java rename to backend/core/src/main/java/org/opencdmp/model/reference/Field.java index a42231557..07fdfac41 100644 --- a/backend/core/src/main/java/org/opencdmp/model/referencedefinition/Field.java +++ b/backend/core/src/main/java/org/opencdmp/model/reference/Field.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.referencedefinition; +package org.opencdmp.model.reference; import org.opencdmp.commons.enums.ReferenceFieldDataType; diff --git a/backend/core/src/main/java/org/opencdmp/model/Reference.java b/backend/core/src/main/java/org/opencdmp/model/reference/Reference.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/Reference.java rename to backend/core/src/main/java/org/opencdmp/model/reference/Reference.java index 8c5bc5fb8..13e325f2c 100644 --- a/backend/core/src/main/java/org/opencdmp/model/Reference.java +++ b/backend/core/src/main/java/org/opencdmp/model/reference/Reference.java @@ -1,8 +1,10 @@ -package org.opencdmp.model; +package org.opencdmp.model.reference; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.enums.ReferenceSourceType; -import org.opencdmp.model.referencedefinition.Definition; +import org.opencdmp.model.user.User; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.referencetype.ReferenceType; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/ReferenceType.java b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceType.java similarity index 95% rename from backend/core/src/main/java/org/opencdmp/model/ReferenceType.java rename to backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceType.java index a04b52786..8bcbcdb50 100644 --- a/backend/core/src/main/java/org/opencdmp/model/ReferenceType.java +++ b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceType.java @@ -1,7 +1,7 @@ -package org.opencdmp.model; +package org.opencdmp.model.referencetype; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.referencetypedefinition.ReferenceTypeDefinition; +import org.opencdmp.model.referencetype.ReferenceTypeDefinition; import java.time.Instant; import java.util.UUID; diff --git a/backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeDefinition.java b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeDefinition.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeDefinition.java rename to backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeDefinition.java index 3fa3d59bf..1d2d2a284 100644 --- a/backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeDefinition.java +++ b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeDefinition.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.referencetypedefinition; +package org.opencdmp.model.referencetype; import org.opencdmp.model.externalfetcher.ExternalFetcherBaseSourceConfiguration; diff --git a/backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeField.java b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeField.java similarity index 94% rename from backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeField.java rename to backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeField.java index 119ad86a7..94005fbd6 100644 --- a/backend/core/src/main/java/org/opencdmp/model/referencetypedefinition/ReferenceTypeField.java +++ b/backend/core/src/main/java/org/opencdmp/model/referencetype/ReferenceTypeField.java @@ -1,4 +1,4 @@ -package org.opencdmp.model.referencetypedefinition; +package org.opencdmp.model.referencetype; import org.opencdmp.commons.enums.ReferenceFieldDataType; diff --git a/backend/core/src/main/java/org/opencdmp/model/User.java b/backend/core/src/main/java/org/opencdmp/model/user/User.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/User.java rename to backend/core/src/main/java/org/opencdmp/model/user/User.java index 7d4cacfc1..068d81505 100644 --- a/backend/core/src/main/java/org/opencdmp/model/User.java +++ b/backend/core/src/main/java/org/opencdmp/model/user/User.java @@ -1,7 +1,10 @@ -package org.opencdmp.model; +package org.opencdmp.model.user; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.enums.UserSettingsType; +import org.opencdmp.model.TenantUser; +import org.opencdmp.model.UserContactInfo; +import org.opencdmp.model.usercredential.UserCredential; +import org.opencdmp.model.UserRole; import java.time.Instant; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/model/UserAdditionalInfo.java b/backend/core/src/main/java/org/opencdmp/model/user/UserAdditionalInfo.java similarity index 91% rename from backend/core/src/main/java/org/opencdmp/model/UserAdditionalInfo.java rename to backend/core/src/main/java/org/opencdmp/model/user/UserAdditionalInfo.java index 632dd39fa..df944c114 100644 --- a/backend/core/src/main/java/org/opencdmp/model/UserAdditionalInfo.java +++ b/backend/core/src/main/java/org/opencdmp/model/user/UserAdditionalInfo.java @@ -1,9 +1,6 @@ -package org.opencdmp.model; +package org.opencdmp.model.user; -import org.opencdmp.commons.enums.ContactInfoType; - -import java.time.Instant; -import java.util.UUID; +import org.opencdmp.model.reference.Reference; public class UserAdditionalInfo { private String avatarUrl; diff --git a/backend/core/src/main/java/org/opencdmp/model/UserCredential.java b/backend/core/src/main/java/org/opencdmp/model/usercredential/UserCredential.java similarity index 93% rename from backend/core/src/main/java/org/opencdmp/model/UserCredential.java rename to backend/core/src/main/java/org/opencdmp/model/usercredential/UserCredential.java index f94a1f544..dca39f786 100644 --- a/backend/core/src/main/java/org/opencdmp/model/UserCredential.java +++ b/backend/core/src/main/java/org/opencdmp/model/usercredential/UserCredential.java @@ -1,5 +1,6 @@ -package org.opencdmp.model; +package org.opencdmp.model.usercredential; +import org.opencdmp.model.user.User; import org.opencdmp.model.usercredential.UserCredentialData; import java.time.Instant; diff --git a/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java b/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java index fa6287afb..05687acae 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java @@ -4,12 +4,8 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.enums.ActionConfirmationStatus; import org.opencdmp.commons.enums.ActionConfirmationType; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.enums.LockTargetType; import org.opencdmp.data.ActionConfirmationEntity; -import org.opencdmp.data.LockEntity; -import org.opencdmp.data.TagEntity; -import org.opencdmp.model.ActionConfirmation; -import org.opencdmp.model.Tag; +import org.opencdmp.model.actionconfirmation.ActionConfirmation; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.tools.data.query.FieldResolver; import gr.cite.tools.data.query.QueryBase; diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java index 03af2b80b..c75b150b9 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java @@ -8,7 +8,7 @@ import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DmpDescriptionTemplateEntity; import org.opencdmp.data.DmpEntity; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.PublicDescription; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionReferenceQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionReferenceQuery.java index 3ea4f6f2e..2ec223b28 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionReferenceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionReferenceQuery.java @@ -4,12 +4,8 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.authorization.Permission; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.commons.scope.user.UserScope; -import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DescriptionReferenceEntity; -import org.opencdmp.data.DescriptionTagEntity; -import org.opencdmp.data.DmpDescriptionTemplateEntity; -import org.opencdmp.model.DescriptionReference; -import org.opencdmp.query.utils.BuildSubQueryInput; +import org.opencdmp.model.descriptionreference.DescriptionReference; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.query.FieldResolver; @@ -18,7 +14,6 @@ import gr.cite.tools.data.query.QueryContext; import jakarta.persistence.Tuple; import jakarta.persistence.criteria.CriteriaBuilder; import jakarta.persistence.criteria.Predicate; -import jakarta.persistence.criteria.Subquery; import org.springframework.beans.factory.config.ConfigurableBeanFactory; import org.springframework.context.annotation.Scope; import org.springframework.stereotype.Component; diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java index 69b1eaf35..40a51295a 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java @@ -9,8 +9,7 @@ import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.DescriptionTemplateEntity; import org.opencdmp.data.DmpDescriptionTemplateEntity; import org.opencdmp.data.DmpEntity; -import org.opencdmp.data.EntityDoiEntity; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.query.utils.BuildSubQueryInput; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateTypeQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateTypeQuery.java index f710d38e3..dc5ad6098 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateTypeQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateTypeQuery.java @@ -3,13 +3,9 @@ package org.opencdmp.query; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.enums.DescriptionTemplateTypeStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.scope.user.UserScope; -import org.opencdmp.data.DescriptionTemplateEntity; import org.opencdmp.data.DescriptionTemplateTypeEntity; -import org.opencdmp.model.DescriptionTemplate; import org.opencdmp.model.DescriptionTemplateType; import org.opencdmp.query.utils.QueryUtilsService; -import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.query.FieldResolver; import gr.cite.tools.data.query.QueryBase; import gr.cite.tools.data.query.QueryContext; diff --git a/backend/core/src/main/java/org/opencdmp/query/DmpBlueprintQuery.java b/backend/core/src/main/java/org/opencdmp/query/DmpBlueprintQuery.java index 6460bc77f..33ae54db7 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DmpBlueprintQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DmpBlueprintQuery.java @@ -4,9 +4,8 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.enums.DmpBlueprintStatus; import org.opencdmp.commons.enums.DmpBlueprintVersionStatus; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.DmpBlueprintEntity; -import org.opencdmp.model.DmpBlueprint; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.query.FieldResolver; diff --git a/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java b/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java index 38c9c5782..ab3805b59 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java @@ -5,7 +5,7 @@ import org.opencdmp.authorization.Permission; import org.opencdmp.commons.enums.*; import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.*; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.PublicDmp; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; diff --git a/backend/core/src/main/java/org/opencdmp/query/DmpReferenceQuery.java b/backend/core/src/main/java/org/opencdmp/query/DmpReferenceQuery.java index c5fcb6f4c..7d613d963 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DmpReferenceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DmpReferenceQuery.java @@ -7,7 +7,7 @@ import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.DmpEntity; import org.opencdmp.data.DmpReferenceEntity; import org.opencdmp.data.ReferenceEntity; -import org.opencdmp.model.DmpReference; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.model.PublicDmpReference; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.commons.web.authz.service.AuthorizationService; diff --git a/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java b/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java index 9e3fb6d0b..6ed274aa9 100644 --- a/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java @@ -3,7 +3,7 @@ package org.opencdmp.query; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.enums.IsActive; import org.opencdmp.data.PrefillingSourceEntity; -import org.opencdmp.model.PrefillingSource; +import org.opencdmp.model.prefillingsource.PrefillingSource; import org.opencdmp.query.utils.QueryUtilsService; import gr.cite.tools.data.query.FieldResolver; import gr.cite.tools.data.query.QueryBase; diff --git a/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java b/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java index 3fed9080c..e686affe7 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java @@ -17,7 +17,7 @@ import org.opencdmp.data.DmpEntity; import org.opencdmp.data.DmpReferenceEntity; import org.opencdmp.data.ReferenceEntity; import org.opencdmp.model.PublicReference; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.query.utils.BuildSubQueryInput; import org.opencdmp.query.utils.QueryUtilsService; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java b/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java index 9a1049e42..17fcdedc7 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java @@ -2,12 +2,10 @@ package org.opencdmp.query; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.ReferenceEntity; import org.opencdmp.data.ReferenceTypeEntity; -import org.opencdmp.model.ReferenceType; +import org.opencdmp.model.referencetype.ReferenceType; import org.opencdmp.query.utils.QueryUtilsService; -import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.query.FieldResolver; import gr.cite.tools.data.query.QueryBase; import gr.cite.tools.data.query.QueryContext; diff --git a/backend/core/src/main/java/org/opencdmp/query/UserCredentialQuery.java b/backend/core/src/main/java/org/opencdmp/query/UserCredentialQuery.java index 7f8215813..6b0ab9b43 100644 --- a/backend/core/src/main/java/org/opencdmp/query/UserCredentialQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/UserCredentialQuery.java @@ -4,7 +4,7 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.authorization.Permission; import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.data.UserCredentialEntity; -import org.opencdmp.model.UserCredential; +import org.opencdmp.model.usercredential.UserCredential; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.query.FieldResolver; import gr.cite.tools.data.query.QueryBase; diff --git a/backend/core/src/main/java/org/opencdmp/query/UserQuery.java b/backend/core/src/main/java/org/opencdmp/query/UserQuery.java index b433c9af4..bbd8e4fba 100644 --- a/backend/core/src/main/java/org/opencdmp/query/UserQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/UserQuery.java @@ -18,7 +18,7 @@ import org.opencdmp.data.UserContactInfoEntity; import org.opencdmp.data.UserEntity; import org.opencdmp.data.UserRoleEntity; import org.opencdmp.model.PublicUser; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.utils.BuildSubQueryInput; import org.opencdmp.query.utils.QueryUtilsService; import org.springframework.beans.factory.config.ConfigurableBeanFactory; diff --git a/backend/core/src/main/java/org/opencdmp/query/lookup/ReferenceSearchLookup.java b/backend/core/src/main/java/org/opencdmp/query/lookup/ReferenceSearchLookup.java index 499f59621..4399f7d3e 100644 --- a/backend/core/src/main/java/org/opencdmp/query/lookup/ReferenceSearchLookup.java +++ b/backend/core/src/main/java/org/opencdmp/query/lookup/ReferenceSearchLookup.java @@ -1,6 +1,6 @@ package org.opencdmp.query.lookup; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.query.ReferenceQuery; import gr.cite.tools.data.query.Lookup; import gr.cite.tools.data.query.QueryFactory; diff --git a/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationService.java b/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationService.java index 7c8a2f0b2..f045c76c8 100644 --- a/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationService.java +++ b/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationService.java @@ -1,6 +1,6 @@ package org.opencdmp.service.actionconfirmation; -import org.opencdmp.model.ActionConfirmation; +import org.opencdmp.model.actionconfirmation.ActionConfirmation; import org.opencdmp.model.persist.ActionConfirmationPersist; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.exception.MyForbiddenException; diff --git a/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationServiceImpl.java index 6e940edc1..a8fc436de 100644 --- a/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/actionconfirmation/ActionConfirmationServiceImpl.java @@ -12,9 +12,9 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.ActionConfirmationEntity; import org.opencdmp.data.TenantEntityManager; import org.opencdmp.errorcode.ErrorThesaurusProperties; -import org.opencdmp.model.ActionConfirmation; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.ActionConfirmationBuilder; +import org.opencdmp.model.actionconfirmation.ActionConfirmation; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.model.builder.actionconfirmation.ActionConfirmationBuilder; import org.opencdmp.model.deleter.ActionConfirmationDeleter; import org.opencdmp.model.persist.ActionConfirmationPersist; import org.opencdmp.model.persist.actionconfirmation.RemoveCredentialRequestPersist; diff --git a/backend/core/src/main/java/org/opencdmp/service/dashborad/DashboardServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/dashborad/DashboardServiceImpl.java index a5b4994ae..e3d720ec4 100644 --- a/backend/core/src/main/java/org/opencdmp/service/dashborad/DashboardServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/dashborad/DashboardServiceImpl.java @@ -11,6 +11,8 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.model.*; import org.opencdmp.model.builder.PublicReferenceTypeBuilder; import org.opencdmp.model.builder.RecentActivityItemBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.*; import org.opencdmp.query.lookup.DescriptionLookup; @@ -29,7 +31,6 @@ import org.springframework.stereotype.Service; import javax.management.InvalidApplicationException; import java.util.*; -import static org.opencdmp.authorization.AuthorizationFlags.Owner; import static org.opencdmp.authorization.AuthorizationFlags.Public; @Service diff --git a/backend/core/src/main/java/org/opencdmp/service/description/DescriptionService.java b/backend/core/src/main/java/org/opencdmp/service/description/DescriptionService.java index a712a112a..f5d5d308c 100644 --- a/backend/core/src/main/java/org/opencdmp/service/description/DescriptionService.java +++ b/backend/core/src/main/java/org/opencdmp/service/description/DescriptionService.java @@ -2,7 +2,7 @@ package org.opencdmp.service.description; import org.opencdmp.commons.types.description.importexport.DescriptionImportExport; import org.opencdmp.data.StorageFileEntity; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.DescriptionValidationResult; import org.opencdmp.model.StorageFile; import org.opencdmp.model.persist.*; @@ -13,7 +13,6 @@ import gr.cite.tools.exception.MyValidationException; import gr.cite.tools.fieldset.FieldSet; import jakarta.xml.bind.JAXBException; import org.springframework.http.ResponseEntity; -import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.multipart.MultipartFile; import org.xml.sax.SAXException; diff --git a/backend/core/src/main/java/org/opencdmp/service/description/DescriptionServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/description/DescriptionServiceImpl.java index 6354f01e8..8c63f9ef6 100644 --- a/backend/core/src/main/java/org/opencdmp/service/description/DescriptionServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/description/DescriptionServiceImpl.java @@ -42,15 +42,20 @@ import org.opencdmp.integrationevent.outbox.annotationentitytouch.AnnotationEnti import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEvent; import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEventHandler; import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionBuilder; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; import org.opencdmp.model.deleter.DescriptionDeleter; import org.opencdmp.model.deleter.DescriptionReferenceDeleter; import org.opencdmp.model.deleter.DescriptionTagDeleter; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.file.FileEnvelope; import org.opencdmp.model.persist.*; import org.opencdmp.model.persist.descriptionproperties.*; import org.opencdmp.model.persist.descriptionreference.DescriptionReferenceDataPersist; import org.opencdmp.model.persist.referencedefinition.DefinitionPersist; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; import org.opencdmp.query.*; import org.opencdmp.service.descriptiontemplate.DescriptionTemplateService; import org.opencdmp.service.elastic.ElasticService; diff --git a/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateService.java b/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateService.java index 930631f3b..7455fe80e 100644 --- a/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateService.java +++ b/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateService.java @@ -2,7 +2,7 @@ package org.opencdmp.service.descriptiontemplate; import com.fasterxml.jackson.core.JsonProcessingException; import org.opencdmp.commons.types.descriptiontemplate.importexport.DescriptionTemplateImportExport; -import org.opencdmp.model.DescriptionTemplate; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.model.persist.DescriptionTemplatePersist; import org.opencdmp.model.persist.NewVersionDescriptionTemplatePersist; import gr.cite.tools.exception.MyApplicationException; diff --git a/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateServiceImpl.java index 531b39bfd..a4254f031 100644 --- a/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/descriptiontemplate/DescriptionTemplateServiceImpl.java @@ -37,19 +37,19 @@ import org.opencdmp.errorcode.ErrorThesaurusProperties; import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEvent; import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEventHandler; import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionTemplateBuilder; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; import org.opencdmp.model.deleter.DescriptionTemplateDeleter; import org.opencdmp.model.deleter.UserDescriptionTemplateDeleter; -import org.opencdmp.model.descriptiontemplatedefinition.Definition; -import org.opencdmp.model.descriptiontemplatedefinition.Field; -import org.opencdmp.model.descriptiontemplatedefinition.Page; -import org.opencdmp.model.descriptiontemplatedefinition.Section; +import org.opencdmp.model.descriptiontemplate.*; import org.opencdmp.model.persist.DescriptionTemplatePersist; import org.opencdmp.model.persist.NewVersionDescriptionTemplatePersist; import org.opencdmp.model.persist.ReferencePersist; import org.opencdmp.model.persist.UserDescriptionTemplatePersist; import org.opencdmp.model.persist.descriptiontemplatedefinition.*; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.BaseFieldDataPersist; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.model.user.User; import org.opencdmp.query.*; import org.opencdmp.service.fielddatahelper.FieldDataHelperService; import org.opencdmp.service.fielddatahelper.FieldDataHelperServiceProvider; @@ -631,13 +631,13 @@ public class DescriptionTemplateServiceImpl implements DescriptionTemplateServic } } if (model.getFieldSets() != null) { - for (org.opencdmp.model.descriptiontemplatedefinition.FieldSet fieldSet : model.getFieldSets()) { + for (org.opencdmp.model.descriptiontemplate.FieldSet fieldSet : model.getFieldSets()) { this.reassignFieldSet(fieldSet); } } } - private void reassignFieldSet(org.opencdmp.model.descriptiontemplatedefinition.FieldSet model) { + private void reassignFieldSet(org.opencdmp.model.descriptiontemplate.FieldSet model) { if (model == null) return; model.setId(UUID.randomUUID().toString()); diff --git a/backend/core/src/main/java/org/opencdmp/service/dmp/DmpService.java b/backend/core/src/main/java/org/opencdmp/service/dmp/DmpService.java index 4eece384a..673a625c4 100644 --- a/backend/core/src/main/java/org/opencdmp/service/dmp/DmpService.java +++ b/backend/core/src/main/java/org/opencdmp/service/dmp/DmpService.java @@ -1,7 +1,7 @@ package org.opencdmp.service.dmp; import org.opencdmp.commons.types.dmp.importexport.DmpImportExport; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.DmpUser; import org.opencdmp.model.DmpValidationResult; import org.opencdmp.model.persist.*; diff --git a/backend/core/src/main/java/org/opencdmp/service/dmp/DmpServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/dmp/DmpServiceImpl.java index 968edbcfe..d82bec93b 100644 --- a/backend/core/src/main/java/org/opencdmp/service/dmp/DmpServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/dmp/DmpServiceImpl.java @@ -1,57 +1,6 @@ package org.opencdmp.service.dmp; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.authorization.Permission; -import org.opencdmp.authorization.authorizationcontentresolver.AuthorizationContentResolver; -import org.opencdmp.commons.JsonHandlingService; -import org.opencdmp.commons.XmlHandlingService; -import org.opencdmp.commons.enums.*; -import org.opencdmp.commons.enums.notification.NotificationContactType; -import org.opencdmp.commons.scope.tenant.TenantScope; -import org.opencdmp.commons.scope.user.UserScope; -import org.opencdmp.commons.types.actionconfirmation.DmpInvitationEntity; -import org.opencdmp.commons.types.description.importexport.DescriptionImportExport; -import org.opencdmp.commons.types.dmp.DmpBlueprintValueEntity; -import org.opencdmp.commons.types.dmp.DmpContactEntity; -import org.opencdmp.commons.types.dmp.DmpPropertiesEntity; -import org.opencdmp.commons.types.dmp.importexport.*; -import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; -import org.opencdmp.commons.types.dmpblueprint.SectionEntity; -import org.opencdmp.commons.types.dmpreference.DmpReferenceDataEntity; -import org.opencdmp.commons.types.notification.*; -import org.opencdmp.commons.types.reference.DefinitionEntity; -import org.opencdmp.commons.types.reference.FieldEntity; -import org.opencdmp.commons.notification.NotificationProperties; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.*; -import org.opencdmp.errorcode.ErrorThesaurusProperties; -import org.opencdmp.event.DmpTouchedEvent; -import org.opencdmp.event.EventBroker; -import org.opencdmp.integrationevent.outbox.annotationentityremoval.AnnotationEntityRemovalIntegrationEventHandler; -import org.opencdmp.integrationevent.outbox.annotationentitytouch.AnnotationEntityTouchedIntegrationEventHandler; -import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEvent; -import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEventHandler; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.DmpBuilder; -import org.opencdmp.model.builder.DmpUserBuilder; -import org.opencdmp.model.deleter.*; -import org.opencdmp.model.dmpreference.DmpReferenceData; -import org.opencdmp.model.file.FileEnvelope; -import org.opencdmp.model.persist.*; -import org.opencdmp.model.persist.actionconfirmation.DmpInvitationPersist; -import org.opencdmp.model.persist.dmpproperties.DmpBlueprintValuePersist; -import org.opencdmp.model.persist.dmpproperties.DmpContactPersist; -import org.opencdmp.model.persist.dmpproperties.DmpPropertiesPersist; -import org.opencdmp.model.persist.dmpreference.DmpReferenceDataPersist; -import org.opencdmp.model.persist.referencedefinition.DefinitionPersist; -import org.opencdmp.model.persist.referencedefinition.FieldPersist; -import org.opencdmp.query.*; -import org.opencdmp.service.actionconfirmation.ActionConfirmationService; -import org.opencdmp.service.description.DescriptionService; -import org.opencdmp.service.dmpblueprint.DmpBlueprintService; -import org.opencdmp.service.elastic.ElasticService; -import org.opencdmp.service.filetransformer.FileTransformerService; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.deleter.DeleterFactory; @@ -69,6 +18,63 @@ import gr.cite.tools.validation.ValidationFailure; import gr.cite.tools.validation.ValidatorFactory; import jakarta.xml.bind.JAXBException; import org.jetbrains.annotations.NotNull; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.authorization.Permission; +import org.opencdmp.authorization.authorizationcontentresolver.AuthorizationContentResolver; +import org.opencdmp.commons.JsonHandlingService; +import org.opencdmp.commons.XmlHandlingService; +import org.opencdmp.commons.enums.*; +import org.opencdmp.commons.enums.notification.NotificationContactType; +import org.opencdmp.commons.notification.NotificationProperties; +import org.opencdmp.commons.scope.tenant.TenantScope; +import org.opencdmp.commons.scope.user.UserScope; +import org.opencdmp.commons.types.actionconfirmation.DmpInvitationEntity; +import org.opencdmp.commons.types.description.importexport.DescriptionImportExport; +import org.opencdmp.commons.types.dmp.DmpBlueprintValueEntity; +import org.opencdmp.commons.types.dmp.DmpContactEntity; +import org.opencdmp.commons.types.dmp.DmpPropertiesEntity; +import org.opencdmp.commons.types.dmp.importexport.*; +import org.opencdmp.commons.types.dmpblueprint.ReferenceTypeFieldEntity; +import org.opencdmp.commons.types.dmpblueprint.SectionEntity; +import org.opencdmp.commons.types.dmpreference.DmpReferenceDataEntity; +import org.opencdmp.commons.types.notification.*; +import org.opencdmp.commons.types.reference.DefinitionEntity; +import org.opencdmp.commons.types.reference.FieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.*; +import org.opencdmp.errorcode.ErrorThesaurusProperties; +import org.opencdmp.event.DmpTouchedEvent; +import org.opencdmp.event.EventBroker; +import org.opencdmp.integrationevent.outbox.annotationentityremoval.AnnotationEntityRemovalIntegrationEventHandler; +import org.opencdmp.integrationevent.outbox.annotationentitytouch.AnnotationEntityTouchedIntegrationEventHandler; +import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEvent; +import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEventHandler; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.DmpValidationResult; +import org.opencdmp.model.UserContactInfo; +import org.opencdmp.model.builder.DmpUserBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.deleter.*; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.dmpreference.DmpReferenceData; +import org.opencdmp.model.file.FileEnvelope; +import org.opencdmp.model.persist.*; +import org.opencdmp.model.persist.actionconfirmation.DmpInvitationPersist; +import org.opencdmp.model.persist.dmpproperties.DmpBlueprintValuePersist; +import org.opencdmp.model.persist.dmpproperties.DmpContactPersist; +import org.opencdmp.model.persist.dmpproperties.DmpPropertiesPersist; +import org.opencdmp.model.persist.dmpreference.DmpReferenceDataPersist; +import org.opencdmp.model.persist.referencedefinition.DefinitionPersist; +import org.opencdmp.model.persist.referencedefinition.FieldPersist; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.query.*; +import org.opencdmp.service.actionconfirmation.ActionConfirmationService; +import org.opencdmp.service.description.DescriptionService; +import org.opencdmp.service.dmpblueprint.DmpBlueprintService; +import org.opencdmp.service.elastic.ElasticService; +import org.opencdmp.service.filetransformer.FileTransformerService; import org.opencdmp.service.responseutils.ResponseUtilsService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; diff --git a/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintService.java b/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintService.java index 5f861708a..89f66cdb5 100644 --- a/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintService.java +++ b/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintService.java @@ -4,7 +4,7 @@ import com.fasterxml.jackson.core.JsonProcessingException; import org.opencdmp.commons.enums.DmpBlueprintSystemFieldType; import org.opencdmp.commons.types.dmpblueprint.importexport.BlueprintImportExport; import org.opencdmp.data.DmpBlueprintEntity; -import org.opencdmp.model.DmpBlueprint; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import org.opencdmp.model.persist.DmpBlueprintPersist; import org.opencdmp.model.persist.NewVersionDmpBlueprintPersist; import gr.cite.tools.exception.MyApplicationException; diff --git a/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintServiceImpl.java index da6b9b497..dfdcc913a 100644 --- a/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/dmpblueprint/DmpBlueprintServiceImpl.java @@ -27,12 +27,12 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.DmpBlueprintEntity; import org.opencdmp.data.TenantEntityManager; import org.opencdmp.errorcode.ErrorThesaurusProperties; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.builder.DmpBlueprintBuilder; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.builder.dmpblueprint.DmpBlueprintBuilder; import org.opencdmp.model.deleter.DmpBlueprintDeleter; -import org.opencdmp.model.dmpblueprintdefinition.Definition; -import org.opencdmp.model.dmpblueprintdefinition.Field; -import org.opencdmp.model.dmpblueprintdefinition.Section; +import org.opencdmp.model.dmpblueprint.Definition; +import org.opencdmp.model.dmpblueprint.Field; +import org.opencdmp.model.dmpblueprint.Section; import org.opencdmp.model.persist.DmpBlueprintPersist; import org.opencdmp.model.persist.NewVersionDmpBlueprintPersist; import org.opencdmp.model.persist.dmpblueprintdefinition.*; diff --git a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperService.java b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperService.java index 900930c72..89e764e67 100644 --- a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperService.java @@ -2,6 +2,8 @@ package org.opencdmp.service.elastic; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.model.*; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.lookup.DescriptionLookup; import org.opencdmp.query.lookup.DmpLookup; diff --git a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperServiceImpl.java index 2844b43c4..dfab0972b 100644 --- a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticQueryHelperServiceImpl.java @@ -1,27 +1,27 @@ package org.opencdmp.service.elastic; +import gr.cite.tools.data.builder.BuilderFactory; +import gr.cite.tools.data.query.QueryFactory; +import gr.cite.tools.fieldset.BaseFieldSet; +import gr.cite.tools.fieldset.FieldSet; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.data.DescriptionEntity; import org.opencdmp.data.DmpEntity; import org.opencdmp.elastic.data.DescriptionElasticEntity; import org.opencdmp.elastic.data.DmpElasticEntity; -import org.opencdmp.model.Description; -import org.opencdmp.model.Dmp; import org.opencdmp.model.PublicDescription; import org.opencdmp.model.PublicDmp; -import org.opencdmp.model.builder.DescriptionBuilder; -import org.opencdmp.model.builder.DmpBuilder; import org.opencdmp.model.builder.PublicDescriptionBuilder; import org.opencdmp.model.builder.PublicDmpBuilder; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.DescriptionQuery; import org.opencdmp.query.DmpQuery; import org.opencdmp.query.lookup.DescriptionLookup; import org.opencdmp.query.lookup.DmpLookup; -import gr.cite.tools.data.builder.BuilderFactory; -import gr.cite.tools.data.query.QueryFactory; -import gr.cite.tools.fieldset.BaseFieldSet; -import gr.cite.tools.fieldset.FieldSet; import org.springframework.stereotype.Service; import java.util.EnumSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticServiceImpl.java index d7ae9ae1c..01735c9ed 100644 --- a/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/elastic/ElasticServiceImpl.java @@ -24,8 +24,8 @@ import org.opencdmp.elastic.data.DmpElasticEntity; import org.opencdmp.elastic.data.nested.*; import org.opencdmp.elastic.elasticbuilder.DescriptionElasticBuilder; import org.opencdmp.elastic.elasticbuilder.DmpElasticBuilder; -import org.opencdmp.model.Description; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.query.DescriptionQuery; import org.opencdmp.query.DmpQuery; import org.opencdmp.service.dmpblueprint.DmpBlueprintServiceImpl; diff --git a/backend/core/src/main/java/org/opencdmp/service/externalfetcher/ExternalFetcherServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/externalfetcher/ExternalFetcherServiceImpl.java index 63796c20c..a3e8ec9ad 100644 --- a/backend/core/src/main/java/org/opencdmp/service/externalfetcher/ExternalFetcherServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/externalfetcher/ExternalFetcherServiceImpl.java @@ -12,8 +12,8 @@ import org.opencdmp.commons.enums.ExternalFetcherSourceType; import org.opencdmp.commons.types.externalfetcher.StaticOptionEntity; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.ReferenceEntity; -import org.opencdmp.model.Reference; -import org.opencdmp.model.referencedefinition.Field; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.reference.Field; import org.opencdmp.service.externalfetcher.config.entities.*; import org.opencdmp.service.externalfetcher.criteria.ExternalReferenceCriteria; import org.opencdmp.service.externalfetcher.models.ExternalDataResult; diff --git a/backend/core/src/main/java/org/opencdmp/service/externalfetcher/criteria/ExternalReferenceCriteria.java b/backend/core/src/main/java/org/opencdmp/service/externalfetcher/criteria/ExternalReferenceCriteria.java index 1b24917ba..0d1e849bf 100644 --- a/backend/core/src/main/java/org/opencdmp/service/externalfetcher/criteria/ExternalReferenceCriteria.java +++ b/backend/core/src/main/java/org/opencdmp/service/externalfetcher/criteria/ExternalReferenceCriteria.java @@ -1,6 +1,6 @@ package org.opencdmp.service.externalfetcher.criteria; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import java.util.List; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/BaseFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/BaseFieldDataHelperService.java index 5181883d3..ec345423e 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/BaseFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/BaseFieldDataHelperService.java @@ -5,7 +5,7 @@ import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.BaseFieldDa import org.opencdmp.commons.enums.FieldType; import org.opencdmp.commons.types.descriptiontemplate.fielddata.BaseFieldDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.BaseFieldDataImportExport; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.BaseFieldData; +import org.opencdmp.model.descriptiontemplate.fielddata.BaseFieldData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.BaseFieldDataPersist; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/FieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/FieldDataHelperService.java index da335b332..82e125709 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/FieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/FieldDataHelperService.java @@ -5,7 +5,7 @@ import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.BaseFieldDa import org.opencdmp.commons.enums.FieldType; import org.opencdmp.commons.types.descriptiontemplate.fielddata.BaseFieldDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.BaseFieldDataImportExport; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.BaseFieldData; +import org.opencdmp.model.descriptiontemplate.fielddata.BaseFieldData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.BaseFieldDataPersist; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.validation.Validator; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelAndMultiplicityFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelAndMultiplicityFieldDataHelperService.java index 18cb0ff3a..7b45f1532 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelAndMultiplicityFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelAndMultiplicityFieldDataHelperService.java @@ -1,13 +1,12 @@ package org.opencdmp.service.fielddatahelper; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.BaseFieldDataModel; import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.LabelAndMultiplicityDataModel; import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.LabelAndMultiplicityDataImportExport; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.LabelAndMultiplicityDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.LabelAndMultiplicityDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.LabelAndMultiplicityData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.LabelAndMultiplicityDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.LabelAndMultiplicityData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.LabelAndMultiplicityDataPersist; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelFieldDataHelperService.java index c85b820ee..1d77776b2 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/LabelFieldDataHelperService.java @@ -9,8 +9,8 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.LabelDataImportExport; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.LabelDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.LabelDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.LabelData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.LabelDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.LabelData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.LabelDataPersist; import org.springframework.stereotype.Component; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/RadioBoxFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/RadioBoxFieldDataHelperService.java index 159e7d78a..67b5926af 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/RadioBoxFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/RadioBoxFieldDataHelperService.java @@ -1,16 +1,13 @@ package org.opencdmp.service.fielddatahelper; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.LabelAndMultiplicityDataModel; import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.RadioBoxDataModel; -import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.commons.types.descriptiontemplate.fielddata.RadioBoxDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.RadioBoxDataImportExport; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.LabelAndMultiplicityDataCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.RadioBoxDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.RadioBoxDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.RadioBoxData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.RadioBoxDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.RadioBoxData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/ReferenceTypeFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/ReferenceTypeFieldDataHelperService.java index bda89b8e7..8dc121395 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/ReferenceTypeFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/ReferenceTypeFieldDataHelperService.java @@ -5,8 +5,8 @@ import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.ReferenceTy import org.opencdmp.commons.types.descriptiontemplate.fielddata.ReferenceTypeDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.ReferenceTypeDataImportExport; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.ReferenceTypeDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.ReferenceTypeDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.ReferenceTypeData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.ReferenceTypeDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.ReferenceTypeData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.ReferenceTypeDataPersist; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/SelectFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/SelectFieldDataHelperService.java index aa72161c6..c0de9ad5e 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/SelectFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/SelectFieldDataHelperService.java @@ -1,16 +1,13 @@ package org.opencdmp.service.fielddatahelper; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.LabelAndMultiplicityDataModel; import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.SelectDataModel; -import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.commons.types.descriptiontemplate.fielddata.SelectDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.SelectDataImportExport; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.LabelAndMultiplicityDataCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.SelectDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.SelectDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.SelectData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.SelectDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.SelectData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/UploadFieldDataHelperService.java b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/UploadFieldDataHelperService.java index e25d54d1a..7ddc2a6ae 100644 --- a/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/UploadFieldDataHelperService.java +++ b/backend/core/src/main/java/org/opencdmp/service/fielddatahelper/UploadFieldDataHelperService.java @@ -1,16 +1,13 @@ package org.opencdmp.service.fielddatahelper; import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.LabelAndMultiplicityDataModel; import org.opencdmp.commonmodels.models.descriptiotemplate.fielddata.SelectDataModel; -import org.opencdmp.commons.types.descriptiontemplate.fielddata.LabelAndMultiplicityDataEntity; import org.opencdmp.commons.types.descriptiontemplate.fielddata.UploadDataEntity; import org.opencdmp.commons.types.descriptiontemplate.importexport.fielddata.UploadDataImportExport; import org.opencdmp.convention.ConventionService; -import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.LabelAndMultiplicityDataCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.descriptiontemplate.fielddata.UploadDataCommonModelBuilder; -import org.opencdmp.model.builder.descriptiontemplatedefinition.fielddata.UploadDataBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.UploadData; +import org.opencdmp.model.builder.descriptiontemplate.fielddata.UploadDataBuilder; +import org.opencdmp.model.descriptiontemplate.fielddata.UploadData; import org.opencdmp.model.persist.descriptiontemplatedefinition.fielddata.*; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.fieldset.FieldSet; diff --git a/backend/core/src/main/java/org/opencdmp/service/filetransformer/FileTransformerServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/filetransformer/FileTransformerServiceImpl.java index 72d8bbdbf..bea4f264d 100644 --- a/backend/core/src/main/java/org/opencdmp/service/filetransformer/FileTransformerServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/filetransformer/FileTransformerServiceImpl.java @@ -16,8 +16,8 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.TenantConfigurationEntity; import org.opencdmp.event.TenantConfigurationTouchedEvent; import org.opencdmp.filetransformerbase.interfaces.FileTransformerConfiguration; -import org.opencdmp.model.Description; -import org.opencdmp.model.Dmp; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmp.Dmp; import org.opencdmp.model.builder.commonmodels.description.DescriptionCommonModelBuilder; import org.opencdmp.model.builder.commonmodels.dmp.DmpCommonModelBuilder; import org.opencdmp.model.file.RepositoryFileFormat; diff --git a/backend/core/src/main/java/org/opencdmp/service/maintenance/MaintenanceServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/maintenance/MaintenanceServiceImpl.java index 3bccd8fc5..fadce5d69 100644 --- a/backend/core/src/main/java/org/opencdmp/service/maintenance/MaintenanceServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/maintenance/MaintenanceServiceImpl.java @@ -11,7 +11,7 @@ import org.opencdmp.integrationevent.outbox.tenanttouched.TenantTouchedIntegrati import org.opencdmp.integrationevent.outbox.userremoval.UserRemovalIntegrationEventHandler; import org.opencdmp.integrationevent.outbox.usertouched.UserTouchedIntegrationEventHandler; import org.opencdmp.model.Tenant; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.query.TenantQuery; import org.opencdmp.query.UserQuery; import gr.cite.commons.web.authz.service.AuthorizationService; diff --git a/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceService.java b/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceService.java index d981e8760..69d798d29 100644 --- a/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceService.java +++ b/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceService.java @@ -1,8 +1,8 @@ package org.opencdmp.service.prefillingsource; -import org.opencdmp.model.Description; +import org.opencdmp.model.description.Description; import org.opencdmp.model.Prefilling; -import org.opencdmp.model.PrefillingSource; +import org.opencdmp.model.prefillingsource.PrefillingSource; import org.opencdmp.model.persist.PrefillingSearchRequest; import org.opencdmp.model.persist.DescriptionPrefillingRequest; import org.opencdmp.model.persist.PrefillingSourcePersist; diff --git a/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceServiceImpl.java index 75092c22b..c2a71bafd 100644 --- a/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/prefillingsource/PrefillingSourceServiceImpl.java @@ -34,12 +34,16 @@ import org.opencdmp.data.DescriptionTemplateEntity; import org.opencdmp.data.PrefillingSourceEntity; import org.opencdmp.data.TenantEntityManager; import org.opencdmp.errorcode.ErrorThesaurusProperties; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionTemplateBuilder; -import org.opencdmp.model.builder.PrefillingSourceBuilder; +import org.opencdmp.model.DescriptionTag; +import org.opencdmp.model.Prefilling; +import org.opencdmp.model.Tag; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; +import org.opencdmp.model.builder.prefillingsource.PrefillingSourceBuilder; import org.opencdmp.model.deleter.PrefillingSourceDeleter; -import org.opencdmp.model.descriptionproperties.*; +import org.opencdmp.model.description.*; +import org.opencdmp.model.descriptionreference.DescriptionReference; import org.opencdmp.model.descriptionreference.DescriptionReferenceData; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; import org.opencdmp.model.persist.DescriptionPrefillingRequest; import org.opencdmp.model.persist.PrefillingSearchRequest; import org.opencdmp.model.persist.PrefillingSourcePersist; @@ -47,8 +51,11 @@ import org.opencdmp.model.persist.externalfetcher.*; import org.opencdmp.model.persist.prefillingsourcedefinition.PrefillingSourceDefinitionFieldPersist; import org.opencdmp.model.persist.prefillingsourcedefinition.PrefillingSourceDefinitionFixedValueFieldPersist; import org.opencdmp.model.persist.prefillingsourcedefinition.PrefillingSourceDefinitionPersist; -import org.opencdmp.model.prefillingsourcedefinition.PrefillingSourceDefinition; -import org.opencdmp.model.referencedefinition.Definition; +import org.opencdmp.model.prefillingsource.PrefillingSource; +import org.opencdmp.model.prefillingsource.PrefillingSourceDefinition; +import org.opencdmp.model.reference.Definition; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; import org.opencdmp.query.PrefillingSourceQuery; import org.opencdmp.query.lookup.ReferenceSearchLookup; import org.opencdmp.service.externalfetcher.ExternalFetcherService; @@ -554,9 +561,9 @@ public class PrefillingSourceServiceImpl implements PrefillingSourceService { .ensure(Reference._type) .ensure(this.conventionService.asIndexer(Reference._type, ReferenceType._id)) .ensure(Reference._description) - .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.referencedefinition.Field._code)) - .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.referencedefinition.Field._dataType)) - .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.referencedefinition.Field._value)) + .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.reference.Field._code)) + .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.reference.Field._dataType)) + .ensure(this.conventionService.asIndexer(Reference._description, Definition._fields, org.opencdmp.model.reference.Field._value)) .ensure(Reference._reference) .ensure(Reference._sourceType) .ensure(Reference._abbreviation) diff --git a/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceService.java b/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceService.java index ac53edf57..69c5da0bd 100644 --- a/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceService.java +++ b/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceService.java @@ -1,7 +1,7 @@ package org.opencdmp.service.reference; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.model.Reference; +import org.opencdmp.model.reference.Reference; import org.opencdmp.model.persist.ReferencePersist; import org.opencdmp.query.lookup.ReferenceSearchLookup; import gr.cite.tools.exception.MyApplicationException; diff --git a/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceServiceImpl.java index af4820347..42fc18a9c 100644 --- a/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/reference/ReferenceServiceImpl.java @@ -1,32 +1,6 @@ package org.opencdmp.service.reference; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.authorization.Permission; -import org.opencdmp.commons.XmlHandlingService; -import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.enums.ReferenceFieldDataType; -import org.opencdmp.commons.enums.ReferenceSourceType; -import org.opencdmp.commons.types.reference.DefinitionEntity; -import org.opencdmp.commons.types.reference.FieldEntity; -import org.opencdmp.commons.types.referencetype.*; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.ReferenceEntity; -import org.opencdmp.data.ReferenceTypeEntity; -import org.opencdmp.data.TenantEntityManager; -import org.opencdmp.model.Reference; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.ReferenceBuilder; -import org.opencdmp.model.deleter.ReferenceDeleter; -import org.opencdmp.model.persist.ReferencePersist; -import org.opencdmp.model.persist.referencedefinition.DefinitionPersist; -import org.opencdmp.model.persist.referencedefinition.FieldPersist; -import org.opencdmp.query.ReferenceQuery; -import org.opencdmp.query.lookup.ReferenceSearchLookup; -import org.opencdmp.service.externalfetcher.ExternalFetcherService; -import org.opencdmp.service.externalfetcher.config.entities.SourceBaseConfiguration; -import org.opencdmp.service.externalfetcher.criteria.ExternalReferenceCriteria; -import org.opencdmp.service.externalfetcher.models.ExternalDataResult; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.deleter.DeleterFactory; @@ -39,9 +13,34 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import gr.cite.tools.logging.MapLogEntry; -import jakarta.persistence.EntityManager; import jakarta.xml.bind.JAXBException; import org.jetbrains.annotations.NotNull; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.authorization.Permission; +import org.opencdmp.commons.XmlHandlingService; +import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.commons.enums.ReferenceFieldDataType; +import org.opencdmp.commons.enums.ReferenceSourceType; +import org.opencdmp.commons.types.reference.DefinitionEntity; +import org.opencdmp.commons.types.reference.FieldEntity; +import org.opencdmp.commons.types.referencetype.ReferenceTypeDefinitionEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.ReferenceEntity; +import org.opencdmp.data.ReferenceTypeEntity; +import org.opencdmp.data.TenantEntityManager; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.deleter.ReferenceDeleter; +import org.opencdmp.model.persist.ReferencePersist; +import org.opencdmp.model.persist.referencedefinition.DefinitionPersist; +import org.opencdmp.model.persist.referencedefinition.FieldPersist; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.query.ReferenceQuery; +import org.opencdmp.query.lookup.ReferenceSearchLookup; +import org.opencdmp.service.externalfetcher.ExternalFetcherService; +import org.opencdmp.service.externalfetcher.config.entities.SourceBaseConfiguration; +import org.opencdmp.service.externalfetcher.criteria.ExternalReferenceCriteria; +import org.opencdmp.service.externalfetcher.models.ExternalDataResult; import org.slf4j.LoggerFactory; import org.springframework.context.MessageSource; import org.springframework.context.i18n.LocaleContextHolder; @@ -100,7 +99,7 @@ public class ReferenceServiceImpl implements ReferenceService { if (isUpdate) { data = this.entityManager.find(ReferenceEntity.class, model.getId()); if (data == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{model.getId(), Reference.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{model.getId(), Reference.class.getSimpleName()}, LocaleContextHolder.getLocale())); } else { data = new ReferenceEntity(); data.setId(UUID.randomUUID()); @@ -176,7 +175,7 @@ public class ReferenceServiceImpl implements ReferenceService { } ReferenceTypeEntity data = this.entityManager.find(ReferenceTypeEntity.class, lookup.getTypeId()); - if (data == null) throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{lookup.getTypeId(), ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); + if (data == null) throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{lookup.getTypeId(), ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); String like; if (lookup.getLike() != null){ @@ -192,8 +191,8 @@ public class ReferenceServiceImpl implements ReferenceService { if (remoteRepos != null && !this.conventionService.isListNullOrEmpty(remoteRepos.getResults())){ List referenceEntities = new ArrayList<>(); for (Map result : remoteRepos.getResults()){ - if (result == null || result.isEmpty()) continue;; - ReferenceEntity referenceEntity = buildReferenceEntityFromExternalData(result, data); + if (result == null || result.isEmpty()) continue; + ReferenceEntity referenceEntity = this.buildReferenceEntityFromExternalData(result, data); referenceEntities.add(referenceEntity); } externalModels = this.builderFactory.builder(ReferenceBuilder.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).build(lookup.getProject(), referenceEntities); diff --git a/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeService.java b/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeService.java index 85ceb72a1..ceab2bc2a 100644 --- a/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeService.java +++ b/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeService.java @@ -1,6 +1,6 @@ package org.opencdmp.service.referencetype; -import org.opencdmp.model.ReferenceType; +import org.opencdmp.model.referencetype.ReferenceType; import org.opencdmp.model.persist.ReferenceTypePersist; import gr.cite.tools.exception.MyApplicationException; import gr.cite.tools.exception.MyForbiddenException; diff --git a/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeServiceImpl.java index 4f5bda572..0596fcc1b 100644 --- a/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/referencetype/ReferenceTypeServiceImpl.java @@ -1,22 +1,5 @@ package org.opencdmp.service.referencetype; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.authorization.Permission; -import org.opencdmp.commons.XmlHandlingService; -import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.commons.enums.ExternalFetcherSourceType; -import org.opencdmp.commons.types.externalfetcher.*; -import org.opencdmp.commons.types.referencetype.*; -import org.opencdmp.convention.ConventionService; -import org.opencdmp.data.ReferenceTypeEntity; -import org.opencdmp.data.TenantEntityManager; -import org.opencdmp.errorcode.ErrorThesaurusProperties; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.deleter.ReferenceTypeDeleter; -import org.opencdmp.model.persist.ReferenceTypePersist; -import org.opencdmp.model.persist.externalfetcher.*; -import org.opencdmp.model.persist.referencetypedefinition.*; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.deleter.DeleterFactory; @@ -30,6 +13,25 @@ import gr.cite.tools.logging.LoggerService; import gr.cite.tools.logging.MapLogEntry; import jakarta.xml.bind.JAXBException; import org.jetbrains.annotations.NotNull; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.authorization.Permission; +import org.opencdmp.commons.XmlHandlingService; +import org.opencdmp.commons.enums.ExternalFetcherSourceType; +import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.commons.types.externalfetcher.*; +import org.opencdmp.commons.types.referencetype.ReferenceTypeDefinitionEntity; +import org.opencdmp.commons.types.referencetype.ReferenceTypeFieldEntity; +import org.opencdmp.convention.ConventionService; +import org.opencdmp.data.ReferenceTypeEntity; +import org.opencdmp.data.TenantEntityManager; +import org.opencdmp.errorcode.ErrorThesaurusProperties; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.deleter.ReferenceTypeDeleter; +import org.opencdmp.model.persist.ReferenceTypePersist; +import org.opencdmp.model.persist.externalfetcher.*; +import org.opencdmp.model.persist.referencetypedefinition.ReferenceTypeDefinitionPersist; +import org.opencdmp.model.persist.referencetypedefinition.ReferenceTypeFieldPersist; +import org.opencdmp.model.referencetype.ReferenceType; import org.slf4j.LoggerFactory; import org.springframework.context.MessageSource; import org.springframework.context.i18n.LocaleContextHolder; @@ -82,7 +84,7 @@ public class ReferenceTypeServiceImpl implements ReferenceTypeService { if (isUpdate) { data = this.entityManager.find(ReferenceTypeEntity.class, model.getId()); if (data == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{model.getId(), ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{model.getId(), ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); if (!this.conventionService.hashValue(data.getUpdatedAt()).equals(model.getHash())) throw new MyValidationException(this.errors.getHashConflict().getCode(), this.errors.getHashConflict().getMessage()); } else { diff --git a/backend/core/src/main/java/org/opencdmp/service/user/UserService.java b/backend/core/src/main/java/org/opencdmp/service/user/UserService.java index e943543e7..458de6b83 100644 --- a/backend/core/src/main/java/org/opencdmp/service/user/UserService.java +++ b/backend/core/src/main/java/org/opencdmp/service/user/UserService.java @@ -1,7 +1,7 @@ package org.opencdmp.service.user; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.model.persist.actionconfirmation.RemoveCredentialRequestPersist; import org.opencdmp.model.persist.UserMergeRequestPersist; import org.opencdmp.model.persist.UserPersist; diff --git a/backend/core/src/main/java/org/opencdmp/service/user/UserServiceImpl.java b/backend/core/src/main/java/org/opencdmp/service/user/UserServiceImpl.java index 60ece70cb..b532fc80c 100644 --- a/backend/core/src/main/java/org/opencdmp/service/user/UserServiceImpl.java +++ b/backend/core/src/main/java/org/opencdmp/service/user/UserServiceImpl.java @@ -29,9 +29,9 @@ import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEvent; import org.opencdmp.integrationevent.outbox.notification.NotifyIntegrationEventHandler; import org.opencdmp.integrationevent.outbox.userremoval.UserRemovalIntegrationEventHandler; import org.opencdmp.integrationevent.outbox.usertouched.UserTouchedIntegrationEventHandler; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.model.UserContactInfo; -import org.opencdmp.model.UserCredential; +import org.opencdmp.model.usercredential.UserCredential; import org.opencdmp.model.builder.UserBuilder; import org.opencdmp.model.deleter.*; import org.opencdmp.model.persist.*; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/DashboardController.java b/backend/web/src/main/java/org/opencdmp/controllers/DashboardController.java index b77c946fc..d5e7c0119 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/DashboardController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/DashboardController.java @@ -4,6 +4,7 @@ import org.opencdmp.audit.AuditableAction; import org.opencdmp.commons.scope.user.UserScope; import org.opencdmp.model.*; import org.opencdmp.model.censorship.*; +import org.opencdmp.model.user.User; import org.opencdmp.service.dashborad.DashboardService; import gr.cite.tools.auditing.AuditService; import gr.cite.tools.data.censor.CensorFactory; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/DescriptionController.java b/backend/web/src/main/java/org/opencdmp/controllers/DescriptionController.java index 727ad05ec..b7990eafd 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/DescriptionController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/DescriptionController.java @@ -20,10 +20,12 @@ import org.opencdmp.commons.enums.IsActive; import org.opencdmp.convention.ConventionService; import org.opencdmp.data.StorageFileEntity; import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionBuilder; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; import org.opencdmp.model.builder.PublicDescriptionBuilder; -import org.opencdmp.model.censorship.DescriptionCensor; +import org.opencdmp.model.censorship.description.DescriptionCensor; import org.opencdmp.model.censorship.PublicDescriptionCensor; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; import org.opencdmp.model.persist.*; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.DescriptionQuery; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/DescriptionTemplateController.java b/backend/web/src/main/java/org/opencdmp/controllers/DescriptionTemplateController.java index 42b5104e0..0876724aa 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/DescriptionTemplateController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/DescriptionTemplateController.java @@ -17,11 +17,11 @@ import jakarta.xml.bind.JAXBException; import org.opencdmp.audit.AuditableAction; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.data.DescriptionTemplateEntity; -import org.opencdmp.model.DescriptionTemplate; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.builder.DescriptionTemplateBuilder; -import org.opencdmp.model.censorship.DescriptionTemplateCensor; -import org.opencdmp.model.censorship.DmpBlueprintCensor; +import org.opencdmp.model.descriptiontemplate.DescriptionTemplate; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.builder.descriptiontemplate.DescriptionTemplateBuilder; +import org.opencdmp.model.censorship.descriptiontemplate.DescriptionTemplateCensor; +import org.opencdmp.model.censorship.dmpblueprint.DmpBlueprintCensor; import org.opencdmp.model.persist.DescriptionTemplatePersist; import org.opencdmp.model.persist.NewVersionDescriptionTemplatePersist; import org.opencdmp.model.result.QueryResult; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/DmpBlueprintController.java b/backend/web/src/main/java/org/opencdmp/controllers/DmpBlueprintController.java index 4b33cf66e..10adeae2b 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/DmpBlueprintController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/DmpBlueprintController.java @@ -6,9 +6,9 @@ import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.model.persist.NewVersionDmpBlueprintPersist; import gr.cite.tools.validation.ValidationFilterAnnotation; import org.opencdmp.data.DmpBlueprintEntity; -import org.opencdmp.model.DmpBlueprint; -import org.opencdmp.model.builder.DmpBlueprintBuilder; -import org.opencdmp.model.censorship.DmpBlueprintCensor; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.builder.dmpblueprint.DmpBlueprintBuilder; +import org.opencdmp.model.censorship.dmpblueprint.DmpBlueprintCensor; import org.opencdmp.model.persist.DmpBlueprintPersist; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.DmpBlueprintQuery; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/DmpController.java b/backend/web/src/main/java/org/opencdmp/controllers/DmpController.java index 1e939793a..97dae8443 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/DmpController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/DmpController.java @@ -1,22 +1,5 @@ package org.opencdmp.controllers; -import org.opencdmp.audit.AuditableAction; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.DmpAccessType; -import org.opencdmp.commons.enums.DmpStatus; -import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.model.builder.PublicDmpBuilder; -import gr.cite.tools.validation.ValidationFilterAnnotation; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.DmpBuilder; -import org.opencdmp.model.censorship.DmpCensor; -import org.opencdmp.model.censorship.PublicDmpCensor; -import org.opencdmp.model.persist.*; -import org.opencdmp.model.result.QueryResult; -import org.opencdmp.query.DmpQuery; -import org.opencdmp.query.lookup.DmpLookup; -import org.opencdmp.service.dmp.DmpService; -import org.opencdmp.service.elastic.ElasticQueryHelperService; import gr.cite.tools.auditing.AuditService; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.censor.CensorFactory; @@ -27,7 +10,29 @@ import gr.cite.tools.exception.MyNotFoundException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import gr.cite.tools.logging.MapLogEntry; +import gr.cite.tools.validation.ValidationFilterAnnotation; import jakarta.xml.bind.JAXBException; +import org.opencdmp.audit.AuditableAction; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.DmpAccessType; +import org.opencdmp.commons.enums.DmpStatus; +import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.model.DescriptionsToBeFinalized; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.DmpValidationResult; +import org.opencdmp.model.PublicDmp; +import org.opencdmp.model.builder.PublicDmpBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.censorship.PublicDmpCensor; +import org.opencdmp.model.censorship.dmp.DmpCensor; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpblueprint.DmpBlueprint; +import org.opencdmp.model.persist.*; +import org.opencdmp.model.result.QueryResult; +import org.opencdmp.query.DmpQuery; +import org.opencdmp.query.lookup.DmpLookup; +import org.opencdmp.service.dmp.DmpService; +import org.opencdmp.service.elastic.ElasticQueryHelperService; import org.slf4j.LoggerFactory; import org.springframework.context.MessageSource; import org.springframework.context.i18n.LocaleContextHolder; @@ -110,7 +115,7 @@ public class DmpController { DmpQuery query = this.queryFactory.query(DmpQuery.class).authorize(EnumSet.of(Public)).ids(id).isActive(IsActive.Active).statuses(DmpStatus.Finalized).accessTypes(DmpAccessType.Public); PublicDmp model = this.builderFactory.builder(PublicDmpBuilder.class).authorize(EnumSet.of(Public)).build(fieldSet, query.firstAs(fieldSet)); - if (model == null) throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); + if (model == null) throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); this.auditService.track(AuditableAction.Dmp_PublicLookup, Map.ofEntries( new AbstractMap.SimpleEntry("id", id), @@ -142,7 +147,7 @@ public class DmpController { DmpQuery query = this.queryFactory.query(DmpQuery.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).ids(id); Dmp model = this.builderFactory.builder(DmpBuilder.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).build(fieldSet, query.firstAs(fieldSet)); if (model == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); this.auditService.track(AuditableAction.Dmp_Lookup, Map.ofEntries( new AbstractMap.SimpleEntry("id", id), @@ -332,7 +337,7 @@ public class DmpController { return true; } - @RequestMapping(method = RequestMethod.GET, value = {"/xml/export/{id}"}, produces = "application/xml") + @RequestMapping(method = RequestMethod.GET, value = "/xml/export/{id}", produces = "application/xml") public @ResponseBody ResponseEntity getXml(@PathVariable UUID id) throws JAXBException, ParserConfigurationException, IOException, InstantiationException, IllegalAccessException, SAXException, InvalidApplicationException { logger.debug(new MapLogEntry("export" + DmpBlueprint.class.getSimpleName()).And("id", id)); diff --git a/backend/web/src/main/java/org/opencdmp/controllers/PrefillingSourceController.java b/backend/web/src/main/java/org/opencdmp/controllers/PrefillingSourceController.java index 218b8a1ad..5c35e0923 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/PrefillingSourceController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/PrefillingSourceController.java @@ -17,16 +17,16 @@ import jakarta.xml.bind.JAXBException; import org.opencdmp.audit.AuditableAction; import org.opencdmp.authorization.AuthorizationFlags; import org.opencdmp.data.PrefillingSourceEntity; -import org.opencdmp.model.Description; import org.opencdmp.model.Prefilling; -import org.opencdmp.model.PrefillingSource; -import org.opencdmp.model.builder.PrefillingSourceBuilder; -import org.opencdmp.model.censorship.DescriptionCensor; -import org.opencdmp.model.censorship.PrefillingCensor; -import org.opencdmp.model.censorship.PrefillingSourceCensor; +import org.opencdmp.model.builder.prefillingsource.PrefillingSourceBuilder; +import org.opencdmp.model.censorship.description.DescriptionCensor; +import org.opencdmp.model.censorship.prefillingsource.PrefillingCensor; +import org.opencdmp.model.censorship.prefillingsource.PrefillingSourceCensor; +import org.opencdmp.model.description.Description; import org.opencdmp.model.persist.DescriptionPrefillingRequest; import org.opencdmp.model.persist.PrefillingSearchRequest; import org.opencdmp.model.persist.PrefillingSourcePersist; +import org.opencdmp.model.prefillingsource.PrefillingSource; import org.opencdmp.model.result.QueryResult; import org.opencdmp.query.PrefillingSourceQuery; import org.opencdmp.query.lookup.PrefillingSourceLookup; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/ReferenceController.java b/backend/web/src/main/java/org/opencdmp/controllers/ReferenceController.java index 33b9d4a88..eebfff896 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/ReferenceController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/ReferenceController.java @@ -1,18 +1,6 @@ package org.opencdmp.controllers; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.audit.AuditableAction; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.data.ReferenceEntity; -import org.opencdmp.model.Reference; -import org.opencdmp.model.builder.ReferenceBuilder; -import org.opencdmp.model.censorship.ReferenceCensor; -import org.opencdmp.model.persist.ReferencePersist; -import org.opencdmp.model.result.QueryResult; -import org.opencdmp.query.ReferenceQuery; -import org.opencdmp.query.lookup.ReferenceLookup; -import org.opencdmp.query.lookup.ReferenceSearchLookup; -import org.opencdmp.service.reference.ReferenceService; import gr.cite.tools.auditing.AuditService; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.censor.CensorFactory; @@ -26,6 +14,18 @@ import gr.cite.tools.logging.MapLogEntry; import gr.cite.tools.validation.ValidationFilterAnnotation; import jakarta.transaction.Transactional; import jakarta.xml.bind.JAXBException; +import org.opencdmp.audit.AuditableAction; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.data.ReferenceEntity; +import org.opencdmp.model.builder.reference.ReferenceBuilder; +import org.opencdmp.model.censorship.reference.ReferenceCensor; +import org.opencdmp.model.persist.ReferencePersist; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.result.QueryResult; +import org.opencdmp.query.ReferenceQuery; +import org.opencdmp.query.lookup.ReferenceLookup; +import org.opencdmp.query.lookup.ReferenceSearchLookup; +import org.opencdmp.service.reference.ReferenceService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.MessageSource; @@ -41,7 +41,7 @@ import java.util.Map; import java.util.UUID; @RestController -@RequestMapping(path = {"api/reference"}) +@RequestMapping(path = "api/reference") public class ReferenceController { private static final LoggerService logger = new LoggerService(LoggerFactory.getLogger(ReferenceController.class)); @@ -127,7 +127,7 @@ public class ReferenceController { ReferenceQuery query = this.queryFactory.query(ReferenceQuery.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).ids(id); Reference model = this.builderFactory.builder(ReferenceBuilder.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).build(fieldSet, query.firstAs(fieldSet)); if (model == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{id, Reference.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{id, Reference.class.getSimpleName()}, LocaleContextHolder.getLocale())); this.auditService.track(AuditableAction.Reference_Lookup, Map.ofEntries( new AbstractMap.SimpleEntry("id", id), diff --git a/backend/web/src/main/java/org/opencdmp/controllers/ReferenceTypeController.java b/backend/web/src/main/java/org/opencdmp/controllers/ReferenceTypeController.java index 95dc217cf..ba73e7513 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/ReferenceTypeController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/ReferenceTypeController.java @@ -1,18 +1,6 @@ package org.opencdmp.controllers; import com.fasterxml.jackson.core.JsonProcessingException; -import org.opencdmp.audit.AuditableAction; -import org.opencdmp.authorization.AuthorizationFlags; -import gr.cite.tools.validation.ValidationFilterAnnotation; -import org.opencdmp.data.ReferenceTypeEntity; -import org.opencdmp.model.ReferenceType; -import org.opencdmp.model.builder.ReferenceTypeBuilder; -import org.opencdmp.model.censorship.ReferenceTypeCensor; -import org.opencdmp.model.persist.ReferenceTypePersist; -import org.opencdmp.model.result.QueryResult; -import org.opencdmp.query.ReferenceTypeQuery; -import org.opencdmp.query.lookup.ReferenceTypeLookup; -import org.opencdmp.service.referencetype.ReferenceTypeService; import gr.cite.commons.web.authz.service.AuthorizationService; import gr.cite.tools.auditing.AuditService; import gr.cite.tools.data.builder.BuilderFactory; @@ -24,8 +12,20 @@ import gr.cite.tools.exception.MyNotFoundException; import gr.cite.tools.fieldset.FieldSet; import gr.cite.tools.logging.LoggerService; import gr.cite.tools.logging.MapLogEntry; +import gr.cite.tools.validation.ValidationFilterAnnotation; import jakarta.transaction.Transactional; import jakarta.xml.bind.JAXBException; +import org.opencdmp.audit.AuditableAction; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.data.ReferenceTypeEntity; +import org.opencdmp.model.builder.referencetype.ReferenceTypeBuilder; +import org.opencdmp.model.censorship.referencetype.ReferenceTypeCensor; +import org.opencdmp.model.persist.ReferenceTypePersist; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.model.result.QueryResult; +import org.opencdmp.query.ReferenceTypeQuery; +import org.opencdmp.query.lookup.ReferenceTypeLookup; +import org.opencdmp.service.referencetype.ReferenceTypeService; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.MessageSource; @@ -39,7 +39,7 @@ import java.util.Map; import java.util.UUID; @RestController -@RequestMapping(path = {"api/reference-type"}) +@RequestMapping(path = "api/reference-type") public class ReferenceTypeController{ private static final LoggerService logger = new LoggerService(LoggerFactory.getLogger(ReferenceTypeController.class)); @@ -99,7 +99,7 @@ public class ReferenceTypeController{ ReferenceTypeQuery query = this.queryFactory.query(ReferenceTypeQuery.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).ids(id); ReferenceType model = this.builderFactory.builder(ReferenceTypeBuilder.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).build(fieldSet, query.firstAs(fieldSet)); if (model == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{id, ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{id, ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); this.auditService.track(AuditableAction.ReferenceType_Lookup, Map.ofEntries( new AbstractMap.SimpleEntry("id", id), @@ -118,7 +118,7 @@ public class ReferenceTypeController{ ReferenceTypeQuery query = this.queryFactory.query(ReferenceTypeQuery.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).codes(code); ReferenceType model = this.builderFactory.builder(ReferenceTypeBuilder.class).authorize(AuthorizationFlags.OwnerOrDmpAssociatedOrPermission).build(fieldSet, query.firstAs(fieldSet)); if (model == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{code, ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{code, ReferenceType.class.getSimpleName()}, LocaleContextHolder.getLocale())); this.auditService.track(AuditableAction.ReferenceType_Lookup, Map.ofEntries( new AbstractMap.SimpleEntry("code", code), diff --git a/backend/web/src/main/java/org/opencdmp/controllers/UserController.java b/backend/web/src/main/java/org/opencdmp/controllers/UserController.java index 78fbbd99c..75bd50747 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/UserController.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/UserController.java @@ -8,7 +8,7 @@ import org.opencdmp.commons.scope.user.UserScope; import gr.cite.tools.validation.ValidationFilterAnnotation; import org.opencdmp.data.UserEntity; import org.opencdmp.model.DmpAssociatedUser; -import org.opencdmp.model.User; +import org.opencdmp.model.user.User; import org.opencdmp.model.UserRole; import org.opencdmp.model.builder.DmpAssociatedUserBuilder; import org.opencdmp.model.builder.UserBuilder; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDatasetsDescriptionDocumentation.java b/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDatasetsDescriptionDocumentation.java index 961385aec..9a1dffe2d 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDatasetsDescriptionDocumentation.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDatasetsDescriptionDocumentation.java @@ -19,16 +19,22 @@ import org.opencdmp.controllers.publicapi.response.DataTableData; import org.opencdmp.controllers.publicapi.types.ApiMessageCode; import org.opencdmp.controllers.publicapi.types.ResponseItem; import org.opencdmp.data.DescriptionEntity; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.DescriptionBuilder; -import org.opencdmp.model.builder.DmpBuilder; -import org.opencdmp.model.descriptiontemplatedefinition.*; -import org.opencdmp.model.descriptiontemplatedefinition.fielddata.BaseFieldData; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.builder.descriptionproperties.DescriptionBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.description.Description; +import org.opencdmp.model.descriptionreference.DescriptionReference; +import org.opencdmp.model.descriptiontemplate.*; +import org.opencdmp.model.descriptiontemplate.fielddata.BaseFieldData; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpreference.DmpReference; import org.opencdmp.model.mapper.publicapi.DescriptionToPublicApiDatasetListingMapper; import org.opencdmp.model.mapper.publicapi.DescriptionToPublicApiDatasetMapper; import org.opencdmp.model.mapper.publicapi.DmpToPublicApiDmpListingMapper; import org.opencdmp.model.publicapi.listingmodels.DatasetPublicListingModel; import org.opencdmp.model.publicapi.overviewmodels.DatasetPublicModel; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.user.User; import org.opencdmp.query.DescriptionQuery; import org.opencdmp.query.DmpQuery; import org.opencdmp.query.lookup.DescriptionLookup; diff --git a/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDmpsDocumentation.java b/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDmpsDocumentation.java index 741bbdf29..bde3aefac 100644 --- a/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDmpsDocumentation.java +++ b/backend/web/src/main/java/org/opencdmp/controllers/publicapi/PublicDmpsDocumentation.java @@ -1,27 +1,5 @@ package org.opencdmp.controllers.publicapi; -import org.opencdmp.authorization.AuthorizationFlags; -import org.opencdmp.commons.enums.IsActive; -import org.opencdmp.controllers.publicapi.request.dmp.DataManagmentPlanPublicTableRequest; -import org.opencdmp.controllers.publicapi.response.DataTableData; -import org.opencdmp.data.DmpEntity; -import org.opencdmp.model.*; -import org.opencdmp.model.builder.DmpBuilder; -import org.opencdmp.model.builder.DmpDescriptionTemplateBuilder; -import org.opencdmp.model.dmpblueprintdefinition.Section; -import org.opencdmp.model.mapper.publicapi.DmpToPublicApiDmpListingMapper; -import org.opencdmp.model.mapper.publicapi.DmpToPublicApiDmpMapper; -import org.opencdmp.model.publicapi.listingmodels.DataManagementPlanPublicListingModel; -import org.opencdmp.model.publicapi.overviewmodels.DataManagementPlanPublicModel; -import org.opencdmp.model.referencedefinition.Definition; -import org.opencdmp.model.referencedefinition.Field; -import org.opencdmp.controllers.publicapi.types.ResponseItem; -import org.opencdmp.query.DmpDescriptionTemplateQuery; -import org.opencdmp.query.DmpQuery; -import org.opencdmp.query.EntityDoiQuery; -import org.opencdmp.query.lookup.DmpLookup; -import org.opencdmp.service.publicapi.PublicApiProperties; -import org.opencdmp.controllers.publicapi.types.ApiMessageCode; import gr.cite.tools.data.builder.BuilderFactory; import gr.cite.tools.data.query.QueryFactory; import gr.cite.tools.exception.MyNotFoundException; @@ -34,6 +12,34 @@ import io.swagger.v3.oas.annotations.responses.ApiResponse; import io.swagger.v3.oas.annotations.tags.Tag; import jakarta.validation.Valid; import org.jetbrains.annotations.NotNull; +import org.opencdmp.authorization.AuthorizationFlags; +import org.opencdmp.commons.enums.IsActive; +import org.opencdmp.controllers.publicapi.request.dmp.DataManagmentPlanPublicTableRequest; +import org.opencdmp.controllers.publicapi.response.DataTableData; +import org.opencdmp.controllers.publicapi.types.ApiMessageCode; +import org.opencdmp.controllers.publicapi.types.ResponseItem; +import org.opencdmp.data.DmpEntity; +import org.opencdmp.model.DmpDescriptionTemplate; +import org.opencdmp.model.DmpUser; +import org.opencdmp.model.builder.DmpDescriptionTemplateBuilder; +import org.opencdmp.model.builder.dmp.DmpBuilder; +import org.opencdmp.model.dmp.Dmp; +import org.opencdmp.model.dmpblueprint.Section; +import org.opencdmp.model.dmpreference.DmpReference; +import org.opencdmp.model.mapper.publicapi.DmpToPublicApiDmpListingMapper; +import org.opencdmp.model.mapper.publicapi.DmpToPublicApiDmpMapper; +import org.opencdmp.model.publicapi.listingmodels.DataManagementPlanPublicListingModel; +import org.opencdmp.model.publicapi.overviewmodels.DataManagementPlanPublicModel; +import org.opencdmp.model.reference.Definition; +import org.opencdmp.model.reference.Field; +import org.opencdmp.model.reference.Reference; +import org.opencdmp.model.referencetype.ReferenceType; +import org.opencdmp.model.user.User; +import org.opencdmp.query.DmpDescriptionTemplateQuery; +import org.opencdmp.query.DmpQuery; +import org.opencdmp.query.EntityDoiQuery; +import org.opencdmp.query.lookup.DmpLookup; +import org.opencdmp.service.publicapi.PublicApiProperties; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; @@ -53,7 +59,7 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; @Tag(name = "DMPs", description = "Provides DMP public API's.") @RestController @CrossOrigin -@RequestMapping(value = {"/api/public/dmps"}) +@RequestMapping("/api/public/dmps") public class PublicDmpsDocumentation { private static final Logger logger = LoggerFactory.getLogger(PublicDmpsDocumentation.class); @@ -85,16 +91,14 @@ public class PublicDmpsDocumentation { } @Operation(summary = "This method is used to get a listing of public dmps.", description = PublicApiStaticHelpers.Dmp.getPagedNotes) - @io.swagger.v3.oas.annotations.responses.ApiResponses(value = {@ApiResponse( - responseCode = "200", - description = """ - The following example is generated using: - a) body: *{"criteria": {},"length": 2,"offset": 0,"orderings": {"fields": []} }* - b) fieldsGroup: listing""", - content = @Content(mediaType = APPLICATION_JSON_VALUE, examples = {@ExampleObject( - value = PublicApiStaticHelpers.Dmp.getPagedResponseExample - )}) - )}) + @io.swagger.v3.oas.annotations.responses.ApiResponses(@ApiResponse( + responseCode = "200", + description = """ + The following example is generated using: + a) body: *{"criteria": {},"length": 2,"offset": 0,"orderings": {"fields": []} }* + b) fieldsGroup: listing""", + content = @Content(mediaType = APPLICATION_JSON_VALUE, examples = @ExampleObject(PublicApiStaticHelpers.Dmp.getPagedResponseExample)) + )) @RequestMapping(method = RequestMethod.POST, consumes = "application/json", produces = "application/json") public @ResponseBody ResponseEntity>> getPaged( @Valid @RequestBody @io.swagger.v3.oas.annotations.parameters.RequestBody(description = PublicApiStaticHelpers.Dmp.getPagedRequestBodyDescription) DataManagmentPlanPublicTableRequest dmpTableRequest, @@ -116,7 +120,7 @@ public class PublicDmpsDocumentation { private static DmpLookup getDmpLookup(String fieldsGroup, DataManagmentPlanPublicTableRequest request) { BaseFieldSet fieldSet = new BaseFieldSet(); Set fields; - if (fieldsGroup.equals("listing")) { + if ("listing".equals(fieldsGroup)) { fields = Set.of( Dmp._id, Dmp._label, @@ -154,14 +158,12 @@ public class PublicDmpsDocumentation { } @Operation(summary = "This method is used to get the overview of a public dmp.", description = PublicApiStaticHelpers.Dmp.getOverviewSinglePublicNotes) - @io.swagger.v3.oas.annotations.responses.ApiResponses(value = {@ApiResponse( - responseCode = "200", - description = "The following example is generated using id: *e9a73d77-adfa-4546-974f-4a4a623b53a8*", - content = @Content(mediaType = APPLICATION_JSON_VALUE, examples = {@ExampleObject( - value = PublicApiStaticHelpers.Dmp.getOverviewSinglePublicResponseExample - )}) - )}) - @RequestMapping(method = RequestMethod.GET, value = {"/{id}"}, produces = "application/json") + @io.swagger.v3.oas.annotations.responses.ApiResponses(@ApiResponse( + responseCode = "200", + description = "The following example is generated using id: *e9a73d77-adfa-4546-974f-4a4a623b53a8*", + content = @Content(mediaType = APPLICATION_JSON_VALUE, examples = @ExampleObject(PublicApiStaticHelpers.Dmp.getOverviewSinglePublicResponseExample)) + )) + @RequestMapping(method = RequestMethod.GET, value = "/{id}", produces = "application/json") public @ResponseBody ResponseEntity> getOverviewSinglePublic( @PathVariable @Parameter(description = "fetch the dmp with the given id", example = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx") String id ) { @@ -183,8 +185,8 @@ public class PublicDmpsDocumentation { String.join(".", Dmp._dmpReferences, DmpReference._reference, Reference._abbreviation), String.join(".", Dmp._dmpReferences, DmpReference._reference, Reference._description), String.join(".", Dmp._dmpReferences, DmpReference._reference, Reference._definition), - String.join(".", Dmp._blueprint, org.opencdmp.model.dmpblueprintdefinition.Definition._sections, Section._id), - String.join(".", Dmp._blueprint, org.opencdmp.model.dmpblueprintdefinition.Definition._sections, Section._ordinal), + String.join(".", Dmp._blueprint, org.opencdmp.model.dmpblueprint.Definition._sections, Section._id), + String.join(".", Dmp._blueprint, org.opencdmp.model.dmpblueprint.Definition._sections, Section._ordinal), Dmp._createdAt, Dmp._updatedAt, Dmp._finalizedAt @@ -193,7 +195,7 @@ public class PublicDmpsDocumentation { DmpQuery query = this.queryFactory.query(DmpQuery.class).authorize(EnumSet.of(AuthorizationFlags.Public)).ids(UUID.fromString(id)).isActive(IsActive.Active); Dmp model = this.builderFactory.builder(DmpBuilder.class).build(dmpFieldSet, query.firstAs(dmpFieldSet)); if (model == null) - throw new MyNotFoundException(messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); + throw new MyNotFoundException(this.messageSource.getMessage("General_ItemNotFound", new Object[]{id, Dmp.class.getSimpleName()}, LocaleContextHolder.getLocale())); EntityDoiQuery entityDoiQuery = this.queryFactory.query(EntityDoiQuery.class).entityIds(UUID.fromString(id)).isActive(IsActive.Active); BaseFieldSet templateFieldSet = new BaseFieldSet(); DmpDescriptionTemplateQuery dmpDescriptionTemplateQuery = this.queryFactory.query(DmpDescriptionTemplateQuery.class).dmpIds(UUID.fromString(id)).isActive(IsActive.Active); diff --git a/backend/web/src/main/java/org/opencdmp/interceptors/user/UserInterceptor.java b/backend/web/src/main/java/org/opencdmp/interceptors/user/UserInterceptor.java index 5155fc2c0..d936c4182 100644 --- a/backend/web/src/main/java/org/opencdmp/interceptors/user/UserInterceptor.java +++ b/backend/web/src/main/java/org/opencdmp/interceptors/user/UserInterceptor.java @@ -15,7 +15,7 @@ import org.opencdmp.convention.ConventionService; import org.opencdmp.data.*; import org.opencdmp.integrationevent.outbox.usertouched.UserTouchedIntegrationEventHandler; import org.opencdmp.model.UserContactInfo; -import org.opencdmp.model.UserCredential; +import org.opencdmp.model.usercredential.UserCredential; import org.opencdmp.query.UserContactInfoQuery; import org.opencdmp.query.UserCredentialQuery; import gr.cite.commons.web.oidc.principal.CurrentPrincipalResolver; @@ -26,7 +26,6 @@ import gr.cite.tools.fieldset.BaseFieldSet; import gr.cite.tools.logging.LoggerService; import jakarta.persistence.EntityManager; import jakarta.persistence.PersistenceContext; -import jakarta.persistence.Tuple; import jakarta.persistence.criteria.CriteriaBuilder; import jakarta.persistence.criteria.CriteriaQuery; import jakarta.persistence.criteria.Root;