- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2022 02:48 AM
I have created a link "click here to reopen the incident" on Email script but it should be button not link on email. can any one help me where i am missing the point in below script.
(function runMailScript( /* GlideRecord */ current, /* TemplatePrinter */ template,
/* Optional EmailOutbound */
email, /* Optional GlideRecord */ email_action,
/* Optional GlideRecord */
event) {
var url = '<a href="mailto:' + gs.getProperty('glide.email.reopen.incident') + '?subject=Re: Please reopen' + current.number + '&body=You can type a message before this text. Please do not edit the Subject or remove the following text: , or the record will not reopen%0D%0A' + email.watermark + '">' + 'click here to reopen the incident' + '</a>';
template.print(url);
})(current, template, email, email_action, event);
Thanks
SP
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2022 11:02 PM
Hello,
It should be like this:
var url = '<a href="mailto:' + gs.getProperty('glide.email.reopen.incident') + '?subject=Re: Please reopen' + current.number + '&body=You can type a message before this text.
Please do not edit the Subject or remove the following text: , or the record will not reopen%0D%0A' + email.watermark + '"><img src=\"PIC.jpgx\" /></a>';
Best regards,
Boyan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2022 11:57 PM
In case you want to customize the styling of this button, or any other cosmetic changes then you can copy the OOB Notification email script and create a new one and make changes on your new custom Notification email script.
For reference attaching the link for Notification script as well:
https://instance.service-now.com/nav_to.do?uri=sys_script_email.do?sys_id=f25bc270d711120035ae23c7ce610323
Replace "instance' with your instance name.
Hope this helps. Please mark the answer as correct/helpful based on impact.
Regards,
Shloke
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-20-2022 02:05 AM
Hi,
Did you try the solution which I have proposed. Feature is available OOB, so why do you want to customize by adding a new code?
Regards,
Shloke
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-20-2022 02:22 AM
when i click on that button it should redirect to outlook email not to incident form.
Thanks for your response.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-20-2022 03:40 AM
okay. Not an issue. Please refer the below blog which contains exactly what you are looking for:
https://community.servicenow.com/community?id=community_article&sys_id=b9023a9ddbc4e4d43daa1ea6689619af
Hope this helps. Please mark the answer as correct/helpful based on impact.
Regards,
Shloke
Regards,
Shloke