Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define Admin UI options per user role #931

Open
mateuswetah opened this issue Nov 8, 2024 · 0 comments
Open

Define Admin UI options per user role #931

mateuswetah opened this issue Nov 8, 2024 · 0 comments
Labels
[Effort] Level 3 🧐 [Module] Admin [Project] Gestão de Acervos [Project] IPHAN [Type] Enhancement Feature requests that fit into the project scope and demand will be implemented.

Comments

@mateuswetah
Copy link
Member

Context and motivation

For a long time now, we've had some Admin UI options hidden in code. These options tweak the Admin specially by hidding elements that may overhaul the user with features that he/she might not use. For example, an editor has enough capabilities to run an importer, but they might not need it. They might have access to Activities and Mappers, but again, do not need it. Also, some behaviors like the amount of collections loaded in the home page or the default state of a collapsed menu... these types of decisions that may make sense to be defined in a per-user-role setting but are not tied to actual capabilities. I'm often required to hide things in the admin UI for certain user because Tainacan tries to offer as much power to the user but may loose in simplicity sometimes.

Ideal solution

So far we've made this options available via code but I think it is time to bring to the UI.

A place where this seems to fit and that has been tested before is in the user role form. Here is a screenshot of extra fields added by the IPHAN theme:
Image

For sure it seems a lot but I think we can decide which features make sense to expose now and which should remain code-only. What this theme does is use a form hook to insert the extra tab there, where this options are offered to be stored in a traditional wp-option field, separated by user role. Then, using our tainacan-admin-ui-options filter, the options are loaded into the Vue Admin component.

I think we can replicate the same idea, creating a new tab focused on UI tweaks per user role.

Alternative solutions

We may consider that "it is too much" to offer this on a per user role basis and decide that this should only be a feature of the plugin settings screen, something coming next in the 1.0 redesign #494 and #881.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Effort] Level 3 🧐 [Module] Admin [Project] Gestão de Acervos [Project] IPHAN [Type] Enhancement Feature requests that fit into the project scope and demand will be implemented.
Projects
Status: Backlog
Development

No branches or pull requests

1 participant