The CreatorCon Call for Content is officially open! Get started here.

Create a custom list collector that allows users to select options from a record's information

Vee Jay Recana
Mega Guru

Hi Community!

 

I have a requirement that requires allowing users to select multiple options like a list collector variable in an MRVS in a catalog item. The options would be coming from a record in network adapter table (cmdb_ci_network_adapter). So, we have to manually add options to the custom list collector variable. Since addOption is not supported in the OOB list collector, it's not possible for me to use it.

 

For example, Network adapter A has a custom field Proxy IP (u_proxy_ip), I want the Proxy IP information to be pushed as an option to the variable and allow me to select multiple options.

 

Anyone had a similar requirement or implementation? Or even any idea how can I achieve this requirement?

 

Thank you!

3 REPLIES 3

Ankur Bawiskar
Tera Patron
Tera Patron

@Vee Jay Recana 

you want user to select multiple network adapters from existing table "cmdb_ci_network_adapter" then why to add new options?

You can show u_proxy_ip field when user starts typing values in list collector

Use variable attributes

See Example below

ref_auto_completer=AJAXTableCompleter,ref_ac_columns=category;serial_number,ref_ac_columns_search=true,ref_ac_order_by=name

Variable attributes sections

AnkurBawiskar_0-1759917870975.png

 

Output: I have added category and serial_number as extra fields to be shown along with name

AnkurBawiskar_1-1759917870979.png

 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar ,

 

Because, in our MRVS for the catalog item, we have 3 fields
List collector variable = referenced to Network Adapter table
Single line text variable = populated based on the selected data from list collector

Another variable for Proxy IP = multi select

Each variable is being pushed to our payload for our integration. Showing more information in the list collector will not allow us to push data to the payload and our client wanted to implement the UI like that.

@Vee Jay Recana 

the users are already selected multiple Network Adapters and each has it's Own proxy IP value.

What logic it makes to allow again selection of Proxy IP when they already selected Network Adapters?

Doesn't look like a valid business requirement.

As a consultant please inform customer about the best practices and not all requirements are meant to be done.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader