-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Update for #15534 - Refined gates on user bulk #15563
Conversation
Signed-off-by: snipe <[email protected]>
PR Summary
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like making this more detailed 👍🏾
One thing to note is that we only display the bulk actions dropdown if the user has the ability to delete users. Should we update that so it individually takes into account which actions should be shown?
@can('delete', \App\Models\User::class) |
I don't think that's true? snipe-it/resources/views/partials/users-bulk-actions.blade.php Lines 1 to 23 in 9f8473e
|
Signed-off-by: snipe <[email protected]>
@marcusmoore I just added some gates around the dropdown menu - take a peek |
Signed-off-by: snipe <[email protected]>
Signed-off-by: snipe <[email protected]>
Signed-off-by: snipe <[email protected]>
@marcusmoore Derp - you were right about the delete gate - that's dumb. I removed that and only applied it where it matters. I moved merged into the delete gate though, since technically anyone who can merge a user is deleting a different user(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dig it 😄
Just a slight revision for #15534, where we use a looser gate for starting things off, and then refine the gates based on ones that might need more permissions.