Admin how can view all data

The formula

IN(LOOKUP(USEREMAIL(), User Manager, IsCurrentUser, User Role), List(“Admin”,“Station Incharge”,“User”,“Inspector”))

currently restricts a table’s view to only those users whose email addresses match an entry in the User Manager table and whose role is listed (“Admin,” “Station Incharge,” “User,” “Inspector”). How can this formula be modified to allow an administrator to view all data within the table, regardless of their presence in the User Manager table or assigned role?

Provavelmente, você precisará de uma condição. Use a função IF() para isso. IF(Condição para o administrador acessar, Acesso aos dados da tabela, senão: sua função já existente).

1 Like

You didn’t say how administrators are identified, so I’ve made an assumption:

OR(
  ("Admin" = USERROLE()),
  IN(LOOKUP(USEREMAIL(), User Manager, IsCurrentUser, User Role), List("Admin","Station Incharge","User","Inspector"))
)
2 Likes

Muito interessante!

1 Like

Ben appsheet`in demo sürümünü kullanıyorum. Bu konu ile ilgili farklı birşey yaptım. Sizlere de fikir olması açısından paylaşıyorum.

Ekran görüntülerinde de göründüğü gibi True değer verdiğim yerlere kullanıcı erişim sağlayabiliyor. Diğer kısımlara erişim sağlayamıyor.

Daha fazla bilgi paylaşımı için adresinden bana ulaşabilirsiniz.