Commit 467b8168 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_simulation: keep one sm in order to be able to generate divergence

parent d196306f
...@@ -85,8 +85,11 @@ class QuantityDeliverySolver(XMLObject): ...@@ -85,8 +85,11 @@ class QuantityDeliverySolver(XMLObject):
for movement in simulation_movement_list: for movement in simulation_movement_list:
movement.edit(delivery_ratio=movement.getQuantity() / new_quantity, activate_kw=activate_kw) movement.edit(delivery_ratio=movement.getQuantity() / new_quantity, activate_kw=activate_kw)
else: else:
# zero quantity
movement = simulation_movement_list.pop()
movement.edit(delivery_ratio=1, quantity=0, activate_kw=activate_kw)
for movement in simulation_movement_list: for movement in simulation_movement_list:
movement.edit(delivery_ratio=0, activate_kw=activate_kw) movement.edit(delivery_ratio=0, quantity=0, activate_kw=activate_kw)
return result return result
......
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