tag:blogger.com,1999:blog-16500981.post1812877862142655875..comments2023-09-28T18:11:20.365+07:00Comments on living in java: Starting an alfresco workflow using Javascript APISantosohttp://www.blogger.com/profile/01534214022898572802noreply@blogger.comBlogger15125tag:blogger.com,1999:blog-16500981.post-84349259123241902022016-01-11T22:33:18.126+07:002016-01-11T22:33:18.126+07:00.i don't want to use the forms which are avail....i don't want to use the forms which are available within the Alfresco Activiti BPM Suite v1.4.0. I want to create my own html forms. The html forms should be able to trigger a workflow in alfresco activiti. Any pointers as to how this can be done ??Livingituphttps://www.blogger.com/profile/01224893430651502984noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-74586682133248240142014-05-12T15:45:11.180+07:002014-05-12T15:45:11.180+07:00hi sir! thanks for your code tutorial. But can you...hi sir! thanks for your code tutorial. But can you please give the whole code of starting workflow from the start. Where is the connection to the repository? Thanks!!Anonymoushttps://www.blogger.com/profile/16301056777349134909noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-68009060742177616552013-02-19T17:23:31.899+07:002013-02-19T17:23:31.899+07:00Is it possible to execute a Workflow via Javascrip...Is it possible to execute a Workflow via Javascript without passing a document? I have only a ScriptTask in my process definition. <br /><br />ThanksAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-16500981.post-12248052059128876122013-01-29T20:28:39.349+07:002013-01-29T20:28:39.349+07:00Managers and analysts can continuously improve per...Managers and analysts can continuously improve performance by discovering process bottlenecks and inefficiencies.<br /><br /><br /><br /><a href="http://www.processmaker.com/" rel="nofollow">alfresco workflow</a>Sexyladyme26https://www.blogger.com/profile/13202731218038182029noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-78288817476948051592012-10-15T16:29:36.124+07:002012-10-15T16:29:36.124+07:00Hi Santoso,
The script is working fine when I am ...Hi Santoso,<br /><br />The script is working fine when I am invoking it from my browser, but getting HTTP response code 505 when it is invoked from java code.<br /><br />Below is the java code used to invoke the script:<br />URL conn = new URL(<br /> "http://10.10.12.120:8080/alfresco/service/lombardi/initiateworkflow?n=FSMIS/Central Delhi/Firm/Temp/F15102012107/Raheja Industries&alf_ticket="+ticket);<br /> URLConnection yc = conn.openConnection();<br /> BufferedReader in = new BufferedReader(new InputStreamReader(<br /> yc.getInputStream()));<br /><br />Please help.Vivekhttps://www.blogger.com/profile/02968026962831789598noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-45939328411517976222011-04-20T01:56:48.693+07:002011-04-20T01:56:48.693+07:00Help! This workflow won't start and I'm n...Help! This workflow won't start and I'm not seeing the issue!<br /><br />I'm including my webscript JS below and the value of my variables are supplied in the model assignment lines below:<br /><br />[code]<br />var nodeId = args.node_id;<br /><br />var node = args.node_id;<br /><br />if (node != null)<br />{<br /> var workflowType = "jbpm$" + args.type;<br /><br /> var assignTo = people.getPerson(args.assignto);<br /><br /> var description = args.desc;<br /><br /> var workflow = actions.create("start-workflow");<br /><br /> workflow.parameters.workflowName = workflowType;<br /><br /> workflow.parameters["bpm:workflowDescription"] = description;<br /><br /> workflow.parameters["bpm:assignee"] = assignTo;<br /><br /> workflow.execute(node.nodeRef);<br />}<br /><br />model.assignto = assignTo; //Node Type: {http://www.alfresco.org/model/content/1.0}person Node Ref: workspace://SpacesStore/70a6d0fe-0aa1-452b-97ae-b343e10a2654<br />model.node = node; //Node Type: {http://www.alfresco.org/model/content/1.0}person Node Ref: workspace://SpacesStore/70a6d0fe-0aa1-452b-97ae-b343e10a2654<br />model.type = workflowType; //jbpm$2 - the stock review and approve (single user) workflow...<br /><br />[/code]<br /><br />Error that I'm getting is:<br /><br />03190082 Wrapped Exception (with status template): 03190150 Failed to execute script '/start_workflow.post.js (in repository store workspace://SpacesStore/Company Home/Data Dictionary/Web Scripts Extensions)': 03190149 Can't find method org.alfresco.repo.jscript.ScriptAction.execute(org.mozilla.javascript.Undefined). (workspace://SpacesStore/Company Home/Data Dictionary/Web Scripts Extensions/start_workflow.post.js#21)<br /><br />I'm not understand what is undefined! I'd appreciate any pointers!<br /><br />BruceBruce W. Fordhttps://www.blogger.com/profile/01695306126580209063noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-38009483627164726702010-11-30T16:33:33.951+07:002010-11-30T16:33:33.951+07:00How do you access that sanz:notifyMe property in a...How do you access that sanz:notifyMe property in a task inside a beanshell script and how inside a javascript script?Unknownhttps://www.blogger.com/profile/02789664288526286964noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-14919958012480874822010-08-10T21:47:55.662+07:002010-08-10T21:47:55.662+07:00Hi Santoso,
I was executing your script but I am g...Hi Santoso,<br />I was executing your script but I am getting error. "A system error happened during the operation: 07100013 Failed to execute script 'workspace://SpacesStore/891d8884-2fd7-4c62-8e1f-499815dbe33c': 07100012 Mandatory task properties have not been provided: {http://www.alfresco.org/model/bpm/1.0}assignee"<br /><br />My code as below<br /><br />var workflow = actions.create("start-workflow");<br />workflow.parameters.workflowName = "jbpm$wf:review";<br />workflow.parameters["bpm:workflowDescription"] = document.name;<br />workflow.parameters["bpm:groupAssignee"] = people.getGroup("GROUP_DEVELOPER");<br />workflow.parameters["wf:notifyMe"] = true;<br />var futureDate = new Date();<br />futureDate.setDate(futureDate.getDate() + 7);<br />workflow.parameters["bpm:workflowDueDate"] = futureDate;<br />workflow.execute(document);<br /><br />Please help.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-16500981.post-18304858321400011732009-07-20T15:21:56.246+07:002009-07-20T15:21:56.246+07:00hi,
Thanks for all information. I had a question,...hi,<br /><br />Thanks for all information. I had a question, can I refer to different groupAssignee? Indeed, according to the space where the content is added, the groupAssignee will be different.<br />How can I do that?<br /><br />Thanks.Unknownhttps://www.blogger.com/profile/09786252967470881868noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-12896624388203887132009-04-21T17:49:00.000+07:002009-04-21T17:49:00.000+07:00Hi,
BlueXML provides a Workflow modeler to design ...Hi,<br />BlueXML provides a Workflow modeler to design such workflows and generate everything Alfresco needs (model, process definition file, web client configuration, messages, ...)<br /><br />No need to code anything,<br /><br />HTH,Jean-Christophe Kermagorethttp://www.bluexml.comnoreply@blogger.comtag:blogger.com,1999:blog-16500981.post-76292178491491009302009-04-18T01:46:00.000+07:002009-04-18T01:46:00.000+07:00Hi Santoso
I have this requirement of using the d...Hi Santoso<br /><br />I have this requirement of using the document's custom properties in my workflow. I am, at this point, able to add a document belonging to a custom document type to the alfresco and also am able to launch a custom workflow (using a javascript and a rule defined on my space). Now, my requirement is to assign certain properties (like empId and empName) on the custom document type to the workflow parameters defined on my workflow. Is there a way to accomplish this?Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-16500981.post-27520564875784480432009-03-13T12:31:00.000+07:002009-03-13T12:31:00.000+07:00Hi Miki,AFAIK, I don't think there's a toolkit whi...Hi Miki,<BR/><BR/>AFAIK, I don't think there's a toolkit which could help you develop workflow easily.<BR/><BR/>At least you need to have your process definition, model and web client configuration.<BR/><BR/>The tool to prepare the process definition could be found here :<BR/>http://wiki.alfresco.com/wiki/WorkflowAdministration#Process_Designer_developed_Process_Archive<BR/><BR/>This tool could help you deploy the process definition.<BR/><BR/>For the model and web client configuration, I think you have to prepare it yourself using a text editor.Santosohttps://www.blogger.com/profile/01534214022898572802noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-13246204312453468372009-03-12T14:32:00.000+07:002009-03-12T14:32:00.000+07:00Hi Santoso,i need for my clients workflow toolkit ...Hi Santoso,<BR/>i need for my clients workflow toolkit for alfresco that will be used without programing and deploying, is there anything like this?<BR/>Thank You<BR/>MikistockerMkhttps://www.blogger.com/profile/08845739323785064702noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-233155384901495202009-02-17T14:50:00.000+07:002009-02-17T14:50:00.000+07:00Hi, of course you can reference to existing conten...Hi, <BR/><BR/>of course you can reference to existing content. <BR/><BR/>To get the noderef you could use scriptnode API (see http://wiki.alfresco.com/wiki/3.0_JavaScript_API#Root_Scope_Objects --> if you're using alfresco 3.0)<BR/><BR/>for example :<BR/>the document (test.txt) is located in docs under your company home.<BR/>var noderef = userhome.childByNamePath("/Company Home/docs/text.txt");<BR/><BR/>workflow.execute(noderef);<BR/><BR/><BR/>The above code should work for you. Please inform me whether it works for you or not :)Santosohttps://www.blogger.com/profile/01534214022898572802noreply@blogger.comtag:blogger.com,1999:blog-16500981.post-66428287810551217082009-02-17T13:16:00.000+07:002009-02-17T13:16:00.000+07:00hi Santoso, Thanks for the informative tutorial, I...hi Santoso, <BR/><BR/>Thanks for the informative tutorial, I was wondering, how can I "reference a content that is already uploaded in alfresco" if I know its noderef? I want to execute a workflow with a pre-defined content.<BR/><BR/>ex. <BR/><BR/>workflow.execute(<I>"content noderef"</I>)???<BR/><BR/><BR/>can i use noderef if yes, how? thanksAnonymousnoreply@blogger.com