Is it possible to send Change Approval reminders to only those who have not yet approved?

rp24
Kilo Explorer

As of now in our Change Management workflow, the approval reminders are set to send to the CAB-Approvers group. The users within this group who have already approved the change still receive the reminder email along with the users who have not yet approved.

Is it possible to modify this so that only the users within this group who have not approved yet will receive the reminder email?

5 REPLIES 5

Chuck Tomasi
Tera Patron

Hi Ryan,



I invite you to take a look at a scriptless solution I wrote for use cases such as this.



Scriptless scheduled jobs


Ok, yeah that makes sense.I think what had me confused is we don't have a scheduled job set up for these reminders. They fire off from within the Comprehensive Change workflow as a "Notification" Activity Property seen below; So I am only able to select certain users or groups, there are no conditions available to allow me to stop the reminder email from sending to the users who have already approved the change.



So the best bet would be to scrap this step from the Workflow and set up a Scheduled Job?



find_real_file.png


sachin_namjoshi
Kilo Patron
Kilo Patron

Hi Ryan,



You can create a Scheduled job for this, schedule it to run everyday and send out email reminders to all the approvers. Create an event approval_reminder, then create an email notification in which you specify this event. You can write something like this in the Job:-.





  1. var gr = new GlideRecord('sysapproval_approver');      
  2.       gr.addQuery('state', 'requested');      
  3.       gr.addQuery('sysapproval.sys_class_name','<your table name>');   //table name like incident,problem etc  
  4.  
  5.       gr.query();      
  6.       while (gr.next()) {      
  7.           gs.eventQueue("approval_reminder",gr, gs.getUserID(), gs.userName());      
  8.       }      

In the email notification,for Who will receive, make Users/Groups in fields as 'Approver', it should work fine. Also make sure that you check the 'Send to event creator', its just for testing you can deactivate later.



Regards,


Sachin


FYI - This is exactly the use case I wrote the scriptless solution for. It appears again and again, so why not just set some conditions and let the system sort it out?