<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Can't get taskid from ScriptTask (groovy) in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/can-t-get-taskid-from-scripttask-groovy/m-p/201904#M155034</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I want to call external script using ScriptTask step. External script after finish his job call REST API to complete task like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;POST &lt;/SPAN&gt;&lt;A href="http://login:pass@host/activiti-rest/service/runtime/tasks/23045" rel="nofollow noopener noreferrer"&gt;http://login&lt;img id="smileytongue" class="emoticon emoticon-smileytongue" src="https://connect.hyland.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;ass@host/activiti-rest/service/runtime/tasks/23045&lt;/A&gt;&lt;SPAN&gt; body: '{"action":"complete"}'. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So to do it I need to know taskId. How can I get it in ScriptTask using groovy? I tried to call task.getId(), but got an exception in Activiti Explorer.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks a lot for your help.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 26 Aug 2014 08:20:02 GMT</pubDate>
    <dc:creator>vala4i</dc:creator>
    <dc:date>2014-08-26T08:20:02Z</dc:date>
    <item>
      <title>Can't get taskid from ScriptTask (groovy)</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/can-t-get-taskid-from-scripttask-groovy/m-p/201904#M155034</link>
      <description>I want to call external script using ScriptTask step. External script after finish his job call REST API to complete task like this&lt;IMG id="smileytongue" class="emoticon emoticon-smileytongue" src="https://migration33.stage.lithium.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;OST http://login&lt;IMG id="smileytongue" class="emoticon emoticon-smileytongue" src="https://migration33.stage.lithium.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;ass@host/activiti-rest/service/runtime/tasks/23045 body: '{"action":"complete"}'. So to do it I need to know taskId. How can I get it in ScriptTask u</description>
      <pubDate>Tue, 26 Aug 2014 08:20:02 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/can-t-get-taskid-from-scripttask-groovy/m-p/201904#M155034</guid>
      <dc:creator>vala4i</dc:creator>
      <dc:date>2014-08-26T08:20:02Z</dc:date>
    </item>
    <item>
      <title>Re: Can't get taskid from ScriptTask (groovy)</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/can-t-get-taskid-from-scripttask-groovy/m-p/201905#M155035</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I do not understand you question, but I will try to help.&lt;/SPAN&gt;&lt;BR /&gt;&lt;STRONG&gt;Assumptions:&lt;/STRONG&gt;&lt;BR /&gt;&lt;UL&gt;* You have 2 process instances (A,B). &lt;BR /&gt;* The process A is in waiting state (activity: UserTask).&lt;BR /&gt;* process B after the start should complete user task from process A&lt;BR /&gt;* process instance id A is input parameter to start the process instance B&lt;/UL&gt;&lt;STRONG&gt;Solution:&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;Create task query from task service and ask for all task for process instance A. Query returns list of tasks for the given process instance with ids.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Martin&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Aug 2014 05:49:24 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/can-t-get-taskid-from-scripttask-groovy/m-p/201905#M155035</guid>
      <dc:creator>martin_grofcik</dc:creator>
      <dc:date>2014-08-27T05:49:24Z</dc:date>
    </item>
  </channel>
</rss>

