Topic by Robert North
Content
We have some complex requirements for the Assignment of queues and SLA's based upon Product and Category values. These would be quite complex to implement in Business Rules so I'm thinking of a better way to do it. OPA would be the ideal candidate but we would like to replicate this approach for Wyong who won't be using OPA.
The approach I am trying to get working is:
-creating a Custom Object to store the reference data (Product, Category, Queue, SLA).
-querying then Custom Object using a Custom Process on the Incident Create event.
-updating the queue and SLA values based upon the values retrieved from the custom object.
The problem I'm having is assigning to queue & SLA values, I'm trying the below examples of code that I got from the documentation but I keep getting the error
"Uncaught Exception 'Exception' with message 'Validation failed on create of incident'
--Updating a NamedID SubObject
if($incident->Queue->ID)
$incident->Queue->ID=5;
$incident->Queue = new RNCPHP\NamedIDLabel();
$incident->Queue->LookupName = "test1";
Does anybody know how to assign values to the Queue and SLA Instance fields through a Custom Process on the create Incident event?
Thanks
Bob
Version
Right NOw CX Nov 2013Code Block
Image
