How to assign assignment group with different criteria into flow design

BanuMahalakshmi
Tera Contributor
Hi
 
I have completed till capturing get catalogitem variable values and fetch records from the table location point of contact. 
But i struck into task assign into assignment group value depands on request item variable "location" value.
I want to assign initially default in the assignment group (local -support group).
If system property (Acc, Adc,ted) indicates that the variable location starts with one of the mentioned in the system property, no further action required.
If the location does not have an active local support group, no further action required.
If the location does have an active location support group, then update the assignment group with this value.
Please advise how to check these condition.Thanks.
BanuMahalakshmi_0-1743769884196.png

 

6 REPLIES 6

SwathiPedireddy
Kilo Sage

Hi @BanuMahalakshmi 

Step 1: Create Flow Variable with type True/False and set Flow variable as shown below and Update script with property

SwathiPedireddy_0-1743777676956.png

var location=fd_data._1__get_catalog_variables.site;//change according your step and variable name
var propertyLocation=gs.getProperty('').split(',');
var isLocationMatched=false;

for(var i=0;i<propertyLocation.length;i++){
    if(location.startsWith(propertyLocation[i])){
        isLocationMatched=true;
    }

}
return isLocationMatched;
 
Step 2:Check location matched with property and lookup record support group is active and then create task with support group
SwathiPedireddy_1-1743777868819.png

 

Step 3: Else create task with default group

SwathiPedireddy_2-1743777935382.png

 

 Thanks,

Swathi

 

 

Hi,

Thanks for reply, my client asked to change the flow. initially task should be created with default assignment group. then check the condition:
.If system property indicates that the Site is one of the locations mentioned in the system property, no further action required. end loop

.If the location does not have an active local support group, no further action required. end loop
.If the location does have an active location support group, then update the task assignment group with this value.

 

i tried to change the flow - first created task then check these 3 condition, but task has created with default assignment group value then these 3 conditions not triggered. can u help me on that?snap2.PNG

@BanuMahalakshmi 

how are you checking those conditions? share the screenshots of each IF else IF

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Step 1:  Create task, then fetching group values from location point of contact table depands on location value.

 

BanuMahalakshmi_0-1745341275211.png

 

Step2: if count < 0, it means location doesnt have active support group. then end loop. no changes required in the task.

BanuMahalakshmi_1-1745341447951.png

 

Step 3: if the location has active support group and if the value mentioned system property  matches, end loop no update required into task.

BanuMahalakshmi_2-1745341603941.pngBanuMahalakshmi_3-1745341660253.png

Step 4: If the location does have an active location support group, then update the assignment group with this value.

BanuMahalakshmi_4-1745342125993.png

 

Issue: my flow didnt trigger after creation of task, it didnt check there conditions. Thanks.