How to get "Email body" to the "comments"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 08:26 AM
Hi everyone Im trying to use an "Inbound Email Action" to get what the user writes on the "Email body" to the "comments" I have been trying to use the "email.body_text" but for some reason it just does not work, it is actually breaking the code ... can anyone help with this?
Code:
if (email.subject.indexOf("reject") >= 0) {
current.comments = 'Rejection Cause: ' + email.body_text;
current.active = false;
msgArray.push(displayValue);
current.u_rejected = true;
current.update();
}
if (email.subject.indexOf("approve") >= 0) {
current.u_approved = true;
msgArray.push(displayValue);
current.update();
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 08:55 AM
Does your action have create/write access to the table it is targeting?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 09:35 AM
Yes, could the problem be that the "Additional comments" are "Readonly" ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 09:40 AM
Hi @F_bio Santos ,
If you are referring to Additional Comments , they are stored in sys_journal_field , hence if you are updating comments for a RITM or Incident you might want to first update it in sys_journal_field.
Please mark helpful/correct if my response helped you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-10-2024 10:05 AM
Hi @Anubhav24 I dont want to update an already existing one, I want to create a new entry wityh the "body" of the email