How to redirect to approval record ?

MH3
Tera Contributor

Hi All,

I have this task , When I click on 'here' from below notification then It should redirect me to related approval record. The below notification is triggered when record is inserted in RITM table. Please check the image attached.

PS. I have tried ${sysapproval.URI_REF} but it is redirecting to current RITM record.

 

25011.png

1 ACCEPTED SOLUTION

Sonu Parab
Mega Sage
Mega Sage

Hi @MH3 ,
Have a look at this post.
How to make Click here to Reject link in Approval notification to redirect to approval record, do no... 

If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!
Thank you

View solution in original post

6 REPLIES 6

Basheer
Mega Sage

Hi @MH3 ,

Try these if there is a reference field for sysapprover table in the RITM. 

${sysapproval.URI}

${sysapproval.URI_REF}

 

If there is no reference field, then you need to do it via email script.

 

Please hit like button if my suggestion has helped you in any way.
Please mark correct if my response has solved your query.

Cheers,
Mohammed Basheer Ahmed.

Hi @MH3 

var approvalRecord = " ";
var gr = new GlideRecord("sysapproval_approver");
gr.addQuery("document_id",current.getUniqueValue());
gr.query();
if(gr.next()){
approvalRecord = gr.getUniqueValue
}

template.print('<a href='+gs.getProperty('glide.servlet.uri')+'sysapproval_approver.do?sys_id='
+ approvalRecord + '>' + "here "+ '</a>');

//if the property doesn't work check if there is property in your instance then only it will work
Please hit like button if my suggestion has helped you in any way.
Please mark correct if my response has solved your query.

Cheers,
Mohammed Basheer Ahmed.

Namrata Ghorpad
Mega Sage
Mega Sage

Hello,

Your notification is on RITM table and there is no any referenced field that is referring to sysapproval_approver table that's why it's not showing the approval record after clicking on link.

You need to write email script for this.

 

Please mark my answer as helpful/correct if it helps you.

Regards,

Namrata

Sonu Parab
Mega Sage
Mega Sage

Hi @MH3 ,
Have a look at this post.
How to make Click here to Reject link in Approval notification to redirect to approval record, do no... 

If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!
Thank you