Permissions

In my previous apps, I was able to add “Edit” functionality and assign that to a specific user group. That function appears to be missing now. Where do I lock a sheet down to only allow certain people to edit?

That depends on how you are allowing users to navigate to an Edit Screen. Could be condition on buttons, actions, other components. What is your app flow to allow users to edit data? Screenshots help a lot.

1 Like

In the previous version, I was using a inline list to allow edits (as the screenshot shows). Inline lists are no longer available and I now use a collection. I can add an action to the collection which allows edit but there doesn’t appear to be the same option to select who has permissions to edit.

image

It’s still there, just in a different place. Look for Actions in the right hand side configuration panel.

2 Likes

Yes, I saw that but how do do you define which roles have permissions to edit?
If I enable that setting, every user of the app can edit the data within the collection.

There are many ways to do that.
But essentially you need some column in your User Profile table that identifies which users you want to allow to edit. It could be as simple as a Boolean type column, and you set it to true for users that should have edit permissions, and then use that as an editing condition.

Or it could be tied to a specific role, or roles. So you might have something like “allow editing where Role is Admin”, and then give that role to some of your users.

It’s totally up to you to decide how to manage it.

I am getting the impressions I am being completely stupid here.
I already have a users table where I have identified a few people with the role of administrator. the others are read only.
What I can’t figure out how I add the edit action to only users with a role of administrator. There isn’t that option in the add action function.

Don’t stress, we’ll get there :slight_smile:

When you click on the “Add Condition”, you should see something like the below:

If you don’t see an option to choose from your User Profile, it could be that your User Profiles are not correctly configured.

If after checking that you still don’t see it, perhaps show me what you do see (screen shot) and we can figure it out from there.

I’ve got it now. Thanks. I hadn’t clicked “back to default action” which is why I couldn’t see the screen you demonstrated. What a fool. :slight_smile:

Now I just need to figure out how I can limit editing to only one row of data specific to one users details.

Do you also know if the size of the text on buttons can be increased within the app?

If the table in question is your User Profiles table, and you only want to allow users to edit their own details, then you can use “email is signed in user” on the editing condition.

It can’t without using CSS, which requires one of the higher subscription levels. But there are lots of options and styles, and you aren’t limited to Buttons for actions. Try experimenting with different components. You can do some neat stuff with the Action Row component, for example.

Brilliant. Thank you very much for your help.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.