laravel / nova-issues

554 stars 34 forks source link

Force deletion visual bug #4723

Closed KickSchutte67 closed 2 years ago

KickSchutte67 commented 2 years ago

Description:

Laravel uses policies to disable users from certain pages on Laravel Nova. When selecting a list of resources (e.g. every single user), the recycle bin (top right of container) is available for use. Even though my policy tells Nova the user is not allowed to force delete a resource, this option is still available. When the option is clicked, Nova refreshes and all resources are still in the list.

Can this visual bug be fixed?

image

Detailed steps to reproduce the issue on a fresh Nova installation:

  1. Create users via resource
  2. Select all users using the mass selector (top left of container)
  3. Use the mass delete option (top right of container)
  4. Select "force delete selected"
crynobone commented 2 years ago

See https://github.com/laravel/nova-issues/discussions/4474#discussioncomment-3008533