Name

sn_csm_lv.CSMLookupVerifyAjaxUtil

Description

Helper methods for Lookup and Verify feature

Script

var CSMLookupVerifyAjaxUtil = Class.create();
CSMLookupVerifyAjaxUtil.prototype = Object.extendsObject(global.AbstractAjaxProcessor, {
  
  getConfigSysId: function() {
  	var configId = this.getParameter('sysparm_configId');
  	// Method needs to be in a global scope for addDomainQuery to work
  	if (gs.getProperty("glide.sys.domain.use_record_domain_for_processes") == 'true') {
  		var table = this.getParameter('sysparm_table');
  		var recSysId = this.getParameter('sysparm_recSysId');
  		return new global.CSMDomainLookupVerifyUtil().getConfigSysId(configId, table, recSysId);
  	}
  	
      var gr = new GlideRecord('sn_lookup_verify_config');
      gr.addQuery('id', configId);          
      gr.addQuery('active', 'true');
      gr.query();
      if (gr.next() && gr.canRead()) {
          return gr.getUniqueValue();
      } else
          return '';
  },

  type: 'CSMLookupVerifyAjaxUtil'
});

Sys ID

0f2d078a733600106dfdbd49faf6a737

Offical Documentation

Official Docs: