Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

List Collector in Widget

Yee Tong Lam
Kilo Contributor

Hi,

I would like to create a list collector in widget. I know it is OOB item in Service Catalog. Can I apply the same solution in widget? Because in my widget need to have a same functionality dropdown to support my use case. Is there any sample can refer?

 

Regards,

Lam Yee Tong

1 ACCEPTED SOLUTION

Mohith Devatte
Tera Sage
Tera Sage

hello @Yee Tong Lam ,

you can use a service now angular directive called sn record picker in the widget .

Follow this blog and that will help you

https://community.servicenow.com/community?id=community_article&sys_id=7a487c96dbab1010190b1ea668961...

Example:

<sn-record-picker field="location" table="'cmn_location'"  multiple="true" display-field="'name'" value-field="'sys_id'" search-fields="'name'" page-size="100" ></sn-record-picker>

Hope this helps 

please mark my answer correct if this helps you

View solution in original post

3 REPLIES 3

Mohith Devatte
Tera Sage
Tera Sage

hello @Yee Tong Lam ,

you can use a service now angular directive called sn record picker in the widget .

Follow this blog and that will help you

https://community.servicenow.com/community?id=community_article&sys_id=7a487c96dbab1010190b1ea668961...

Example:

<sn-record-picker field="location" table="'cmn_location'"  multiple="true" display-field="'name'" value-field="'sys_id'" search-fields="'name'" page-size="100" ></sn-record-picker>

Hope this helps 

please mark my answer correct if this helps you

Yee Tong Lam
Kilo Contributor

Thanks! This help me a lot and also knowing sn-choice-list support attribute "multiple" as well.

@Yee Tong Lam No porblem.

If it helped please mark the answer correct and close the thread so that it benifits future readers with same query