I added a user to a particular org unit. i then added a org unit lookup for a particular entity. I want users on org unit A to only see entities on org unit A.
What I did is not working...what do I do?
4 Answer(s)
-
0
hi Please check out organization's documentation.
Filter Entities For A User
We may want to get all products that are in the OUs of a specific user. Example code:
https://aspnetboilerplate.com/Pages/Documents/Zero/Organization-Units#filter-entities-for-a-user
-
0
Let me work on this, I will let u know
-
0
@siyeza Thanks.
-
0
Turns out your suggestion there works really well and if you want to ignore (say entities that are not assigned to unit)...this below does the trick.
.... entities not assing to any org unit will be shown to everyone.
(yourOrgnanisationalUnitCodes.Contains(x....somecode) ||string.IsNullOrWhiteSpace(x...somecode))