Preview/Edit Email Notfications

ben75
Kilo Explorer

Hi All,

I would take all the help I can get for this one

I need to be able to preview and edit email notifications before they are sent from an incident/change form:

Currently, on the incident form, when we click on a button called "Send emails", several emails are sent to different users.

The idea is to catch these emails in a new related lis before they are sent .The users should then be able to click on the wanted emails from the related list in order to preview and edit them. Once he's done, he should have the possibility to send them from the related list.

My first guess it to use the "preview email" ui action and then adapt it but I'm not sure if I should go down this rode.

It seems very custom so I'm open to alternative solutions..

Any thoughts on this?

Thank you

Ben

9 REPLIES 9

WArnold
ServiceNow Employee
ServiceNow Employee

I know it has been a while on this question but I cannot seem to find an answer and I've done a lot of searching.   

Looking at the code for the UI action "Preview Notification" I see the creation of the UI page "notification_preview".   In the UI page "notification_preview" there is this call: 

            <g:inline template="notification_preview.xml"/>.

I believe "notification_preview."xml references a UI macro.   I cannot find any UI macro named notification_preview.  Are you able to see this UI macro?   I'm working on my own instance and I don't believe it is a permission issue.  My instance is running on London.

How did you give a sysid of the record to notification_preview.xml to use?

Thank you!

I'm just basing it off the Description of the UI Page.

The UI Macro cannot be accessed.

Displays the result of a notification when run against a record.
Parameters are as follows:
sysparm_notification_id = sys_id of the notification
sysparm_target_id = sys_id of the record to run the notification against
sysparm_user_id = optional, defaults to the current user, sys_id of user that is causing the notification to be sent.


ServiceNow Nerd
ServiceNow Developer MVP 2020-2022
ServiceNow Community MVP 2019-2022

harshav
Tera Guru

Hi Ben,

You could try to create a business rule on the sys_email table in such a way that it should be applicated to only your email, and make sure to stop the state in ready until your condition is met.

Here you have the option to access the content of the via field. 

The only issue you might face is that it will drain the performance if you have too many emails.

Please post how that email is getting triggered ie; event-based or condition based.

Now create a UI action which in turn should talk to this table and send the emails once your condition was met.

Thanks

 

 

 

Brandon R1
Tera Contributor

Is there a way to modify the UI Page "notification_preview" to preview an email in Outlook instead of within SN ??  Due to the VML in Outlook, I need to see how it will really look when it's sent. The "Preview Notification" in SN is useless.

 

There are some third-party tools that can show how an email will look in different browsers/applications you can try out, but nothing in ServiceNow that I am aware of.

https://blog.sendblaster.com/2018/08/01/5-email-preview-tools-worth-using/


ServiceNow Nerd
ServiceNow Developer MVP 2020-2022
ServiceNow Community MVP 2019-2022