Relevant view permissions should be specified on the history views.
Opened this issue · 0 comments
Hi all
As it stands, zope.View is used on all of the view registrations for the content history related views and the permissions are checked in code instead.
Ie:
https://github.com/plone/plone.app.layout/blob/master/plone/app/layout/viewlets/configure.zcml#L277
https://github.com/plone/plone.app.layout/blob/master/plone/app/layout/viewlets/content.py#L201
As a result, the body element on the website has permission-view on it, tricking some stock Plone5 related code into thinking that this is a 'frontend' view. See https://github.com/plone/plone.app.layout/blob/master/plone/app/layout/globals/layout.py#L213
I have a custom diazo theme that relies on the backend views to be styled using the barceloneta theme. As you can see in https://github.com/plone/plonetheme.barceloneta/blob/master/plonetheme/barceloneta/theme/backend.xml#L35 the backend styling is not being applied due to the fact that the history view is seen as a 'public' or 'frontend' view.
Is there any way we can move to changing the default permissions on these views so the relevant body classes are automatically applied?