Commit 6f5bf62b authored by Nicolas Dumazet's avatar Nicolas Dumazet

use resetDynamicDocumentsOnceAtTransactionBoundary instead


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@42858 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b6f629d0
...@@ -28,8 +28,6 @@ ...@@ -28,8 +28,6 @@
############################################################################## ##############################################################################
from Products.ERP5Type.Interactor.Interactor import Interactor from Products.ERP5Type.Interactor.Interactor import Interactor
import transaction
from Products.ERP5Type.TransactionalVariable import getTransactionalVariable
class PortalTypeClassInteractor(Interactor): class PortalTypeClassInteractor(Interactor):
""" """
...@@ -63,11 +61,4 @@ class PortalTypeClassInteractor(Interactor): ...@@ -63,11 +61,4 @@ class PortalTypeClassInteractor(Interactor):
types_tool = getattr(portal, 'portal_types', None) types_tool = getattr(portal, 'portal_types', None)
if types_tool is None: if types_tool is None:
return return
types_tool.resetDynamicDocumentsOnceAtTransactionBoundary()
# 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)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment