use of org.alfresco.module.org_alfresco_module_rm.action.RecordsManagementActionCondition in project records-management by Alfresco.
the class RmActionConditionDefinitionsGet method executeImpl.
/**
* @see org.springframework.extensions.webscripts.DeclarativeWebScript#executeImpl(org.springframework.extensions.webscripts.WebScriptRequest, org.springframework.extensions.webscripts.Status, org.springframework.extensions.webscripts.Cache)
*/
@Override
protected Map<String, Object> executeImpl(WebScriptRequest req, Status status, Cache cache) {
List<ActionConditionDefinition> dmDefs = actionService.getActionConditionDefinitions();
List<RecordsManagementActionCondition> conditions = recordsManagementActionService.getRecordsManagementActionConditions();
List<ActionConditionDefinition> defs = new ArrayList<ActionConditionDefinition>(dmDefs.size() + conditions.size());
defs.addAll(dmDefs);
for (RecordsManagementActionCondition condition : conditions) {
if (condition.isPublicCondition()) {
defs.add(condition.getRecordsManagementActionConditionDefinition());
}
}
Map<String, Object> model = new HashMap<String, Object>();
model.put("actionconditiondefinitions", defs);
return model;
}
Aggregations