[Zope-CMF] adding custom products programmatically

Kaimar Karu Kaimar.Karu@artaxis.ee
Sun, 14 Jul 2002 16:54:41 +0300


Hi,

I created a new Product, "GalahadFile" and in it I created several Z 
Classes, GalahadImageFile for example. Now if i want to use pythin 
script to add a GalahadImageFile programmatically - what should I do?

I add Image files this way:
context.galahad.file_storage[str(org_id)].manage_addImage(str(new_id), 
file=new_contents, title=new_title)

and I want to add GalahadImageFiles this way:
context.galahad.file_storage[str(org_id)].manage_addGalahadImageFile(str(new_id), 
file=new_contents, title=new_title)

What should I do for this? What methods should I add and where?

TIA,
Kaimar