Commit f71d9b83 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

fix bugs in select methods to support both legacy and new simulation hierarchy.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32670 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 29411769
......@@ -60,7 +60,8 @@
parent_applied_rule = movement.getParentValue()\n
parent_rule = parent_applied_rule.getSpecialiseValue()\n
return (\n
root_rule.getPortalType() == "Production Order Rule" and\\\n
root_rule.getPortalType() in ("Production Order Rule",\n
"Production Order Simulation Rule") and\\\n
parent_rule.getPortalType() == "Transformation Rule" and\\\n
root_movement.getSimulationState() == "confirmed"\n
)\n
......
......@@ -60,18 +60,18 @@
parent_applied_rule = movement.getParentValue()\n
parent_rule = parent_applied_rule.getSpecialiseValue()\n
return (\n
((root_rule.getPortalType() == "Production Order Rule" and\\\n
(parent_rule.getPortalType() in ("Transformation Sourcing Rule",))) or \\\n
(root_rule.getPortalType() == "Production Order Simulation Rule" and\\\n
(parent_rule.getPortalType() in ("Delivering Simulation Rule",))))\\\n
and\\\n
root_rule.getPortalType() in ("Production Order Rule",\n
"Production Order Simulation Rule") and\\\n
(parent_rule.getPortalType() in ("Transformation Sourcing Rule",\n
"Delivering Rule",\n
"Delivering Simulation Rule")) and\\\n
root_movement.getSimulationState() == "confirmed"\n
)\n
\n
# XXX need to implement this part in the catalog\n
# portal type causality of root applied rule\n
search_kw = {\n
\'explanation_portal_type\': (\'Production Order\', \'Production Simulation Order\'),\n
\'explanation_portal_type\': \'Production Order\',\n
\'portal_type\': \'Simulation Movement\',\n
}\n
if explanation_uid is not None:\n
......
418
\ No newline at end of file
419
\ No newline at end of file
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