Inbound Action for Email processing help

BrianS344076034
Tera Guru

Hello, our team has created a custom group / app for HR that allows them to create tickets etc.

Its designed so the HR person can reply to the person from the incident and then the user can reply back, works like the incident table for all intents, but HR has noted that when a user replies, the ticket is not updated.


What I can see is the email reply is getting added to the case in the email related items, but the actual update from the email is not getting added to the comments.


This is what I tried so far and not having much like

Flow Designer

Trigger - inbound email

Type is received

Target Table is x_cinep_workday (custom table)

 

Look up 

Sys ID is Trigger ... Sys ID

Update Workday Incident Record

 

This works if I'm the one who replies to a ticket in my name with HR....but not for anyone else

 

Then I tried Inbound Actions

 

Name - Update Workday Ticket

Target Table - Custom table

Action Type - Record Action

 

When to run

Type - Reply

Target table - custom table

Type is recieved

 

Actions

gs.include('validators');

if (current.getTableName() == "Workday Incident") {
    current.comments = "reply from: " + email.origemail + "\n\n" + email.body_text;
   
    if (gs.hasRole("itil")) {
        if (email.body.assign != undefined)
            current.assigned_to = email.body.assign;
       
        if (email.body.priority != undefined && isNumeric(email.body.priority))
            current.priority = email.body.priority;
    }

    if (current.canWrite())
        current.update();
}

 

 

but it still doesn't seem to process any replies, any thoughts?