Name

sn_em_ai.RelatedListItemCandidateFilter

Description

Implements extension point global.RelatedListItemCandidateFilter

Script

var RelatedListItemCandidateFilter = Class.create();
RelatedListItemCandidateFilter.prototype = {
  initialize: function(tableName, parentFieldName, parentRecordSysId, referencedFieldName) {
  	this.tableName = tableName;
  	this.parentFieldName = parentFieldName;
  	this.parentRecordSysId = parentRecordSysId;
  	this.referencedFieldName = referencedFieldName;
  },
  getFilterQuery: function() {		
       return "correlation_group!=1^parent!="+this.parentRecordSysId+"^ORparentISEMPTY^sys_id!="+this.parentRecordSysId+"^state!=Closed^maintenance=false";
  },
  
  handles: function(thing){
  	return thing == "ADD_TO_GROUP";
  },

  type: 'RelatedListItemCandidateFilter'
};

Sys ID

6eb8a9bab7330010c9a22fb9ee11a9b5

Offical Documentation

Official Docs: