HI,
I have created an accident reporting app linked to SharePoint(SP) list. I'm trying to restrict 'varUser' (manager) to only see the Team(s) I want them to have permission to see (data security protection). The higher up the management chain, the more teams they see.
I have created a separate 'Accident team permission' SP list to act as a lookup, with each team being a column (CS1, CS5, EDU11) and a list of e-mails for who I want to have permission. The code I created stops at the first team, I do understand why, but can't think how to correct it so they can see multiple teams if they are further up the management chain and appear in my permisions list. I kind of want If, they appear in this team, then display and this team and this team.... This code sits in my Gallery Items;
If(Lower(LookUp('Accident team permissions', CS5 = varUser.Email).CS5) = Lower(varUser.Email),
Filter('Accident/Incident', 'Sub team' = "The Lodge Nursery"),
Lower(LookUp('Accident team permissions', CS1 = varUser.Email).CS1) = Lower(varUser.Email),
Filter('Accident/Incident', 'Sub team' = "Cressingham"),
Lower(LookUp('Accident team permissions', EDU1 = varUser.Email).EDU11) = Lower(varUser.Email),
Filter('Accident/Incident', 'Sub team' = "Pinecroft"))
Any help/tips much appreciated Clyde123

Report
All responses (
Answers (