email_action Example?

Nawal Kishor Si
Tera Contributor

In Email Script one parameter  email_action . anyone please explain email_action with proper example. i'm not getting how to use this parameter?

Thank you 

1 ACCEPTED SOLUTION

Voona Rohila
Tera Patron

Hi Kishor

email_action contains the GlideRecord for the email notification

 

email_action.name - email notification name

email_action.sys_id - email notification sys_id

email_action.category.getDisplayValue() - email notification category

 

Example:

template.print(" Name:"+email_action.name);
template.print(" sys_id: "+email_action.sys_id);
template.print(" Category:"+email_action.category.getDisplayValue());

find_real_file.png

find_real_file.png

View solution in original post

5 REPLIES 5

Voona Rohila
Tera Patron

Hi Kishor

email_action contains the GlideRecord for the email notification

 

email_action.name - email notification name

email_action.sys_id - email notification sys_id

email_action.category.getDisplayValue() - email notification category

 

Example:

template.print(" Name:"+email_action.name);
template.print(" sys_id: "+email_action.sys_id);
template.print(" Category:"+email_action.category.getDisplayValue());

find_real_file.png

find_real_file.png

Thank you so much 

Anil Lande
Kilo Patron

Hi,

In Email Script email_action is glide Record Object of Email Notification i.e. It store your email Notification record.

When you call any email script from email notification using email_action you can check from which notification mail script is called.

For Example:

email_action.name is Name of your Notification i.e 'TEST Attachments'

email_action.collection is name of table i.e incident

email_action.subject subject added on notification record i.e 'TEST Attachments sent'

 

find_real_file.png

 

 

Thank you