Actionable Case Flows

Richard T
Kilo Guru

Hi

When using actionable case flows the OOB  "Set Needs Attention if additional comments are added by others" marks a case as needing attention when a member of our Service Desk Sends a comment to the Contact on behalf of another member of the team.

Our Service Desk so this quite a lot so we dont really need to "Needs Attention" flag to be set on these occasions.

How can I edit this case flow to exclude them?

Thanks

1 ACCEPTED SOLUTION

parag-mone
ServiceNow Employee
ServiceNow Employee

Hi Richard,

I haven't tested this, but you can try replacing current "else if" statement 

    else if(lastCommentsCreatedBy != inputs.ah_caseRecord.assigned_to.user_name)
       outputs.commentedByOthers = true;

with the following "else if" statement.

  else if(lastCommentsCreatedBy == inputs.ah_caseRecord.contact.user_name)
       outputs.commentedByOthers = true;

This will set the "Needs Attention" flag only when the comment is added by the Case contact.

Thanks,

Parag Mone

View solution in original post

8 REPLIES 8

parag-mone
ServiceNow Employee
ServiceNow Employee

Hi,

Flow "Set Needs Attention if additional comments are added by others" invokes subflow "Check if comment is added by others" which internally invokes Action "Check if comment is added by others". This Action checks for following three conditions -

find_real_file.png

1. If the "Additional Comment" is added by "system" user then set the "Needs attention" flag to false.

2. If the "Additional Comment" is added by the user who is different than case owner (assigned to) then set the  "Needs attention" to true.

3. For every other condition set it to false.

Modify this "Action" script based on your requirements.

 

Thanks,

Parag

Richard T
Kilo Guru

Hi Parag

Thanks for the response.

If I wanted to change the elsif statement so that it only returned tru if the additional comment is added by the contact, how would I code that?

Thanks again.

Richard

parag-mone
ServiceNow Employee
ServiceNow Employee

Hi Richard,

I haven't tested this, but you can try replacing current "else if" statement 

    else if(lastCommentsCreatedBy != inputs.ah_caseRecord.assigned_to.user_name)
       outputs.commentedByOthers = true;

with the following "else if" statement.

  else if(lastCommentsCreatedBy == inputs.ah_caseRecord.contact.user_name)
       outputs.commentedByOthers = true;

This will set the "Needs Attention" flag only when the comment is added by the Case contact.

Thanks,

Parag Mone

Perfect, thank you very much.