mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged HEAD-BUG-FIX (5.0/Cloud) to HEAD (5.0/Cloud)
83759: Merge WAT2 to HEADBUGFIX: r83494 When package items are added/removed it dispatches an Activiti VARIABLE_UPDATED event git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@84576 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -26,6 +26,7 @@ import org.alfresco.repo.workflow.WorkflowConstants;
|
||||
import org.alfresco.repo.workflow.WorkflowModel;
|
||||
import org.alfresco.repo.workflow.activiti.ActivitiConstants;
|
||||
import org.alfresco.repo.workflow.activiti.ActivitiScriptNode;
|
||||
import org.alfresco.repo.workflow.activiti.ActivitiWorkflowEngine;
|
||||
import org.alfresco.rest.framework.core.exceptions.ApiException;
|
||||
import org.alfresco.rest.framework.core.exceptions.EntityNotFoundException;
|
||||
import org.alfresco.rest.framework.core.exceptions.InvalidArgumentException;
|
||||
@@ -72,6 +73,7 @@ public class WorkflowRestImpl
|
||||
protected ProcessEngine activitiProcessEngine;
|
||||
protected boolean deployWorkflowsInTenant;
|
||||
protected List<String> excludeModelTypes = new ArrayList<String>(Arrays.asList("bpm_priority", "bpm_description", "bpm_dueDate"));
|
||||
private ActivitiWorkflowEngine activitiWorkflowEngine;
|
||||
|
||||
static
|
||||
{
|
||||
@@ -269,6 +271,7 @@ public class WorkflowRestImpl
|
||||
}
|
||||
|
||||
Item responseItem = createItemForNodeRef(nodeRef);
|
||||
activitiWorkflowEngine.dispatchPackageUpdatedEvent(packageScriptNode, null, null, processId, null);
|
||||
return responseItem;
|
||||
}
|
||||
|
||||
@@ -312,6 +315,7 @@ public class WorkflowRestImpl
|
||||
try
|
||||
{
|
||||
nodeService.removeChild(packageScriptNode.getNodeRef(), nodeRef);
|
||||
activitiWorkflowEngine.dispatchPackageUpdatedEvent(packageScriptNode, null, null, processId, null);
|
||||
}
|
||||
catch (InvalidNodeRefException e)
|
||||
{
|
||||
@@ -541,4 +545,9 @@ public class WorkflowRestImpl
|
||||
}
|
||||
return item;
|
||||
}
|
||||
|
||||
public void setActivitiWorkflowEngine(ActivitiWorkflowEngine activitiWorkflowEngine)
|
||||
{
|
||||
this.activitiWorkflowEngine = activitiWorkflowEngine;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user