[Zope-CMF] Extending a Plone Object

David Rawle david@rawle.org.uk
Fri, 21 Feb 2003 15:32:06 -0000


Hi Raphael,

I tried creating a Product and then an ZClass called xEvent with a base
class CMF Calendar: Event. But there was no proprty sheet. Do I need to find
out what each field is called in Event and add them again? If so, what is
the 'based on' field for during ZClass create?

If I create a new object that way, how do I go about registering it in Plone
so the users can select it from the type of document to create? (How do I
link portal_types with xEvent? Is it through the forms?)

Very confused here...

Thanks,

- David

---
David Rawle
Checked for Viruses with Norton AntiVirus
Secure Crytographic Signature (S/MIME) may be attached

----- Original Message -----
From: "Raphael Ritz" <ritz@itb.biologie.hu-berlin.de>
To: "David Rawle" <david@rawle.org.uk>
Cc: <zope-cmf@zope.org>
Sent: Friday, February 21, 2003 3:09 PM
Subject: Re: [Zope-CMF] Extending a Plone Object


>
>
> David Rawle wrote:
>
> >I'm pulling my hair out here...
> >
> >I would like to create a new content type by adding a new field (summary)
to
> >the standard Event object. And then create new forms based on the
standard
> >event forms with the new field on it.
> >
> >What do I need to do? Do I have to create a whole new content type or can
I
> >just extend Event. I have tried loads of things and always seem to end up
> >getting 404 or other errors.
> >
> >I got quite excited when I found
http://plone.org/documentation/book/8/view,
> >but that example doesn't add any new properties to the object.
> >
> >Any help? Any docs out there?
> >
> Unfortunately you can't extend existing content types by simply adding a
> few more
> properties (I wish there were an easy way for this).
> You should write a product in which you define your custom content type.
> Here you might just subclass Event, add the property, and adjust its
> view/edit/edit_form.
>
> Do you know
> http://plone.org/documentation/howto/HowToWriteYourOwnContentType
>
> An alternative could be to use CMFTypes
> http://sourceforge.net/projects/collective
>
> Raphael
>
>
>
> _______________________________________________
> Zope-CMF maillist  -  Zope-CMF@zope.org
> http://mail.zope.org/mailman/listinfo/zope-cmf
>
> See http://collector.zope.org/CMF for bug reports and feature requests
>
>