@pauln wrote:
Hi @emre
This is a very hard issue to pin point - basically 2 times out of 20 tests the API to create an Entity Account has failed to LINK the Account back to the Entity?
The ACCOUNT is Created OK it just does not write back to the Entity Record:
The Script is very simple:
function Check(fPrimary, aName, eType, eCode) { // api.Entity(01234B).Exists() if (!api.Entity(fPrimary+eCode).Exists()) { api.Entity(fPrimary+eCode).Create(eType); api.Entity(fPrimary+eCode).Data("Full Name").Update(aName.substring(aName.indexOf("-")+1)); //dlg.ShowMessage("Exit A - Added Entity:"+fPrimary+eCode+' '+aName.substring(aName.indexOf("-")+1)); } if (!api.Account(aName).Exists()) { api.Entity(fPrimary+eCode).CreateAccount(aName) ; //dlg.ShowMessage("Exit B - Added Account:"+aName+' for '+fPrimary+eCode); } //dlg.ShowMessage("Exit 1 - Entity OK:"+fPrimary+eCode); return 1; }
Since the ACCOUNT is created, and there is no intervention by custom automation I can only assume the issue is internal? This code will go LIVE on Tuesday so will have better understanding of Live failure rate in about 7-14 days time I guess.
Your comments welcome.
EDIT:
Below shows what is passed to the above script from the Custom Search Grid shown in the Multiple Account GIF:Customer Account=ZUCU_Wallets:EntityID={ENTITY NAME}-{ENTITY DATA:Full Name},EntitySearch={ENTITY NAME},EntityType=Customers,EntityCode= House Wallet=ZUCU_Wallets:EntityID={ENTITY NAME}B-{ENTITY DATA:Full Name},EntitySearch={ENTITY NAME},EntityType=Bar Wallets,EntityCode=B Member Wallet=ZUCU_Wallets:EntityID={ENTITY NAME}M-{ENTITY DATA:Full Name},EntitySearch={ENTITY NAME},EntityType=Member Wallets,EntityCode=M Prize Wallet=ZUCU_Wallets:EntityID={ENTITY NAME}P-{ENTITY DATA:Full Name},EntitySearch={ENTITY NAME},EntityType=Prize Wallets,EntityCode=P
Note:
Last parameter 'eCode' would have been BLANK which is correct for Master Entity (Customer).
Posts: 5
Participants: 3