Security filter based on groups and not email

bob_evan
Participant II

Hi,

I have an app for my 4 stores and I am currently using security filters to show users data base off their email. How can I set it up so all of my many tables across the app show information to the users if they are an employee of the particular store that is being shown information for? Using the email as the filter doesnt work well here because I might want multiple users to see certain things and not others.

0 5 295
5 REPLIES 5

bob_evan
Participant II

I already have a table setup called โ€œEmployee Listโ€ with the following fields:

Name
Location
Email
Manager

The location field identifies which store they belong too

bob_evan
Participant II

LOOKUP(USEREMAIL(), EmployeeList, Email, Location) = โ€œHooksett Eastโ€

This will work to lock everything in the view to people that work in the location Hooksett East. But this lets the user see all 4 locations as long as they work in Hooksett East.

I do have a location field as well for my tables of data I am talking about

Try this.

[Location] = LOOKUP(USEREMAIL(), EmployeeList, Email, Location)

MultiTech
Participant V

First I would suggest you build in a Current_User system:

Then you can easily pull out the โ€œLocationโ€ from that record and use that in your other security filters.

index(Current_User[Location], 1)

PS: This is essentiallly the same as

only the result of that LOOKUP() is stored in the slice.

Top Labels in this Space