Access control formula (security) for membership

"Access control formula (security) for membership in an app I have built using AppSheet: I want to implement an access control formula that manages membership permissions in my app. I have the following membership types:

  1. Gold Membership,
  2. Silver Membership,
  3. Bronze Membership,
  4. Explorer,
  5. Commander,
  6. Dealer, 
  7. Admin (Collectium Bro).

The goal is to allow all members to view the content, but with different permissions. Admin (Collectium Bro) should have full access to view and modify all information. The other membership types should be able to view their own content and make changes to their own profiles, including the ability to change their membership type to one of the following options: Gold Membership, Silver Membership, Bronze Membership, Explorer. Can someone help me formulate an access control formula that provides the appropriate permissions based on the membership types? Thank you in advance for your assistance!"

Solved Solved
0 4 169
1 ACCEPTED SOLUTION

4 REPLIES 4

Schaue folgendes Video, dort wird detailliert erklรคrt wie dies zu ermรถglichen ist:

 benutzerdefinierte Benutzerberechtigungen  

My formula it doesn't work.

I have table name "Brukere" column name is "Rolle" which contains {"Gold Membership", "Silver Membership", "Bronze Membership", "Retailer", "Explorer"}),
My administrators are "Collectium Bro" and "ADMIN"

And I need a formula as each user can see their own information but not others, admin can see everything.

That's my formula for security setting..

"Rolle"=Any(Select(Brukere[Rolle],"E-postadresse"=USEREMAIL()))

Or this

IFS(
ANY(Brukere[Rolle]) = "Collectium Bro", TRUE,
ANY(Brukere[Rolle]) = "Admin",
OR(
[E-Postadresse] = Useremail(),
AND(
IN([Rolle], {"Gull Medlemskap", "Sรธlv Medlemskap", "Bronse Medlemskap", "Forhandler", "Explorator"}),
IN([E-Postadresse], Brukere[E-Postadresse])
)
),
TRUE,
[Rolle] = Useremail()
)

If I use one of these, all information disappears.


@Collectiumbro wrote:

my formula for security setting


Be sure you're distinguishing between a table's property that controls data access permission and its property that controls data editing permission

Once you're sure you're entering your expression in the appropriate property, your troubleshooting should probably focus on the following points:

  • When you intend to reference a column's value, be sure to enclose the column name in brackets (not quotes).
  • When you intend to reference values from a table's single row that corresponds to the current user, be sure to return that single row (e.g., using a slice).

 

Top Labels in this Space