本文介绍了Alfresco:直接链接到工作流程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
这可能吗?如果是这样,我如何格式化链接以包括UI?
如果没有,是否有专门为启动工作流程而设计的自定义仪表板?
我想从Alfresco网站上的站点链接dashlet开始工作流程.使用Firebug检查POST给我提供了一个有效的URL,但它仅显示表单而没有任何UI:
I would like to start a workflow from the site links dashlet on my Alfresco site. Using Firebug to examine the POST gives me a URL that works, but it only displays the form without any UI:
localhost:8081/share/service/components/form?htmlid=template_x002e_start-workflow_x002e_start-workflow_x0023_default-startWorkflowForm-alf-id1&itemKind=workflow&itemId=activiti%24orpWorkflow&mode=create&submitType=json&showCaption=true&formUI=true&showCancelButton=true&destination=
推荐答案
您可以对共享"进行一些自定义.
You can make a little customization for Share.
例如,如果您需要打开任何业务流程的开始表单,则可以在弹出窗口中找到其索引,并在URL中添加一个附加参数(例如openFormParam).
For example, if you need to open the start form of any business process, you can find its index in the popup and add an additional parameter to the URL (let's say, openFormParam).
在start-workflow.js中:
onReady: function StartWorkflow_onReady() { // skipped ... // get the additional parameter from the URL here // var openFormParam = ... if(openFormParam !== null) { var p_aArgs = []; var index = {index: 0}; // for the first workflow in the popup p_aArgs.push(0, index); this.onWorkflowSelectChange(null, p_aArgs); } return Alfrescoponent.StartWorkflow.superclass.onReady.call(this); }, // OOTB onWorkflowSelectChange: function StartWorkflow_onWorkflowSelectChange(p_sType, p_aArgs) { var i = p_aArgs[1].index; if (i >= 0) { // Update label of workflow menu button var workflowDefinition = this.options.workflowDefinitions[i]; this.widgets.workflowDefinitionMenuButton.set("label", workflowDefinition.title + " " + Alfresco.constants.MENU_ARROW_SYMBOL); this.widgets.workflowDefinitionMenuButton.set("title", workflowDefinition.description); // Load the form for the specific workflow Alfresco.util.Ajax.request({ url: Alfresco.constants.URL_SERVICECONTEXT + "components/form", dataObj: { htmlid: this.id + "-startWorkflowForm-" + Alfresco.util.generateDomId(), itemKind: "workflow", itemId: workflowDefinition.name, mode: "create", submitType: "json", showCaption: true, formUI: true, showCancelButton: true, destination: this.options.destination }, successCallback: { fn: this.onWorkflowFormLoaded, scope: this }, failureMessage: this.msg("message.failure"), scope: this, execScripts: true }); } },更多推荐
Alfresco:直接链接到工作流程
发布评论