how to apply same filter that is displayed in the modal when clicking on search icon(type reference)

samurai2
ServiceNow Employee
ServiceNow Employee

I want to use this filter (highlighted in red) that comes with the modal as a Preset Record viewport modal into my custom modal, but I don't know how to implement it.

Screenshot 2024-11-21 at 1.18.05 PM.png

 

10 REPLIES 10

If it's a custom modal then you can try adding the Condition Builder component in the modal and configure it accordingly. the search icon that you are referring to is called Field Decorators, where through action assignment it is configured.

https://<YOURINSTANCENAME>.service-now.com/sys_declarative_action_assignment.do?sys_id=c6542741ff13101035be517f793bf1bb&sysparm_view=decorators&sysparm_record_target=sys_declarative_action_assignment&sysparm_record_row=1&sysparm_record_rows=4&sysparm_record_list=model%3D15920e6d534723003eddddeeff7b1244%5Etable%3Dglobal%5ElabelSTARTSWITHSearch+For+Record%5EtooltipSTARTSWITHSearch+for+Record%5EORDERBYDESCsys_updated_on

 In the action assignment payload definition is mapped and subsequently Event mapping is done. You can try with this approach but I haven't tried it before so can't tell exactly.