From 0bbdea3ac045c54022a0c37629c3398bc88c5486 Mon Sep 17 00:00:00 2001 From: Nicolas Delaby <nicolas@nexedi.com> Date: Mon, 15 Feb 2010 17:02:19 +0000 Subject: [PATCH] This patch is related to http://svn.erp5.org?rev=30412&view=rev __name__ should be define on Accessor in order to be able to wrap PreferenceMethod with UnrestrictedMethod. Rewied by Romain git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32563 20353a03-c40f-0410-a6d1-a30d3c3de9de --- product/ERP5Form/PreferenceTool.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/product/ERP5Form/PreferenceTool.py b/product/ERP5Form/PreferenceTool.py index 8f0643fe6a..46f76b56ef 100644 --- a/product/ERP5Form/PreferenceTool.py +++ b/product/ERP5Form/PreferenceTool.py @@ -1,3 +1,4 @@ +# -*- coding: utf-8 -*- ############################################################################## # # Copyright (c) 2005 Nexedi SARL and Contributors. All Rights Reserved. @@ -110,7 +111,7 @@ class PreferenceMethod(Method): func_defaults = () def __init__(self, attribute, default): - self._preference_getter = attribute + self.__name__ = self._preference_getter = attribute self._preference_default = default self._preference_cache_id = 'PreferenceTool.CachingMethod.%s' % attribute -- 2.30.9