Auto populate catalog variables using flow designer

vijayaram
Tera Contributor

Hi ALL,

how to auto populate catalog variables in DESCRIPTION field of catalog task using flow designer (by script)

2 REPLIES 2

Anand Kumar P
Giga Patron

Hi @vijayaram ,

You can follow below steps-

Create one custom action

AnandKumarP_1-1701501686088.png


Click on plues icon take script step

AnandKumarP_2-1701501721422.png


Use below script and add variables whatever you required in script i am taking 2 varibles Additional_software_requirements and Air

(function execute(inputs, outputs) {
   var ritmid=inputs.request_item;
   var getitem=new GlideRecord('sc_req_item');
   getitem.get(ritmid);
   var description = getitem.variables.Additional_software_requirements +' ' + getitem.variables.air ;
   outputs.desc=description;
})(inputs, outputs);

AnandKumarP_3-1701501826386.png


In outputs call script step

AnandKumarP_4-1701501854401.png

Then go to main flow and add action in flow  and drag pill  ritm sys_id

AnandKumarP_5-1701501912031.png

 

And in task action take description variables add Outputs 

AnandKumarP_6-1701502007523.png

Then test raising catalog item request




AnandKumarP_0-1701501649174.png

AnandKumarP_7-1701502057415.png

Please mark it as helpful and solution proposed.

Thanks,

Anand

 

OlaN
Giga Sage
Giga Sage

Hi,

Can you please explain what you are trying to do? Can you share some images to clarify?

In it's simplest form, you can set the description field of a catalog task by drag-and-dropping data pills into the field.