-
Notifications
You must be signed in to change notification settings - Fork 330
Description
It is often extremely helpful for presentation code to be able to query if the current user is able to perform a certain action so that the UI can show what operations are and are not available to them. Without this, presentation code must either duplicate permissions logic or allow things to fail when users attempt to do things and tell them they aren't authorized.
Can the ability to check what permissions are available on entities be added?
e.g. If the current user is allowed to view and create in a certain namespace but not update or delete then a "capabilities" object for that namespace could be something like { "view": true, "create": true, "update": false, "delete": false }. If such objects exist client-side for each namespace then presentation code (e.g. in React) can easily be rendered differently based on the user's permissions.