[Zope] PropertySheets again (QUEST)

Tres Seaver tseaver@palladion.com
Mon, 27 Mar 2000 09:14:30 -0600


Oscar Picasso wrote:
> 
> > > As I didn't receive any answer from my previous message, I guess it wasn't
> > > very clear.
> > >
> > > How can I get a list of property.ids, property.types of a ZClass
> > > propertysheet from outside the product containing my ZClass.
> >
> > Look at how Zope's management interface does it
> > ($ZOPE_HOME/lib/python/OFS/properties.dtml).
> 
> Thanks for your input.However I'm not sure that i really understand it. I
> guessed that in that method the key element is popertyMap. So I tried:
> <dtml-var propertyMap> in my zclass_addForm.

To use the propertysheet before you have an instance, you need to get the
Product into the namespace stack, something like this (untested, but I do stuff
like this elsewhere)::

  <dtml-with "manage_addProduct[ 'MyZClassProduct' ]">
   <dtml-in "MyZClass.propertysheets.info.propertyMap()">
    ....
   </dtml-in>
  </dtml-with>

-- 
=========================================================
Tres Seaver         tseaver@palladion.com    713-523-6582
        Now also:   tseaver@digicool.com
Palladion Software  http://www.palladion.com