email script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-19-2024 08:51 AM
I have a select box variable for example 'partner' in my catalog item, which is user details as question choices(text is the name and value is the email id).
I have to send notification to the partner field value which was selected during raising the request. For example partner field value is 'ABC'(email is 'abc@exmpl.com') along with the email body.
How can I implement this using email script and notification?
Can anyone please help me out, it is very urgent.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-19-2024 01:00 PM
@abhisek - You should be able to access the value with current.variables.product.toString() within an email script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-21-2024 03:25 AM
Hi @Dom Gattuso
Thanks for your reply.
The 'partner' variable in my catalog item is not a reference field to user table so Can we send notification to the user whom was selected during raising request ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-21-2024 04:14 AM
I don't think the description is clear enough.
"(text is the name and value is the email id)"
So you have choices that have a label (ABC) and a value ("abc@exmpl.com")?
In that case you should be able to use current.variables.partner.toString() to get the value (abc@exmpl.com) of the field.
So you should be able to something like:
gs.eventQueue('email.partner', current, current.variables.partner.toString(), '');
This expects that you've created an event called email.partner.
Then in your email notification you'd trigger the notification from event email.partner and make the recipient event parm 1.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-21-2024 05:24 AM
Hi @Weird
Thanks for your reply.
You are correct.
That select box variable 'partner' has 26 choice values for the catalog item 'abc'.
When request is raised for that 'abc' catalog item whom we select as a value for that 'partner' variable that user must receive the notification (subject : your request is created, and it should populate the request number). 1 particular user an 1 particular group also must receive the notification along with the user we had selected for that 'partner' variable value.