- Post History
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
on 01-15-2019 07:44 PM
I experienced an issue when some complex catalog items were converted to Service Portal recently. List collectors were locking up on page load for really large numbers of users in the list collector.
It seems that list collectors have a 500 element max before performance significantly degrades.
To solve the issue I created a custom list collector widget. It is build using sn-record-picker and a custom UL element styled to look similar to the oob service portal list collector. It can be read from, and written to using g_form.setValue / g_form.getValue, accepts and responds with lists of sys_ids in the list collector, provides a confirmation popup for remove actions, and offers summary details about the elements in a hover event. The widget is configured via the default value field on the macro variable the widget is attached to in a catalog item.
If anyone wants to play with it, I have attached the widget xml. It has 3 dependencies that need to be added to the widget after importing the widget record:
-dialog-polyfill (SN oob dependancy)
-md5 (https://github.com/blueimp/JavaScript-MD5)
-lodash (https://lodash.com/)