Name

global.cxs_SearchContextAJAX

Description

Configures records in the Search Resource Context Configuration cxs_res_context_config table.

Script

var cxs_SearchContextAJAX = Class.create();

cxs_SearchContextAJAX.prototype = Object.extendsObject(AbstractAjaxProcessor, {
  isConfigured: function() {
  	var contextId = this.getParameter("sysparm_context_id");
      
      //Check for any table configurations
  	var stbl = new GlideRecordSecure('cxs_table_config');
      stbl.addQuery('cxs_context_config', "IN", contextId);
      stbl.query();
  	
  	//Check for any record producer configurations
  	var srp = new GlideRecordSecure('cxs_rp_config');
      srp.addQuery('cxs_context_config', "IN", contextId);
      srp.query();

      return stbl.hasNext() || srp.hasNext();
  },
  
  type: 'cxs_SearchContextAJAX'
});

Sys ID

c8cec941ef11211163fc36cba5c0fb02

Offical Documentation

Official Docs: