AnsweredAssumed Answered

Add item to existing workflow

Question asked by gizmo16 on Jun 18, 2014
Latest reply on Jun 18, 2014 by jpotts
I need help with update workflowTask, add file to existing workflow.

My code is:



      List<NodeRef> addNodes = new ArrayList<NodeRef>();
      addNodes.add(addNodeRef);
   
      Map<QName, List<NodeRef>> nodesAdd = new HashMap<QName, List<NodeRef>>();
      nodesAdd.put(WorkflowModel.ASSOC_PACKAGE, addNodes);


      workflowService.updateTask(currentTask.getId(), null, nodesAdd, null);  //nullpointer



- currentTask is not null, is actual task in workflow, where I want add item
- addNodes is list actual NodeRef uploaded to alfresco folder
- addNodeRef is only one item uploaded to alfresco


Is there any other way an item is added to the already running workflow?

Where's my mistake?


Thanks in advance

Outcomes