+ Start a Discussion
John Shaffer 3John Shaffer 3 

Omni Channel Agent Work trigger

Hello,

My developer created a trigger to copy the Accepted Date value from the Agent Work Object to a read only field on the case object.  It doesnt work consistently.  According to SF support it will not work.  Does anyone have any suggestions?


trigger AgentWorkTrigger on AgentWork (before insert, before update, after insert, after update) {

    AgentWork_CaseHandler.setCaseDatetimeAccepted(trigger.new);    
}
Amit Singh 1Amit Singh 1
Hello John,

If you want to copy the Accepted Date value from the Agent Work Object to Case Object then you can create a new field in Case Object which will be as same datatype as Accepted Date and then copy the value to this field. Then create new formula field which will contain the value of previously created field.

Let me know if this helps:)

Thanks!
AMit Singh