06-01-2012 05:29 AM
06-01-2012 12:11 PM
03-21-2013 11:34 AM
04-05-2013 06:05 AM
04-08-2013 02:10 AM
06-13-2016 06:04 AM
function createWorkflow() {
var workflow = actions.create("start-workflow");
workflow.parameters.workflowName = "jbpm$wf:adhoc"; // Need to be replaced with our Custom workflow ?
workflow.parameters["bpm:workflowDescription"] = "The attached document has been uploaded to Alfresco. Please review within 3 days.";
workflow.parameters["bpm:assignee"] = "admin"; // TODO: not hard coded, this is testing
// workflow.parameters["bpm:groupAssignee"] = assigneeGroup; // Assign group depending on Division ?
var futureDate = new Date();
futureDate.setDate(futureDate.getDate() + 3);
workflow.parameters["bpm:workflowDueDate"] = futureDate;
return workflow.execute(document);
}
function moveDocument(doc, folder) {
doc.move(folder);
}
function main() {
//if (logger.isLoggingEnabled())
logger.log("Test OK");
logger.warn("Test warn OK");
createWorkflow();
}
main();
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.