Automatically resend approval requests which are still pending

hong_cheung
Kilo Explorer

Hello,

Currently approval requests are emailed to the relevant approvers.   However they sometimes do not respond.   Is there a way to keep resending the email request until a reply has been received?

Many thanks,

Hong

30 REPLIES 30

Hi everyone jamiegirouard masha Makosko



Jamie's solution is working great for me but I am hoping that when this UI Action is used it can also set the current approval state back to 'Requested' e.g. where it is used on 'Rejected' approvals by our CHG managers.



I have tried adding the line current.state = 'requested'; to the UI Action but it is not working as I had hoped.



Can anyone please tell me how I could ensure the approval record state is put back to 'Requested' when the UI Action is used?



Many thanks in advance!


Daniel


Hi Daniel,



In order, could you check



1) do you have a current.update() at the end of you UI action?


2) (if yes) do you have business rules or a data policy who could prevent it?


David, thanks for your input - I had clocked the error of my ways, the update line was indeed missing.


Which part is not working?


Where is your resendApprovalEmail() function called? If you are trying to call it in this UI Action you need to add resendApprovalEmail(); on the first line.


Also I believe this function takes in a parameter 'cur', which I think is 'current' in this case and unless you are calling this script from another script you do not need as it is already defined by default and can be referenced as 'current'.