[Erp5-report] r42858 nicolas.dumazet - /erp5/trunk/products/ERP5/Interactor/

nobody at svn.erp5.org nobody at svn.erp5.org
Tue Feb 1 03:37:47 CET 2011


Author: nicolas.dumazet
Date: Tue Feb  1 03:37:47 2011
New Revision: 42858

URL: http://svn.erp5.org?rev=42858&view=rev
Log:
use resetDynamicDocumentsOnceAtTransactionBoundary instead

Modified:
    erp5/trunk/products/ERP5/Interactor/PortalTypeClassInteractor.py

Modified: erp5/trunk/products/ERP5/Interactor/PortalTypeClassInteractor.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Interactor/PortalTypeClassInteractor.py?rev=42858&r1=42857&r2=42858&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Interactor/PortalTypeClassInteractor.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Interactor/PortalTypeClassInteractor.py [utf8] Tue Feb  1 03:37:47 2011
@@ -28,8 +28,6 @@
 ##############################################################################
 
 from Products.ERP5Type.Interactor.Interactor import Interactor
-import transaction
-from Products.ERP5Type.TransactionalVariable import getTransactionalVariable
 
 class PortalTypeClassInteractor(Interactor):
   """
@@ -63,11 +61,4 @@ class PortalTypeClassInteractor(Interact
     types_tool = getattr(portal, 'portal_types', None)
     if types_tool is None:
       return
-
-    # XXX this could be a generic doOnceAtEndOfTransaction in
-    # Interactor baseclass
-    tv = getTransactionalVariable()
-    key = 'Interactor.PortalTypeClassInteractor.resetDynamic'
-    if key not in tv:
-      tv[key] = None
-      transaction.get().addBeforeCommitHook(types_tool.resetDynamicDocuments)
+    types_tool.resetDynamicDocumentsOnceAtTransactionBoundary()



More information about the Erp5-report mailing list