From: Jock C. <joc...@jc...> - 2006-03-14 16:34:34
|
Though I've been playing with Plone and Zope for, wow, a couple of years now I have not so far got down to too much mucking around in code. But now I want to create a customised member type with lots of additional data to collect (it's for an alumni site so I want eventually to capture data about when they left the school and so on). So, I followed this: http://plone.org/products/archetypes/documentation/old/wiki/ SubclassCMFMember/ ...to see if I could get such a basic customisation going. After some fiddling (mostly because of typos in the code) I finally got the new type, AlumniMember to show up in the quickinstaller and to install with no apparent errors. However, when I then create a Plone site, install CMFMember and AlumniMember, migrate to CMFMember, I would then expect to see "AlumniMember" available in the available member type field. But it doesn't seem to appear. If I install Samplex, the SamplexMember type shows up and allows me to set it as default, but not my one. Nor is there any entry for my type in the archetypes_tool. So I'm thinking I have failed to register the type properly. But it's not entirely clear from the LiMi document cited above where i am supposed to do that. Further to all this, I wanted to use the basic subclass idea as a basis on which I could then use ATSchemaEditor to give it some more fields. If I set the USE_SCHEMA_EDITOR = True line in the config.py of CMFMember it seems to throw errors during the migration about not finding the Schema - something I've seen mentioned in other posts on this list but not quite understanding how to rectify it. Do I need to turn USE_SCHEMA_EDITOR on for CMFMember, or somewhere for my subclass only? It is, after all, only my Subclass I actually want to edit! Any thoughts would be welcome. Can provide code. And am using Zope 2.8.4-final, python 2.3.5, linux2 Plone 2.1.1 on CMF 1.5.4, Archetypes 1.3.5 final, CMFMember 1.1beta2, and ATSchemaEditorNG 0.3.2 Cheers, Jock Coats -- Jock Coats Warden's Flat 1e, J Block Morrell Hall, OXFORD, OX3 0FF w: +44 (0)1865 483353 h: +44 (0)1865 485019 m: +44 (0)7769 695767 e: joc...@jc... www: http://jockcoats.blogspot.com/ |