[Zope-CMF] Disabling Workflow

Jon Edwards jon@pcgs.freeserve.co.uk
Fri, 31 Aug 2001 14:22:25 +0100


> -----Original Message-----
> From: Ulrich Eck [mailto:ueck@net-labs.de]

> use a DC-Workflow that you configure for your needs. you could
> set the initial state to "published" so you wouldn't need to do it.
>
> another way is to use a Scriptable-Type-info, where you have
> control over the Object-creation through a script and there
> you could write
>
> context.doActionFor(ob,'publish',comment='published automatically')
>
> after the object is created and refetched from the container.

Thanks Ulrich

That would address the problem when you create a new object, but what about
when you're editing an existing object?

I don't think there's a simple answer, it harks back to the discussions
about workflow/versioning - when you edit an object, you want the original
to still be accessible (so retract won't help)

Maybe I need to make a workflow that has an "update" method that creates a
copy of the original (and locks it to prevent others editing it), which you
edit. When you've finished editing and you "re-publish", it overwrites the
original (and unlocks it again)

Maybe the screen in portal_workflow, where you define which workflow an
object uses, could be changed so that you could select "none"? ...but only
if you were really, really sure! ;-)

At the moment I use Portal Folders, with an added text property. So I guess
an easy hack would be to create a new Type from Portal Folder, add the
catalog-aware stuff, with the added textbox, and give "high-security"
permissions to its Actions

Would anyone who has made Folders catalog- and workflow-aware be willing to
post some pointers? Is it just a case of copying and pasting chunks of code
from, say, Document?

Sorry for the Friday-afternoon-rambling! :-)

Cheers, Jon