- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
I have created the reference qualifier visible in the screenshot to only display users where the company is the same as for the logged in user. Unfortunately it does not work, it still displays all users from sys_user:
Full javascript: javascript:gs.getUser().getCompanyID()
Any ideas what could be the issue?
Any ideas how to best debug this?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
Thanks all for the extensive information. I made it work now with a dynamic filter option calling an Ajax Script include which has a function retrieving the Company ID. Marked the option as solution which was closest to mine
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
This is possibly as a result of script sandboxing.
Instead of using a javascript expression, have you tried using the 'is dynamic' operator and 'My Company'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
What do you mean with script sandboxing in this case?
For reference qualifier there is no option is(dynamic) when I select Company as the field. It is there for Manager or Division, but not for Company
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
When running scripts via a filter as you have shown, they are run in a limited sandbox which doesn't have access to the same functions/APIs as the rest of the platform. These will silently fail.
If you don't have a dynamic filter option available, you can easily create one via the 'Dynamic filter options' menu item.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
I created the filter and applied it in the variable and I also check in the background if the function returns a company, but still it doe not work and I get all users as result in the variable. I tested it with my admin, so also missing roles shouldn't be any issue
Any idea what could be wrong?
