I have a “Team Members” Glide Table to store my user profile data. From the form, I can create records just fine. However, it appears that for the new records, the “Role” column values are set to empty at random, even after editing the user profile and explicitly setting the role value. See this screencast: Loom | Free Screen & Video Recording Software | Loom
The Role values also disappear when I refresh the browser page of my app editor. See here what happened when I created a new record and then refreshed the page: Loom | Free Screen & Video Recording Software | Loom
… the “Admin” role got lost again
Has anyone ever experienced this, and what could be the cause/fix?
That’s correct and expected behaviour.
Roles can only be assigned when the user record is created, and only if the creating user has the same role.
Other than that, roles can be assigned via the Data Editor, or via the Glide API.
Oh whaat, really? Then how should we implement a hierarchical user/permissions system? In my app, I need various access levels:
- Admins who can access everything (including other users) and perform all CRUD actions
- Staff who can access anything that Admins allow them to access (mostly read, create, update, not delete)
- Vendors and Agents who only access what is assigned to them
Are you saying that in Glide, Admins can only assign roles to other Admins and not to users “below” them?
You can do this, but you’ll need to use the Glide API if you want to do it in app. If you’ve never used the Glide API, this is a really good use case for the first time doing this. Here are two really helpful explainer videos:
Thanks for the insight and video links.
It’s just a pain that one has to be on the Pro plan to be able to try the API