[Zope] Creating nested ZClass programmatically
Nick Gaunt
gauntn@eurobell.co.uk
Wed, 2 Jan 2002 11:33:37 +0000
Hi
First of all, Happy New Year to you all!
I am trying to grok ZClasses. I have created a set of classes as follows:
StudySite
|
Study
|
StudyArm
|
SubjectFolder
|
Subject
I can create instances of each nested class successfully through the
management interface. Now I want users to be able to add instances via a
standard user interface, but I cannot work out how to do so. I have users
navigate to the desired Study, click an "Add Subject" button that opens a
form to collect subject details, click "Add" to open a DTMLMethod, and then I
come unstuck - whatever dtml-call syntax I try returns "global name
'StudySite' is not defined". I assume I am not accessing the ZClass
namespace, but what is the syntax?
Would I be better using a python script? If so, what syntax should I use?
Would it have been easier had I created all the classes at the base level of
the ZClass?
Thanks for your help!
Nick