[Zope] Kind of hotfix

Dylan Reinhardt Dylan@DylanReinhardt.com
Wed, 16 Oct 2002 11:22:29 -0700


The simplest way to override manage_options is by making it a class 
variable of the class that you're registering.  All instances of that class 
will then inherit that value for manage_options.

HTH,

Dylan

At 03:28 PM 10/16/2002 +0300, you wrote:
>Hi,
>
>I want to make a kind of Hotfix product.
>Here is what "__init__.py" (from my hotfix product folder) contains:
>
>import OFS
>import Globals
>
>OFS.ObjectManager.ObjectManager.manage_main=Globals.DTMLFile('dtml/main',globals()) 
># line 1
>OFS.ObjectManager.ObjectManager.manage_options=
>                                          # line 2
>  (
>    {'label' : 'LocalRoles','action' : 
> 'manage_main','help':('OFSP','ObjectManager_Contents.stx')},
>  )
>
>"line 1" si OK, it works, but "line 2" does not.
>
>The syntax used in "line 2" is the same as the one in 
>"OFS/ObjectManager.py" in ObjectManager - manage_options member.
>For OBS.Folder.Folder.manage_options it works, only for ObjectManager it 
>don't.
>It is very spooky, why can I overide manage_options from Folder and cannot 
>overide manage_options from ObjectManager.
>I thpought maybe the syntax is wrong, and I tried diferent syntaxes. Even 
>if I use:
>
>OFS.ObjectManager.ObjectManager.manage_options=()
>
>I cannot see any results... :(
>Very curious, don't you think...
>
>Thanks in advance,
>Rares
>
>_________________________________________________________________
>Unlimited Internet access -- and 2 months free!  Try MSN. 
>http://resourcecenter.msn.com/access/plans/2monthsfree.asp
>
>
>_______________________________________________
>Zope maillist  -  Zope@zope.org
>http://lists.zope.org/mailman/listinfo/zope
>**   No cross posts or HTML encoding!  **
>(Related lists - http://lists.zope.org/mailman/listinfo/zope-announce
>http://lists.zope.org/mailman/listinfo/zope-dev )