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

SOLR-15928 Dim add collection buttons in Admin UI when no permission #1371

Merged
merged 5 commits into from Feb 21, 2023

Conversation

janhoy
Copy link
Contributor

@janhoy janhoy commented Feb 17, 2023

https://issues.apache.org/jira/browse/SOLR-15928

This is the first of several permission related edits to Admin UI. The "Add Collection" button was already disabled when user lacked collection-admin-edit, but it was not dimmed/greyed so hard to understand why you could not click.

Skjermbilde 2023-02-18 kl  00 05 23

@janhoy janhoy requested a review from epugh February 17, 2023 23:03
Copy link
Contributor

@epugh epugh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.. canEditCollection() maybe?

@janhoy
Copy link
Contributor Author

janhoy commented Feb 20, 2023

LGTM.. canEditCollection() maybe?

Yea, just tried to get a shorter version of isPermitted(permissions.COLL_EDIT_PERM), but perhaps it is just as good to spell the permission out in HTML every time than to make $scope.canFoo variables for everything?

@chatman
Copy link
Contributor

chatman commented Feb 20, 2023

It might be confusing as to why everything is disabled. How about changing the mouse cursor to not allowed one on hover? https://www.w3schools.com/cssref/pr_class_cursor.php

@janhoy
Copy link
Contributor Author

janhoy commented Feb 20, 2023

It might be confusing as to why everything is disabled. How about changing the mouse cursor to not allowed one on hover? https://www.w3schools.com/cssref/pr_class_cursor.php

That's exactly what this CSS does already :-)

@janhoy
Copy link
Contributor Author

janhoy commented Feb 21, 2023

Now also disabling "Reload" button.
Skjermbilde 2023-02-21 kl  14 14 39

@janhoy janhoy merged commit 5f6ddbf into apache:main Feb 21, 2023
@janhoy janhoy deleted the SOLR-15928_dim_add_collection branch February 21, 2023 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants