email script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2024 07:58 PM
Hi Team ,
can anyone please help me in the , mail script
I want print for a specific catalog item variables in the notification .
i have written mail script for this
Please correct if there is any mistake in notification configuration
Preview is showing like this
Catalog Item variables
OUTPUT has to come like this
SUB :- Short desciption
Body
"A lost or stolen device has been reported by" <Requested For>
The device was lost or stolen on <Date item was Lost/Stolen>
[Blank Line]
"Description:"
<Description>
can anyone please help me here .
what was the mistake .
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2024 08:52 PM
Hi @nameisnani ,
I see there is a space in your HTML body, which is causing the issue (email script does not exist). Try without space like this ''${mail_script:after_line_manager_approval}.
Regards,
Dhanraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2024 09:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2024 10:00 PM
Try the below script and make sure all the backend value of the variables are correct. I'm not sure where you defined your description value.
var requester = current.requested_for.getDisplayValue();
var date = current.variables.date_item_was_lost_stolen;
template.print('A lost or stolen device has been reported by '+requester+' \n The device was lost or stolen on '+ date+' \n \n Description:<Description>');
Regards,
Dhanraj.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2024 09:10 PM
Hi @nameisnani ,
The error is coming up because of the span tag.
In order to fix this please follow the steps mentioned in below post:
Mark this as Helpful / Accept the Solution if this clears your issue
Mark this as Helpful / Accept the Solution if this helps.