[Zope] recursive zclass product

Anthony Baxter Anthony Baxter <anthony@interlink.com.au>
Fri, 03 Dec 1999 12:16:24 +1100


>>> Sam Gendler wrote
[aside: please keep your email to less that 80 columns - it makes it
easier to reply to... ta]
> Actually, let me add one more level of complexity.  I have a CPI product,
> which doesn't need to be recursive.  It contains a CPISection ZClass,
> which contains CPIPage ZClass.  However, I want CPISection to be able to
> contain CPISections, CPIPages, and lots of other standard zope objects.
> I understand the whole Object manager thing, but in my first subclass
> (CPISection), when I go to the subobjects tab, it only shows me things
> in the Products menu (CPI, but no CPISection).

I've done something like this here. (in fact, almost _exactly_ like this :)

I had to structure it so that the three ZClasses were all in the top
level of their Product directory. 

So I have Control Panel / Products / FooProduct /
                                                  FooClass
						  FooMenu
						  FooMenuItem

Or you could write your own mgmt page that pulled the classes out of
the parent class's (see the 'Adding ZClasses Programatically' How-To
for some hints on this).

Anthony