The CreatorCon Call for Content is officially open! Get started here.

Populate Task number in Notification - Workflow

Saridha_L1
Tera Expert

Hi Team,

I have created a notification through workflow. There I have to populate Task number.

I have tried with ${number} ,RITM is displaying, and tried ${task.number}- I Am getting Blank value. Can anyone help me please.

Regards,

Saridha.L

21 REPLIES 21

anupraheja
Tera Expert

Hi,


You can use email script



var gr = new GlideRecord('sc_task');


  gr.addQuery('request_item',current.sys_id);


  gr.query();


  while (gr.next()) {


  gs.log(" Task number is"+gr.number);


  }




Regards,


Anup


Saridha_L1
Tera Expert

Thank you for your response.



I have tried the above script, still its showing blank. Task number is not getting displayed.



Regards,


Saridha.L


Please find attached screenshots of notification and email script.
email.JPGEmailscript.JPG



Please mark as Helpful or Correct.


Hi Anup,



Its working. Thank you for your help .


Saridha_L1
Tera Expert

Hi Anup.



var gr = new GlideRecord('sc_task');


  gr.addQuery('request_item',current.sys_id);


  gr.query();


  while (gr.next()) {


  gs.log(" Task number is"+gr.number);


  }



I am using this.