function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ 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