https://www.servicenow.com/community/developer-forum/how-do-i-put-an-or-condition-in-this-script/m-p/1545979
gliderecord or
gr.addQuery('active', true).addOrCondition('closed_at', '>', gs.daysAgoStart(120));
dot walk for reference field
https://www.servicenow.com/community/developer-forum/dot-walking-in-a-gliderecord-addquery/m-p/1748883
var gr = new GlideRecord("hr_case");
gr.addActiveQuery();
gr.addQuery('parent.ref_sm_order.template', '16c971f9db58ec14066c4f63059619b8');
gr.query();
gr.next();
gs.log(gr.number); var grm = new GlideRecord('sys_user_grmember');
grm.addQuery('group.name', 'xxx').addOrCondition('group.name', '=', 'xxxxx').addOrCondition('group.name', '=', 'xyx');
grm.query();
while (grm.next()) {
userArray.push(grm.user.sys_id);
}
No comments:
Post a Comment