Commit 8b5c173c authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

fix bug of supporting new simulation hierarchy.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32532 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ce2c2513
...@@ -72,12 +72,14 @@ root_movement = movement.getRootSimulationMovement()\n ...@@ -72,12 +72,14 @@ root_movement = movement.getRootSimulationMovement()\n
\n \n
# Test movement\n # Test movement\n
if (root_rule is None or\n if (root_rule is None or\n
root_rule.getPortalType() != "Production Order Rule" or\n root_rule.getPortalType() not in ("Production Order Rule", "Production Order Simulation Rule") or\n
order is None or\n order is None or\n
movement.getResourceValue() is None or\n movement.getResourceValue() is None or\n
movement.getSourceValue() is None or\n movement.getSourceValue() is None or\n
movement.getResourceValue() != root_movement.getResourceValue() or\n movement.getResourceValue() != root_movement.getResourceValue()):\n
movement.getPath() == root_movement.getPath()):\n return False\n
if root_rule.getPortalType() in ("Production Order Simulation Rule",) and\\\n
movement.getPath() == root_movement.getPath():\n
return False\n return False\n
\n \n
supply_chain = rule.getSupplyChain(movement.getParentValue())\n supply_chain = rule.getSupplyChain(movement.getParentValue())\n
......
...@@ -60,9 +60,11 @@ ...@@ -60,9 +60,11 @@
parent_applied_rule = movement.getParentValue()\n parent_applied_rule = movement.getParentValue()\n
parent_rule = parent_applied_rule.getSpecialiseValue()\n parent_rule = parent_applied_rule.getSpecialiseValue()\n
return (\n return (\n
root_rule.getPortalType() == "Production Order Rule" and\\\n ((root_rule.getPortalType() == "Production Order Rule" and\\\n
(parent_rule.getPortalType() in ("Transformation Sourcing Rule",\n (parent_rule.getPortalType() in ("Transformation Sourcing Rule",))) or \\\n
"Delivering Rule")) and\\\n (root_rule.getPortalType() == "Production Order Simulation Rule" and\\\n
(parent_rule.getPortalType() in ("Delivering Simulation Rule",))))\\\n
and\\\n
root_movement.getSimulationState() == "confirmed"\n root_movement.getSimulationState() == "confirmed"\n
)\n )\n
\n \n
......
416 417
\ No newline at end of file \ 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