Automatic Notification per 2 business days

dianemiro
Kilo Sage

Hi Guys,

Can anyone help me on how to create an automatic notification to requested for of a Request Item if the tickets are still Waiting for Approval and Created more than 2 days. Many thanks for your help.

1 ACCEPTED SOLUTION

dianemiro
Kilo Sage

Hi All,



Thank you ALL so much for your help. All replies are helpful. For record purposes, I will summarize and combine all suggested solution:



Step 1. I created a Template for the Notification.


Step 2. I created an Event.


find_real_file.png


Step 3. From this Template I created a Notification thanks to Kuruva Venkateswarlu and Amlan Pal.


find_real_file.png


find_real_file.png


find_real_file.png


Step 4. I created a Scheduled job (script from @Sneha Binani)


var gr = new GlideRecord("sc_req_item");


gr.addEncodedQuery("stage=waiting_for_approval^sys_created_onRELATIVELT@dayofweek@ahead@2^cat_item=da4e262f3784620065f498a543990ed4");


gr.query();


while(gr.next()){


gs.eventQueue("sap_user.requesters.reminders",gr,"","");


}


For Wednesday:


find_real_file.png


For Friday:find_real_file.png



I was able to complete what I want. Again thank you all!!!


View solution in original post

13 REPLIES 13

rajmasurkar
Giga Guru

Hi Diane,



You need to create a scheduled job which will run daily.


In scheduled job, you need to mention the condition if there are any tickets in 'Waiting for Approval' state and created before 2 days.


It its 'Run this script' part, you need to add an event to fire the required notification.



Regards.


Raj


Hi Rajmasurkar,



I am new to scripting. Can you guide me on how to configure the event and the scheduled job? Also I only need it to run every 2 (two) business days or Wednesdays and Fridays and not everyday. I appreciate your help. Many thanks.


Hi Diane,



I think, Sneha Binani has explained it well in her response.



Regards,


Raj


amlanpal
Kilo Sage

Hi Diane,



You need to configure the Email Notification on Requested Item (sc_req_item) table with the conditions and other configurations as of below screenshots:


find_real_file.png


find_real_file.png



I hope this helps.Please mark correct/helpful based on impact