I have a schema where for one attribute (processDef) the user should
be able to modify it only at the time he adds the object.
This is a quick hack to spare some lines of code, but it is not
working as expected. Modifying derived interface modifies the base
too.

Is that the expected behavior?
How could I solve these minor changes in a schema easily?

class IDocType(Interface):
        """DocType dok string
        """
        
        title = MyTextLine(
                title=u"DocType name",
                description=u"DocType name",
                required=True
                )
        processDef = MyChoice(
                title=u"ProcessDefinition tipus",
                description=u"ProcessDefinition tipus",
                required=True,
                vocabulary="processdef",
                readonly=False
                )

class IDocTypeEditForm(IDocType):
        """ """

IDocTypeEditForm.getDescriptionFor('processDef').readonly=True

>>>IDocType.getDescriptionFor('processDef').readonly
True
>>>IDocTypeEditForm.getDescriptionFor('processDef').readonly
True

-- 
Best regards,
 Adam                          mailto:[EMAIL PROTECTED]
--
Quote of the day:
The fear of God kills all other fears. 
- Hugh Black 

_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to