From 0832bfd7b87cdffeac15db9551cec3c3d53865a6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Beno=C3=AEt=20Pin?= Date: Tue, 26 Oct 2010 16:20:06 +0200 Subject: [PATCH] =?utf8?q?R=C3=A9solu=C2=A0:=20probl=C3=A8me=20de=20locali?= =?utf8?q?sation=20avec=20zope-2.12.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- utils.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/utils.py b/utils.py index 26ed830..56ceb30 100755 --- a/utils.py +++ b/utils.py @@ -12,7 +12,7 @@ """ from AccessControl import ModuleSecurityInfo -#from Products.PageTemplates.GlobalTranslationService import getGlobalTranslationService +from zope.i18n import translate as i18ntranslate from zope.i18nmessageid import MessageFactory security = ModuleSecurityInfo('Products.Portfolio.utils') @@ -31,5 +31,4 @@ def translate(message, context): message = message[0] except (TypeError, IndexError): pass - return message - return GTS.translate('portfolio', message, context=context) + return i18ntranslate(message, domain='photoprint', context=context.REQUEST) -- 2.20.1