[Zope] setting Zclass instance id based on properties

Dieter Maurer dieter at handshake.de
Tue Dec 2 13:44:15 EST 2003


Charlie Kalech wrote at 2003-12-2 17:18 +0300:
 > I would like to set the id of a Zclass instance based on some of the properties
 > 
 > I can not use the property variables in the add method since the 
 > properties have not yet been assigned a value
 > 
 > For instance let's say I have three properties: Section, Chapter and Page
 > 
 > How do I assign the id the value <dtml-var Section>-<dtml-var 
 > Chapter>-<dtml-var Page> when I create the zclass instance?

When you have created your ZClass, two constructors have been (usually)
created: a form and its action.

The action is a PythonScript in modern Zope versions -- quite
easy to customize.

When you have special needs you customize these two constructors...

-- 
Dieter



More information about the Zope mailing list