[Zope-CMF] Re: [dev] enhancing Actions: a rough proposal

yuppie y.2004_ at wcm-solutions.de
Wed Nov 24 10:05:28 EST 2004


Florent Guillaume wrote:
>>Actions and transactions don't have to be unrelated if they are stored 
>>in different places. The ActionsTool could query the available workflow 
>>transitions and return the corresponding Actions. This way we don't 
>>have to define redundant permissions / guards / expressions.
> 
> 
> Another way would be to have workflow actions defined with the other
> actions, but use a special tales expression like:
>   python: context.portal_workflow.wf_foo.publish.isGuardAllowedFor(object)
> or add a new function to the namespace so that we can shorten that to
>   python: workflow(object, 'publish', 'wf_foo')
> the last argument being optional if the object belongs to only one workflow.
> 
> Just throwing ideas around...

I like this idea because it allows to use the 'condition' field the same 
way as in other Actions. You can look at this Action and see what 
controls its availability.

But I'm concerned that this is a) to expensive and b) requires adding 
very similar expressions to each Action.

Cheers, Yuppie



More information about the Zope-CMF mailing list