Hello there, I'm trying to figure out the best way to filter a gallery of records (using SharePoint) based one three different user roles. The roles are as follows:
1. User - Can only view records that THEY have created
2. Approver - Can view records that they have created AND records to to which THEY are the approver of (each record has an approver field of type person)
3. Admin - Can view ALL records (I'm assuming I would just simply not add a filter here)
I have boolean variables (isApprover and isAdmin) declared upon running the app that determine if the current user is of either the two roles. This is done with a lookup as a have two SharePoint lists containing all users for each role. I would like to avoid having 3 separate screens if possible. I feel like adding some sort of conditional filter would make sense. Something like "If(isApprover, Approver.Email = User().Email) or something of the sort. PowerApps gets a bit angry when I try putting conditional statements in a filter though. I'm a bit new to PowerApps so I'm sure there's something I'm not doing quite right. If anyone could help me out or tell me a better way of doing this, I would really appreciate it! Thanks!