When a Review Activity becomes ‘In Progress’ in a given Change Request, you probably want to notify each of the Reviewers in the Review Activity that they need to review and approve/reject the Change Request. This is fairly easy to do and in this blog post I’ll show you how.
First we need to create a notification template and then we need to configure the Activity Event Workflow to send the notifications using the notification template at the appropriate time.
To create the notification template, just follow the same general pattern as described in this blog post:
or this one:
Here are step by step instructions to create the notification template:
- Go to the Administration workspace to the Notifications\Templates view.
- Click Create Template in the task pane on the right.
- Enter a name for the template such as ‘Notify Reviewers When to Vote on Review Activity’
- Select the Review Activity class.
- Optionally choose a different management pack.
- Click Next.
- Check the Send as HTML checkbox. Enter a subject, optionally substituting values using the Insert… button.
- Enter the body of the message using the Insert… button as appropriate. One thing you will probably want to do is put in the hyperlink to the analyst portal and pass the ID of the review activity in the URL QueryString. It should look something like this.
- A couple of notes on this: Make sure you use the Work Item ID not the ‘Unknown’ (aka System.Entity) ID in the end of the QueryString there. Of course you will want to use your own server name and port number in your template not ‘smdc.contoso.com:444’.
- Click Next
- Click Create
- Click Close
Now we need to configure the workflow to trigger at the appropriate time and use this notification template.
- First go to the Administration workspace to the Workflows\Configuration view.
- Select the Activity Event Workflow and click Configure Workflow Rules in the task pane on the right.
- When prompted for which class of activities to configure to select the Review Activity class and click OK.
- Click the Add… button.
- Click Next on the General screen
- Specify a name for your workflow
- Choose ‘When a Review Activity is updated’ from the Check for events: drop down. Click Next.
- On the Criteria page of the wizard choose on the Changed From tab to trigger when the Status – Does Not Equal – In Progress. On the Changed To tab choose when Status – Equals – In Progress. Click Next.
- On the Apply Template page, uncheck the box to apply a template. Click Next.
- On the Notifications page, select Reviewers from the drop down and select the notification template created above from the drop down and click Add. Click Next.
- Click Create.
- Click Close
- Click OK.
I’ve also provided the MP here:
All you need to do is import the MP and change the server name in the notification template (and maybe make the template more to your liking).