• Arnaud Fontaine's avatar
    Portal Type as Classes: ERP5Form: Instances of Documents should never be created directly. · e791d08a
    Arnaud Fontaine authored
    This has been banned since the introduction of Portal Type class. When creating
    a new ERP5Form via addERP5Form/ZMI, its MRO:
      * Before:
        <class 'Products.ERP5Form.Form.ERP5Form'>
        <class 'Products.ERP5Type.Base.Base'>
        ...
        <type 'ExtensionClass.Base'>
      * Now:
        <class 'erp5.portal_type.ERP5 Form'>,
        <class 'Products.ERP5Form.Form.ERP5Form'>,
        <class 'Products.ERP5Type.Base.Base'>,
        ...
        <class 'erp5.accessor_holder.property_sheet.SimpleItem'>
        <class 'erp5.accessor_holder.property_sheet.Folder'>
        <class 'erp5.accessor_holder.property_sheet.Base'>
        <class 'erp5.accessor_holder.property_sheet.CategoryCore'>
        <class 'erp5.accessor_holder.BaseAccessorHolder'>
        <class 'Products.ERP5Type.dynamic.portal_type_class.GetAcquireLocalRolesMixIn'>
        <type 'ExtensionClass.Base'>
    
    Thus it was missing many accessors and was working only by chance (or at least
    unless these accessors were...
    e791d08a
testListBox.py 30.4 KB