[Erp5-report] r7148 - /erp5/trunk/products/ERP5Type/Accessor/List.py

nobody at svn.erp5.org nobody at svn.erp5.org
Wed May 10 14:33:25 CEST 2006


Author: jerome
Date: Wed May 10 14:33:20 2006
New Revision: 7148

URL: http://svn.erp5.org?rev=7148&view=rev
Log:
Import evaluateTales from Base instead of copy/paste

Modified:
    erp5/trunk/products/ERP5Type/Accessor/List.py

Modified: erp5/trunk/products/ERP5Type/Accessor/List.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/Accessor/List.py?rev=7148&r1=7147&r2=7148&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/Accessor/List.py (original)
+++ erp5/trunk/products/ERP5Type/Accessor/List.py Wed May 10 14:33:20 2006
@@ -26,13 +26,10 @@
 #
 ##############################################################################
 
-from Base import func_code, type_definition, list_types, ATTRIBUTE_PREFIX, Method
+from Base import func_code, type_definition, list_types,\
+                 ATTRIBUTE_PREFIX, Method, evaluateTales
 from TypeDefinition import asList, identity
 import Base
-
-from Products.CMFCore.Expression import Expression
-from Products.ERP5Type.Utils import createExpressionContext
-from Products.ERP5Type.Cache import CachingMethod
 from Products.ERP5Type.PsycoWrapper import psyco
 
 from zLOG import LOG
@@ -206,14 +203,6 @@
         method(*args, **kw)
       if self._reindex: instance.reindexObject()
 
-
-def _evaluateTales(instance=None, value=None):
-  expression = Expression(value)
-  econtext = createExpressionContext(instance)
-  return expression(econtext)
-
-evaluateTales = CachingMethod(_evaluateTales, id = 'evaluateTales', cache_duration=300)
-
 class DefaultGetter(Method):
     """
       Gets the first item of a list




More information about the Erp5-report mailing list