Working with the ClientEntityContext Service in the Infor CRM (formerly Saleslogix) Web Client

 In a previous post I talked about how to use the ClientEntityContext service to retrieve the current entity Id in client side javascript.  I wanted to expand upon that to detail the other options available to be retrieved by that service.

The properties that are accessible are:

  • EnitityId= the current record’s Id.
  • Description=the defined String Expression for the Entity
  • EntityType = The Sage.Entity.Interfaces implementation name of the Entity.
  • EntityTableName = The underlying SQL table name the entity is bound to.

And here is a sample of accessing these in code. This sample is assuming being on a ticket.

var contextSvc = Sage.Services.getService(‘ClientEntityContext’);
var context = contextSvc.getContext();
var strEntityId = context.EntityId; //Returns the Current Ticket Id
var strEntityDesc = context.Description; //Returns the Entity’s String Expression, i.e. Ticket Number
var strEntityType = context.EntityType; //returns “Sage.Entity.Interfaces.ITicket”
var strEntityTable = context.EntityTableName; //returns “TICKET”



Kris Halsrud

Kris Halsrud is a Senior Analyst / Developer for Customer FX Corporation.

Submit a Comment

Your email address will not be published. Required fields are marked *

Subscribe To Our Newsletter

Join our mailing list to receive the latest Infor CRM (Saleslogix) and Creatio (bpm'online) news and product updates!

You have Successfully Subscribed!