Commit e78ac944 authored by Arnaud Fontaine's avatar Arnaud Fontaine

WIP: Products.DCWorkflow removal.

parent 1699b058
......@@ -92,8 +92,6 @@ from Products.DCWorkflow.utils import Message as _
from Products.ERP5Type import Permissions
from Products.ERP5Type.Cache import CachingMethod
from Products.ERP5Type.Globals import PersistentMapping, InitializeClass
from Products.ERP5Type.patches.WorkflowTool import (SECURITY_PARAMETER_ID,
WORKLIST_METADATA_KEY)
from Products.ERP5Type.Utils import convertToMixedCase
from Products.ERP5Type.XMLObject import XMLObject
from Products.ERP5Type.Core.WorkflowTransition import (TRIGGER_AUTOMATIC,
......@@ -510,6 +508,8 @@ class Workflow(XMLObject):
security_manager = getSecurityManager()
workflow_id = self.getId()
workflow_title = self.getTitle()
from Products.ERP5Type.Tool.WorkflowTool import (SECURITY_PARAMETER_ID,
WORKLIST_METADATA_KEY)
for worklist_definition in worklist_value_list:
action_box_name = worklist_definition.getActionName()
guard_role_list = worklist_definition.getGuardRoleList()
......
......@@ -41,7 +41,6 @@ if WITH_LEGACY_WORKFLOW:
from Products.ERP5Type.patches import BTreeFolder2
if WITH_LEGACY_WORKFLOW:
from Products.ERP5Type.patches import WorkflowTool
from Products.ERP5Type.patches import WorkflowTool
from Products.ERP5Type.patches import DynamicType
from Products.ERP5Type.patches import XMLExportImport
from Products.ERP5Type.patches import ppml
......@@ -73,7 +72,8 @@ if six.PY2:
# No more ZServer
from Products.ERP5Type.patches import http_server
from Products.ERP5Type.patches import memcache_client
from Products.ERP5Type.patches import StateChangeInfoPatch
if WITH_LEGACY_WORKFLOW:
from Products.ERP5Type.patches import StateChangeInfoPatch
from Products.ERP5Type.patches import transforms
from Products.ERP5Type.patches import OFSPdata
from Products.ERP5Type.patches import make_hidden_input
......
......@@ -13,7 +13,8 @@
#
##############################################################################
# WITH_LEGACY_WORKFLOW
from Products.ERP5Type import WITH_LEGACY_WORKFLOW
assert WITH_LEGACY_WORKFLOW
## ERP5 Workflow: This must go before any Products.DCWorkflow imports as this
## patch createExprContext() from-imported in several of its modules
......
......@@ -26,6 +26,9 @@
#
##############################################################################
from Products.ERP5Type import WITH_LEGACY_WORKFLOW
assert WITH_LEGACY_WORKFLOW
from Products.DCWorkflow.Expression import StateChangeInfo
from Products.PythonScripts.Utility import allow_class
allow_class(StateChangeInfo)
......
......@@ -12,6 +12,9 @@
#
##############################################################################
from Products.ERP5Type import WITH_LEGACY_WORKFLOW
assert WITH_LEGACY_WORKFLOW
# State types patch for DCWorkflow
from builtins import str
from builtins import map
......
......@@ -13,6 +13,9 @@
#
##############################################################################
from Products.ERP5Type import WITH_LEGACY_WORKFLOW
assert WITH_LEGACY_WORKFLOW
from zLOG import LOG, WARNING
# Make sure Interaction Workflows are called even if method not wrapped
......@@ -22,8 +25,6 @@ from Products.ERP5Type.Globals import InitializeClass
from Products.CMFCore.WorkflowTool import WorkflowTool
from Products.CMFCore.WorkflowCore import ObjectDeleted
from Products.CMFCore.WorkflowCore import WorkflowException
from Products.DCWorkflow.DCWorkflow import DCWorkflowDefinition
from Products.DCWorkflow.Transitions import TRIGGER_WORKFLOW_METHOD
from Products.DCWorkflow.utils import Message as _
from Products.DCWorkflow.Transitions import TRIGGER_USER_ACTION
......
from Products.ERP5Type import WITH_LEGACY_WORKFLOW
assert WITH_LEGACY_WORKFLOW
from Products.DCWorkflow.Worklists import Worklists
from Products.DCWorkflow.Worklists import WorklistDefinition
from Products.ERP5Type.Permissions import ManagePortal
......
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