[Zope] Create objects of MyClass
Chris Withers
lists at simplistix.co.uk
Wed Mar 17 04:02:02 EST 2004
Serg wrote:
> How can I determine 'My Product Name'? My class named 'MyClass'. It be
> located in dir ../Python/Products/MyProject/.
Generally it'll be "MyProject" then, if you want to implement something like the
Add menu in the ZMI, look at /lib/python/OFS/dtml/mail.dtml for the bit with the
comment <!-- Add object widget -->. filtered_meta_types is your friend.
> If I try use below
> context.manage_addProduct['MyClass'].manage_addMyClass(id,None)
>
> Zope write:
> "An error was encountered while publishing this resource.
> Error Type: AttributeError
> Error Value: MyClass"
Try:
context.manage_addProduct['MyProject'].manage_addMyClass(id,None)
cheers,
Chris
--
Simplistix - Content Management, Zope & Python Consulting
- http://www.simplistix.co.uk
More information about the Zope
mailing list