Class MergeResource
java.lang.Object
ch.tocco.nice2.rest.core.spi.AbstractRestResource
ch.tocco.nice2.rest.action.spi.AbstractPreActionResource
ch.tocco.nice2.actions.impl.merge.MergeResource
- All Implemented Interfaces:
RestResource
-
Nested Class Summary
Nested classes/interfaces inherited from class ch.tocco.nice2.rest.action.spi.AbstractPreActionResource
AbstractPreActionResource.SelectionType
-
Field Summary
Fields inherited from class ch.tocco.nice2.rest.action.spi.AbstractPreActionResource
businessUnitManager, context, defaultDisplayService, defaultValueService, formBeanService, initialFormEntityName, initialFormName, l10n, log, requiresFormEntity, securityManager, textResources
Fields inherited from class ch.tocco.nice2.rest.core.spi.AbstractRestResource
uriInfo
-
Constructor Summary
ConstructorDescriptionMergeResource
(RestDefaultDisplayService restDefaultDisplayService, PersistenceService persistenceService, MergeEntitiesService mergeEntitiesService, MergeEntitiesDataService mergeEntitiesDataService, QueryBuilderFactory queryBuilderFactory) -
Method Summary
Modifier and TypeMethodDescriptiongetSourceData
(EntitySelectionBean selection) jakarta.ws.rs.core.Response
preAction
(ActionResourceBean actionResourceBean) is ran before the actual logic and can be used to run checks or return a form that needs to be filled before executionvoid
setRelationsToDuplicates
(List<RelationToMergeableEntities> contributions) Methods inherited from class ch.tocco.nice2.rest.action.spi.AbstractPreActionResource
getInitialFormValueResponseBean, getSelectedEntities, getSelectedEntity, loadInitialForm, setBusinessUnitManager, setContext, setDefaultDisplayService, setDefaultValueService, setFormBeanService, setL10n, setLog, setSecurityManager, setSelectionService, setTextResources
Methods inherited from class ch.tocco.nice2.rest.core.spi.AbstractRestResource
getPathParameter, setUriInfo, tryGetInt
-
Constructor Details
-
MergeResource
public MergeResource(RestDefaultDisplayService restDefaultDisplayService, PersistenceService persistenceService, MergeEntitiesService mergeEntitiesService, MergeEntitiesDataService mergeEntitiesDataService, QueryBuilderFactory queryBuilderFactory)
-
-
Method Details
-
preAction
Description copied from class:AbstractPreActionResource
is ran before the actual logic and can be used to run checks or return a form that needs to be filled before execution- Overrides:
preAction
in classAbstractPreActionResource
-
getSourceData
@POST @Path("sourceData") @Produces("application/json") @Consumes("application/json") public MergeSourceDataBean getSourceData(EntitySelectionBean selection) -
merge
@POST @Path("merge") @Produces("application/json") @Consumes("application/json") public jakarta.ws.rs.core.Response merge(MergeBean bean) -
setRelationsToDuplicates
@Autowired(required=false) @VisibleForTesting public void setRelationsToDuplicates(List<RelationToMergeableEntities> contributions)
-