[Zope-CMF] Point of publication
Thu, 18 Apr 2002 18:16:01 -0400
Thanks, Dieter. I'm going to play around with this example this evening and
see if I can get things working. As always, you're help is greatly
From: Dieter Maurer [mailto:email@example.com]
Sent: Thursday, April 18, 2002 3:46 PM
To: Kevin Carlson
Subject: RE: [Zope-CMF] Point of publication
Kevin Carlson writes:
> Reviving an old thread...
> I have been able to modify the DefaultWorkflow.py source to accomplish
> moving an object to a different folder on publication. Now that I am
> finally getting around to attempting to do this with a script, I am
> some trouble. Any sample source available?
I use the following External Method to move an object to a "DataCenter".
Center= getCenter(p,obj); t= getType(obj)
# remove the object from its original place - this should uncatalog
# now install
# finally, tell the workflow that we moved the object
raise stateChange.ObjectMoved(n,_redirect(n,t + ' freigegeben und ins
The DataCenter has a special method "addObject" that adds an object,
giving it a new automatically generated id.
You can use the "ObjectManager._setObject" method, when the
destination is a standard "ObjectManager".