[Zope-CMF] Checking for a proxy role by a workflow transition guard expression

Chris Withers chrisw@nipltd.com
Mon, 17 Mar 2003 08:55:37 +0000


Richard Ettema wrote:
> 
> python:
> here.portal_membership.getAuthenticatedMember().has_permission('Review
> portal content', here)
> 
> python: here.portal_membership.getAuthenticatedMember().has_role('Reviewer',
> here)
> 
> python: user.has_role('Reviewer')

I suspect there's another method of the user object that will do what you want. 
Have a look in lib/python/OFS/User.py...

cheers,

Chris