How can I add the Request ID in the notification of a MA notification?
Best Answer
-
john_doyle Cireson Support Ninja IT Monkey ✭✭✭✭Using the WorkItemContainsActivity relationship the substitution string should look like this:
$Context/Path[Relationship='CustomSystem_WorkItem_Activity_Library!System.WorkItemContainsActivity' SeedRole='Target' TypeConstraint='CustomSystem_WorkItem_Library!System.WorkItem']/Property[Type='CustomSystem_WorkItem_Library!System.WorkItem']/Id$
5
Answers
https://community.cireson.com/discussion/1802/review-notifications#latest
Been using the fix for about a year and as long as the run books do not stop it works fine.
I had this question come up a long time ago relating to Review Activities and Change Requests. This is the process I used to set this up in my lab.
The problem is that you are trying to reference a reverse association. In this case the Change Request is the source and the activity is the target. I can only tell you how I built it in my lab.
$Context/Property[Type='CustomSystem_WorkItem_ChangeRequest_Library!System.WorkItem.ChangeRequest']/Risk$
$Context/Path[Relationship='SWAL!System.WorkItemContainsActivity' TypeConstraint='SWAL!System.WorkItem.Activity']/Property[Type='SWAL!System.WorkItem.Activity']/Area$
In my case it looks like this:
$Context/Path[Relationship='SWAL!System.WorkItemContainsActivity' SeedRole='Target' TypeConstraint='CustomSystem_WorkItem_ChangeRequest_Library!System.WorkItem.ChangeRequest']/Property[Type='CustomSystem_WorkItem_ChangeRequest_Library!System.WorkItem.ChangeRequest']/Risk$
The Relationship comes from step 2, then SeedRole='Target'. The TypeConstraint is the taken from step 1. If you copy how I have done it above it should work.
Either way will work, unless one of the relationships is not available.
I'm glad it worked for you. Can you please flag the post which answered the question with the answer button? Thanks