- Issue created by @penyaskito
- 🇷🇴Romania amateescu
I'm on the fence about this.. on one hand, a trashed node shouldn't be available to the system unless it is restored, so for that case it would be "works as designed" and the Devel tab shouldn't be visible at all(?), however the Devel tab might be useful for a developer or site builder for debugging purposes, so we might want to make an exception.
What do you think?
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
That's actually why I didn't add a proposed solution and classified as minor.
This happens with any local task. For devel I wouldn't care that much, but if I use entity_clone: do I want to allow to clone trashed content? It should be on a case per case basis. I think we shouldn't care about exceptions for now, and hide all if possible, but if I have the "view deleted entities", tabs will be visible based on permissions.
- 🇦🇺Australia pameeela
Just noticed this with the 'Clone' tab. FWIW I don't think it is necessary to be able to clone trashed content, so probably the right solution is that the links shouldn't appear if they don't work.
- Merge request !30Add a route processor that persists the 'in-trash' context on relevant pages. → (Merged) created by amateescu
- 🇷🇴Romania amateescu
Found a way to persist the "in trash" context for all links displayed on a page where a deleted entity is displayed. Tested with the Devel local task and it seems to be working great.
@pameeela, I also tested with the Entity Clone module, but the
Clone
tab did not appear when I was viewing a deleted node. That's the correct behavior by the way becausetrash_entity_access()
denies access to any entity operation, but now I'm curious how you were able to see it in your testing :) -
amateescu →
committed 943c6a91 on 3.x
Issue #3398774 by amateescu: Trash breaks any local tabs on trashed...
-
amateescu →
committed 943c6a91 on 3.x
- 🇦🇺Australia pameeela
It was probably Quick Node Clone since that was in Drupal CMS at the time!
- 🇦🇺Australia pameeela
FWIW, we are now using ECA for duplicating, and it works even on content that is in trash :)
- 🇷🇴Romania amateescu
I just checked Quick Node Clone and its tab is now working properly, you can clone a deleted node and create.. a new deleted node :) Not sure if that's actually an improvement (same for duplicating using ECA), but if those modules are not checking entity access there's not much we can do about it.
- 🇦🇺Australia pameeela
Thanks for checking that! I think it's OK that it works this way. It would be fine if the links weren't there, but as long as they work it doesn't seem like an issue.
Automatically closed - issue fixed for 2 weeks with no activity.