Clarity Service Management

Expand all | Collapse all

Direct link to the workflow task from message template

Jump to Best Answer
  • 1.  Direct link to the workflow task from message template

    Posted 04-12-2019 04:15 PM

    Hi,

    Is there anyway to include direct link of the particular workflow task from the message templates of change order?

    If i click the link from the notification mail ,it should go to the corresponding workflow task of the Change order

     

    Can anyone help me on this? 

     

    Thanks,

    Lakshmipriya



  • 2.  Re: Direct link to the workflow task from message template

    Posted 04-13-2019 09:43 AM

    Hi,

     

    this guide could help you to build correct url: https://docops.ca.com/ca-service-management/14-1/en/building/building-ca-service-desk-manager/web-interface-modifications/supported-server-operations

     

    As you can't perform complex scripting within notification template to get workflow's id and navigate into it, you need to use workarounds. You can open an object via url if only one object matches your search criteria, for example you have Approval task at sequence 150, so you can use this url to navigate to your task:

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=APP+QBE.EQ.sequence=150+QBE.EQ.chg=@{id}

     

    PS: also this looks like incorrect process planning and you can easily send notification from workflow task itself.

     

     

    Regards,

    Timur



  • 3.  Re: Direct link to the workflow task from message template

    Posted 04-15-2019 11:26 AM

    Not from a Message Template for Object Type "Change Order" but you can from a Message Template for Object Type "Change Order Workflow Task". It is @{web_url}.



  • 4.  Re: Direct link to the workflow task from message template

    Posted 04-15-2019 01:17 PM

    Hi Lindsay_Estabrooks

    Thanks for your reply.

     

    I have just tried this url in browser 

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=CCA+QBE.EQ.sequence=10+QBE.EQ.chg=@{402032}

    My Task code is CCA ,Sequence is 10 and my change id is 402032 and my CO number is 500

    But it is showing No change workflow task found.

     

    Am I doing anything wrong with values?

     

    Thanks,

    Lakshmipriya



  • 5.  Re: Direct link to the workflow task from message template

    Posted 04-15-2019 02:38 PM

    Try this:

     

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.sequence=10+QBE.EQ.chg=402032

     

    or

     

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.sequence=10+QBE.EQ.chg.chg_ref_num=500



  • 6.  Re: Direct link to the workflow task from message template

    Posted 04-15-2019 06:56 PM

    This one worked

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=CCA+QBE.EQ.chg.chg_ref_num=500

     

    My next question is, If i use this with object type 'change order workflow task' then how it will be trigged ?

    I dnt want to add this message template to be added as multiple notification in workflow task behavior.

    I want it to be triggered as general not based on any category.

     

    Can you help me on this?

     

    Thanks,

    Lakshmipriya 



  • 7.  Re: Direct link to the workflow task from message template

    Posted 04-15-2019 07:35 PM

    You didn't say when you wanted to send out the notification. I assume you want the notificaiton to be sent out when the system changes that task status to 'Pending'. There is no  configurable way to make that happen except in the workflow task behavior.

    The only other way I can think of would be to create a trigger on the wf object and write some SPEL code to send the notification.



  • 8.  Re: Direct link to the workflow task from message template

    Posted 04-19-2019 01:30 PM

    Ohh..My bad. 

    Thanks for your response Lindsay_Estabrooks

    Is there any way to hard code the link in message template of change order ?

    Like below 

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=CCA+QBE.EQ.chg.chg_ref_num= @chg_ref_num

    In my case task name will be same.Only I need to modify the change order number .

     

    Thanks,

    Lakshmipriya



  • 9.  Re: Direct link to the workflow task from message template
    Best Answer

    Posted 04-19-2019 02:32 PM

    Assuming that this is a Message Template for Object Type "Change Order", then it would be:

    pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=CCA+QBE.EQ.chg.chg_ref_num=@{chg_ref_num}



  • 10.  Re: Direct link to the workflow task from message template

    Posted 04-19-2019 08:52 PM

    Its worked!!!

    I have tried below

    To approve this request click  <a  href="               /CAisd/pdmweb.exe?OP=SEARCH+FACTORY=wf+SKIPLIST=1+QBE.EQ.task=CDA+QBE.EQ.chg.chg_ref_num=@{change_id.chg_ref_num}"  target=_blank> here </a>

     

    I have accessed workflow task inside message template of change order and working as expected



  • 11.  Re: Direct link to the workflow task from message template

    Posted 04-21-2019 05:20 AM

    Great that this works for you.
    Another, more generic, approach might be the suggestion I made here:
    https://communities.ca.com/ideas/235722234-extend-activity-notifications-to-workflow-tasks
    Basically, all that is missing is a reference from the change activity log to the originating workflow task.
    The solution mentioned above, handles this.
    Regards
    ......Michael