Home General Discussion

Send Primary Owner notifications if they are not also the Analyst

Steve_ClarkeSteve_Clarke Customer Adept IT Monkey ✭✭

Hi All,

As per the title we would like to send notifications to the Primary owner (Create/Update etc) only if they are not also the Assigned To user. Otherwise they would get two notifications. I have raised this as a feature request but am looking for a way to do it in the mean time.

I have tried to create a custom MP to include criteria such as:

                        <ValueExpression>
                          <Property State="Post">$Context/Path[Relationship='CustomSystem_WorkItem_Incident_Library!System.WorkItem.IncidentPrimaryOwner' TypeConstraint='CustomSystem_Library!System.Domain.User']/Property[Type='CustomSystem_Library!System.Domain.User']/UserName$</Property>
                        </ValueExpression>
                        <Operator>NotEqual</Operator>
                        <ValueExpression>
                          <Property State="Post">$Context/Path[Relationship='CustomSystem_WorkItem_Library!System.WorkItemAssignedToUser' TypeConstraint='CustomSystem_Library!System.Domain.User']/Property[Type='CustomSystem_Library!System.Domain.User']/UserName$</Property>
                        </ValueExpression>

But the workflow still does not function. I have also tried variations of the above (i.e <Property> (no state) etc).

I have also tried to create a custom workflow that triggers a PowerShell script. This workflow runs and does the comparison (currently just logs if there was a match or not), but I can not see a way in PowerShell to trigger a notification. I don't really want to formulate the email content within PowerShell, I would like to use an existing template..

Very clunky that Service Manager cant meet very basic notification requirements like this out of the box. 

I would appreciate any input if anyone has done this or has any insight on how to complete this requirement?

Thanks,

Steve

Answers

  • Steve_ClarkeSteve_Clarke Customer Adept IT Monkey ✭✭

    For those playing at home I ended up scripting the entire thing in PowerShell (including the body of the email) and creating a custom workflow that executes the script.

Sign In or Register to comment.