"Additional Comments" , is not populating in Notifications

NiKhil70
Kilo Guru

Hi ,

I am facing some issue in Email Notification.

If the user updates his comments in the "Additional Comments" , Email should be Triggered to the Requester .

Requester is getting Email Notifications but the comments are not populating in the Email Body .

The recent update only should be populated in the Email Body   .

I tried in this way : 

Hi ${request.requested_for}  ( working fine )

template.print(current.comments.getJournalEntry(1)); ( Not working -Here the comments should populate )

Please give some suggestions.

Thanks

NR

 

 

1 ACCEPTED SOLUTION

Navigate to Notification Email Scripts under System Notification and you could add it here.

Thanks!

View solution in original post

12 REPLIES 12

Ok,

 

I did you create a notification email script with this code?
find_real_file.png

and did you add this email script to the body of your email as following
${mail_script:'Script Name'} see my example below

find_real_file.png

NiKhil70
Kilo Guru

I created a Email Notification :

Under "what it will contain" - > Message HTML - > 

------------------------------------------

Hi ${request.requested_for}

 

current.comments.getJournalEntry(1);

Thank You.

-------------------------------------------------

This is what i added in the email content .

Here Requester name is correctly showing , how ever the comments which were entered in the "Additional comments" are not showing there .

For Ex : If the user enters "Testing" in "Additional comments" in the Incident , "Testing" should be shown in the Email Body .

If the use ${comments} , i can see all the earlier comments as well , but i want only the Recent comments.

Thanks

NR

Hello,


current.comments.getJournalEntry(1); is a script it wont work directly on the notification body. You need to create a mail script and add the script in it and then include the mail script on your email body.

 

Thanks

Alikutty A
Tera Sage

This should work for you

 

1) Create a mail script named add_comments and add the script in it

template.print(current.comments.getJournalEntry(1));

2) Include the mail script in your notification HTML body as

${mail_script:add_comments}

 

Thanks!

 

Hi Ali ,

1) Create a mail script named add_comments and add the script in it

template.print(current.comments.getJournalEntry(1));  

Where should i create the above one ? Could you please elaborate your answer . 

2) Include the mail script in your notification HTML body as

${mail_script:add_comments}  ( I understood , i can do that )

Thanks

NR