Values Do Not Display in List Collector from Custom Table.

joe_leser
Giga Contributor

Greetings,

I am attempting to use a list collector on a catalog item to display, and allow the customer to pick from, values contained in a custom table. Unfortunately, when accessing the catalog item as the customer, the list collector is displaying without any values. Accessing the catalog item as an administrator, or as a user having the role that "owns" the table, the list collector resolves with the expected values.

I also have a second custom table which is exhibiting the same behavior: table and fields display properly within the platform, but not within the service catalog when using a list collector variable.


Oddly, if I change the variable type on the catalog item to a reference field, everyone who should be able is able to see the values within the full_name field properly.

The display value for the custom table is set to the full_name field. Read security rules for the custom table follow:

  • table - allow read for users with roles table_owner, general_user
  • table.* - allow read for users with role table_owner
  • table.full_name - allow read for users with roles table_owner, general_user

Restating the initial problem with more specifics, when impersonating a user with the general_user role, the full_name field displays as the only field visible to that user within the platform. This is working as expected. Going to the catalog item as that same user, no values are displayed within the list collector. If I perform the same actions as a user with the admin role, or a user with the table_owner role, the full table displays within the platform and the list collector displays the expected values.

I have not found anything in the ui_slushbucket macro that would change the load of values outside of the security rule restrictions.

We are currently running Dublin, Patch 1, Hot-fix 1.

Has anyone else run into this scenario?

Any feedback and assistance is greatly appreciated.

Thank you,

-Joe

4 REPLIES 4

d_cammack
Tera Guru

Hello Joe,
Just as a test, what happens if you remove the 'table.*' security rule?  



Thanks,
David


I traced down at least part of the problem today.



I had forgotten that I implemented a client script which fires onLoad of the catalog item in order to filter the values presented in the list collector. The script restricts the values presented to only those marked as 'active' in the table. Users with my general_user role did not have read access to the field denoting whether or not the record was active. I've added another ACL to allow those users to view the data in the active column as well and now the list populates correctly.



Read security rules for the custom table are now reflected by the following:


  • table - allow read for users with roles table_owner, general_user
  • table.* - allow read for users with role table_owner
  • table.full_name - allow read for users with roles table_owner, general_user
  • table.active - allow read for users with roles table_owner, general_user


On a related note: is anyone aware of a method to accomplish said filtering without granting access to the active field? I'm not certain that it matters in this case, but I can think of several others where I may need to filter 'behind the scenes' on a field that an end user may not have permission to read.



Thanks,


-Joe


HI -- I am needing to do the same thing, and would prefer to do it in one client script instead of an OnLoad catalog client script, per item.   Is this a script you would be willing to share?   My use case is that I am building templates of user access, depending on job.   The templates are in a custom table (cost center, template name (Inside Sales Specialist, etc.).   But I don't want to have to build different items or catalog client scripts to display those templates.     Thank you --



Miriam


Miriam,



I'm not currently aware of a method to filter a list collector without an onLoad or onChange client script.



That said, you can define a variable set which includes the list collector for your templates and then apply the client script to the variable set rather than the catalog item. Once you do that, the client script and the list collector will be applied to each catalog item on which you include the variable set.



The script I'm using to per-filter the results is a slightly modified version of the information I found at SNC Guru.



SNCGuru: Changing the Filter of a List Collector Variable via Client Script



Hope this helps.


-Joe