08-17-2014 08:38 AM
NodeRef wfPackage = ServiceHelper.workflowService.createPackage(folderRef); // folderRef is a nodeRef to a folder
…
workflowProps.put(WorkflowModel.ASSOC_PACKAGE, wfPackage);
…
workflowService.startWorkflow(workflowId, parameters);
07170034 Found 1 integrity violations:
The association source type is incorrect:
Source Node: workspace://SpacesStore/52fe26f3-7221-4a5f-9cf3-a87d2f6082b0
Association: Association[ class=ClassDef[name={http://www.alfresco.org/model/bpm/1.0}package], name={http://www.alfresco.org/model/bpm/1.0}packageContains, target class={http://www.alfresco.org/model/system/1.0}base, source role=null, target role=null]
Required Source Type: {http://www.alfresco.org/model/bpm/1.0}package
Actual Source Type: {http://www.alfresco.org/model/content/1.0}folder
08-17-2014 11:31 PM
workflowService.createPackage(folderRef)
,the type of folderRef should be "bpmackage" NodeRef wfPackage = ServiceHelper.workflowService.createPackage(null);
08-18-2014 02:50 AM
08-18-2014 04:21 AM
NodeRef wfPackage = ServiceHelper.workflowService.createPackage(null);
//make your folder as a child of workflow package,and the association type is WorkflowModel.ASSOC_PACKAGE_CONTAINS
QName qName = QName.createQName(***_url, ****localName);
nodeService.addChild(wfPackage, folderRef, WorkflowModel.ASSOC_PACKAGE_CONTAINS,qName );
08-18-2014 04:23 AM
QName.createQName(***_url, ****localName)
? What is his purpose?08-18-2014 05:01 AM
QName name = QName.createQName(NamespaceService.CONTENT_MODEL_1_0_URI,"childFolder");
08-18-2014 06:47 AM
08-18-2014 07:07 AM
08-18-2014 07:37 AM
08-18-2014 09:21 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.