How to access rev_history for anonymous users

I am having problems accessing the review_history function using the getInfoFor method, sample code below:

 <div tal:define = "review_history python:wtool.getInfoFor(here, 'review_history', []); review_history python: portal.reverseList(review_history)" tal:repeat="items review_history"> <span tal:content="python: review_history" /> </div> 

When I log in, I see the contents of rev_history var, but when I view it as an unregistered user, all I see is an empty list. Has anyone ever come across this, and is there a way to change it so that it is accessible to everyone?

+4
source share
1 answer

What you want to do is either set up a workflow or, even better, create your own workflow. In this workflow, you can manage permissions on your content and add anonymous users to view the history of objects. (Remember to apply the new workflow to the types of content for which you want to make the story available to anonymous users.)

Take a look at Plone Workflow Creation or Permission and Security Overview at plone.org. These pages should make you go in the right direction.

+3
source

Source: https://habr.com/ru/post/1301443/


All Articles