3 Jul
2002
3 Jul
'02
9:09 a.m.
Sylvain Thénault wrote:
I wish to know if there is another way than
self.manage_addProduct['OFSP'].manage_addNiceProduct(id)
to add a product to an object which inherits from ObjectManager ? My problem is that I would like to create the object first and add it latter to the object manager. Idea ?
If it is a Python based product you can just import the product in the normal fashion and then instanciate it. Ie. from an external script. from NiceProduct import NiceProduct id = 'niceId' niceProduct = NiceProduct(id) niceProduct.title = 'Nice Title' self.someFolder._setObject(id, theClass(niceProduct)) regards Max M