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

Richard Ettema richard.ettema@yoursolutions.com
Tue, 11 Mar 2003 15:06:04 -0000


Hi,

I have a python script that is called by another site to confirm the
completion of a task.
This python script has a proxy role of 'Reviewer' and calls the
context.workflow.doActionFor(obj, 'publish') to change the status of an item
(obj) from pending to published.

How do I protect the transition so it can only be called by a reviewer, or
this python script acting as a reviewer?

If I do a test in the expression field for the current user having the role
of 'Reviewer' it fails. How do I test for the script having the proxy role I
have given it?

Or am I looking at this in completely the wrong way?

Thanks for your help
Richard
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.456 / Virus Database: 256 - Release Date: 18/02/2003