<sn-record-picker field="location" table="'cmn_location'" display-field="'name'" value-field="'sys_id'" search-fields="'name'" page-size="100" ></sn-record-picker>
Property
Description
field
a JavaScript object consisting of "displayValue", "value" and "name"
table
the table to pull records from
default-query
the query to apply to the table
display-field (or display-fields)
the display field
value-field
the value field (usually sys_id)
search-fields
the fields to search
page-size
number of records to display in dropdown
How to create Reference Fields with the snRecordPicker Directive in Service Portal widget ServiceNow
Working Code Asked question August 8, 2023