How can I update a catalog variable in Flow Designer

Taha_Alawadhi
Giga Contributor

Hey guys,

I need your help!
I am trying to update a catalog variable in the middle of a workflow using flow designer

find_real_file.png

 

I don't see an OOB option to do that and when I tried this script as an action it didn't work. I am getting the variable value, but it won't change it 

 

find_real_file.png

 

Thanks!

1 ACCEPTED SOLUTION

Taha_Alawadhi
Giga Contributor

I just found the solution
Way simpler than I thought

 

find_real_file.png

View solution in original post

6 REPLIES 6

Jan K_lb_k
Tera Contributor

Hi Taha.

You could also create a reusable action, where you pass in the record, variable name and the new value. Then it can be used in other flows as well

(function execute(inputs, outputs) {
  inputs.record.variables[inputs.variable] = inputs.value;
  inputs.record.update();
})(inputs, outputs);

Best regards, Jan

cms1
Tera Contributor

Can you share the entire new action ? 

I am very new to creating a new action.