genericTemplateObject

You can use this object to interact with the Application Specific Information and Application Specific Information Tables stored as generic template information on licensed professionals and conditions

Version

2.0

Constructors

Loads the genericTemplate objects and makes object data accessible through the read only parameters.

Parameter Type Description
gtmp genericTemplateModel Generic template model from which to read information from.

Example

var cond = aa.capCondition.getCapCondition(capId,445392).getOutput(); 
var tmpObj = genericTemplateObject(cond.getTemplateModel()); 

Parameters

Parameter Description
ASI An associative array comprised of data from all the ASI fields that the generic template contains as an associative array. The constructor sets the associated hasASI flag to true if the function finds valid ASI fields during creation. The object stores the associative array as ASI[label name] format.
ASIT An associative array comprised of data from all the ASIT fields that the generic template contains as an associative array. The constructor sets the associated hasASIT flag to true if the function finds valid ASI fields during creation. The object stores this table in the ASIT[tableName][row][column] format.
hasASI Boolean flag set to indicate if object has valid ASI loaded.true = valid ASI found false = no ASI found
hasTables Boolean flag set to indicate if object has valid ASIT loaded.true = valid ASIT found false = no ASIT found

Example

If(tmpObj.hasASI) 
  var tmpObj = tmpObj.ASI["My ASI Field"]; 
//List all ASI 
If(tmpObj.hasASI) 
   For(a in tmpObj.ASI) 
      logDebug(a + " : " + tmpObj.ASI[a]); 

Example

//List all ASI Table values 
If(tmpObj.hasTables) 
   for(table in tmpObj.hasASIT) 
      for(row in tmpObj.hasASIT[table]) 
         for(col in tmpObj.hasASIT[table][row]) 
            logDebug(table + " : " + row + " : " + col + " : " + tmpObj.hasASIT[table][row][col];