on 09-06-2017 8:41 AM
My friends,
I want to create a follow up document for a Service ticket using ABSL script language,the follow up document also is a Service ticket,but not the same process type.
I write the logic in the BeforeSave event of Service Request's root node, when I save one Service ticket, it trigger the breakpoint I have set in the ABSL before,but there is a dump.
I don't know which issue cause the dump.The following is the detail step.
The following picture is the Dump Analysis, but I don't know what's mean, My friend, please help me with this problem, Thank you very much.
import ABSL;
import AP.Common.Global;
import AP.CRM.Global;
//ServiceRequest: Root node
var elTaskRoot : elementsof ServiceRequest;
var instTask = ServiceRequest.CreateWithReference(this);
// ServiceRequest: define party node
var elTaskParty : elementsof ServiceRequest.Party;
var instParty;
instTask.Name.content = "Subject Ticket " + this.ID.content.RemoveLeadingZeros();
if (! instTask.ProcessorParty.IsSet()) {
elTaskParty.PartyKey.PartyID.content = this.ProcessorParty.PartyKey.PartyID.content;
instTask.ProcessorParty.Create(elTaskParty);
}
else
{
instTask.ProcessorParty.Delete();
elTaskParty.PartyKey.PartyID.content = this.ProcessorParty.PartyKey.PartyID.content;
instTask.ProcessorParty.Create(elTaskParty);
}
Hello Chiangjian,
Based on the documentation from the Repository Explorer the action CreateWithReference of the BO ServiceRequest does not support any parameters.
HTH,
. Horst
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Horst,
Thanks for you reply!
I review the BO "ServiceRequest"'s information in the Repository Explorer,I can not see any documentation for the action "CreateWithReference",see the following picture.
I'm trying another way to create the follow up, Although not dump,but the docu flow of the two tickets is not created.
The code as following:
import ABSL;
import AP.CRM.Global;
//Assign the Document to the BTD Reference node
var BTDReference: elementsof ServiceRequest.BusinessTransactionDocumentReference;
BTDReference.BusinessTransactionDocumentReference.ID.content = this.ZTicketID2.content;
BTDReference.BusinessTransactionDocumentReference.TypeCode = "118"; //Ticket Type
BTDReference.BusinessTransactionDocumentRelationshipRoleCode = "2";
this.BusinessTransactionDocumentReference.Create(BTDReference);
Sir, please help me check the above code,thanks very much.
Changjian
Best Regard
Hi Horst,
Thank you Sir! The "this.ZTicketID2.content" already exist in the system, I want to create Relationship between the two ServiceRequest,but not success. When I debug into the absl code ,the document flow has been created in the session when read the reference document of one of the ServiceRequest again,but not save to the DB,It seems not commit work. Sir,do you known what's wrong? Thank you very much!
Changjian
Best Regard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.