I've a custom contentype. I need to override the base view of this objects only when is a anonymous user:
class Imagesblock(folder.ATFolder):
.......
def index_html(self):
""" use the parent view """
portal_state = getMultiAdapter((self, self.REQUEST), name="plone_portal_state")
if portal_state.anonymous()==True:
response = self.REQUEST.response
url = self.aq_parent.absolute_url()
return response.redirect(url, status=303)
else:
return super(Imagesblock).index_html()
I supposed to use the index_html of the super class, but I obtain an error:
AttributeError: 'super' object has no attribute 'index_html'
Any suggestions? Vito