Open atmediauk opened 3 years ago
Its something I've considered, and technically is possible. I don't have the time or patience to look at it at the moment, but happy to accept a PR to do it. In theory, it should just be a case of adjusting the breadcrumbs api controller to return null for the path.
Yours is a bit of an odd scenario in that view isn't available, but edit is, so I would suggest, seen as the links always take you to view, we may want to look and direct the user to the edit page if the view policy isn't available.
I'm not sure if this is a silly idea or if its even possible but can the plugin respect policies?
For example, in the scenario where a user is not allowed to view a model:
When they edit the record the breadcrumbs still include a link to the
view page
e.g:When clicked, the policy kicks in as it should and results in a 403 but this seems misleading from a UI perspective. Maybe in this scenario that section of the breadcrumb should remain as text (not hyperlinked)?
Thanks for your time.