Service catalog

vikaskumarc
Tera Contributor

I have around 10 choices which is inside the requested type , those choices are inside the first option (NEW).

I need to create 10 catalog task with different description and short description. Should i use If, Switch or branch. and then where script needs to be write for description and short description. Please suggest

 

 

Screenshot 2025-07-31 005903.pnggest

5 REPLIES 5

Bhimashankar H
Mega Sage

Hi @vikaskumarc ,

 

If/Else-of chain is simpler for 2-3 options, in your case best to switch statement for many options and different logic.

 

If possible, try to use the flow designer, where you can branch(Switch) on requested_type, something like 

  • Case: "choice_1"

    • Create Catalog Task

      • Short Description: "Task 1"

      • Description: "Details 1"

  • Case: "choice_2"

    • Create Catalog Task

      • Short Description: "Task 2"

      • Description: "Details 2"

  • ...repeat for all 10 choices...

 

Use the Flow Designer “Branch” (Switch) action to create the correct Catalog Task for each requested type choice and set the Short Description/Description in each branch’s "Create Catalog Task" step. If scripting, use an associative code map/object.

 

Thanks,
Bhimashankar H

 

-------------------------------------------------------------------------------------------------
If my response points you in the right directions, please consider marking it as 'Helpful' & 'Correct'. Thanks!

Najmuddin Mohd
Mega Sage

Hello @vikaskumarc ,

You can create two Flow variables.
You can use If, Else if in the flow designer and depending on the choice selected, you can assign the respected flow variables.

NajmuddinMohd_0-1753937196215.png



Later, you can create a Catalog task and assign the short_description and description with the respected flow variables.

If the above information helps you, Kindly mark it as Helpful and Accept the solution.
Regards,
Najmuddin.

G Ponsekar
Mega Guru

Hi @vikaskumarc ,

 

If you are using Workflow use "Run script" activity to create catalog tasks if values are not fixed

If you are using Flow, create custom action to create multiple tasks

 

Thanks,

GP

i am using workflow editor