Commit 09de69a5 authored by Jean-Paul Smets's avatar Jean-Paul Smets

use of target_inventory_state_list for inventory


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@790 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d18b6c18
...@@ -33,7 +33,7 @@ from Acquisition import aq_base ...@@ -33,7 +33,7 @@ from Acquisition import aq_base
from Products.CMFCore.WorkflowCore import WorkflowAction from Products.CMFCore.WorkflowCore import WorkflowAction
from Products.ERP5Type import Permissions, PropertySheet, Constraint, Interface from Products.ERP5Type import Permissions, PropertySheet, Constraint, Interface
from Products.ERP5.ERP5Globals import current_inventory_state_list from Products.ERP5.ERP5Globals import current_inventory_state_list, target_inventory_state_list
from Products.ERP5.Document.OrderLine import OrderLine from Products.ERP5.Document.OrderLine import OrderLine
from Products.ERP5.Document.Movement import Movement from Products.ERP5.Document.Movement import Movement
from Products.ERP5.Document.SetMappedValue import SetMappedValue from Products.ERP5.Document.SetMappedValue import SetMappedValue
...@@ -311,7 +311,7 @@ Une ligne tarifaire.""" ...@@ -311,7 +311,7 @@ Une ligne tarifaire."""
""" """
Take into account efficiency in converted target quantity Take into account efficiency in converted target quantity
""" """
if self.getSimulationState() in current_inventory_state_list: if self.getSimulationState() in target_inventory_state_list:
# When an order is delivered, the target quantity should be considered # When an order is delivered, the target quantity should be considered
# rather than the quantity # rather than the quantity
return Movement.getNetConvertedTargetQuantity(self) return Movement.getNetConvertedTargetQuantity(self)
......
...@@ -35,7 +35,7 @@ from Products.ERP5Type import Permissions, PropertySheet, Constraint, Interface ...@@ -35,7 +35,7 @@ from Products.ERP5Type import Permissions, PropertySheet, Constraint, Interface
from Products.ERP5Type.XMLMatrix import XMLMatrix from Products.ERP5Type.XMLMatrix import XMLMatrix
from Products.ERP5Type.XMLObject import XMLObject from Products.ERP5Type.XMLObject import XMLObject
from Products.ERP5.ERP5Globals import current_inventory_state_list from Products.ERP5.ERP5Globals import current_inventory_state_list, target_inventory_state_list
from Products.ERP5.Document.Movement import Movement from Products.ERP5.Document.Movement import Movement
from Products.ERP5.Variated import Variated from Products.ERP5.Variated import Variated
...@@ -365,7 +365,7 @@ Une ligne tarifaire.""" ...@@ -365,7 +365,7 @@ Une ligne tarifaire."""
Take into account efficiency in converted target quantity Take into account efficiency in converted target quantity
Maybe we should only use target if isDivergent Maybe we should only use target if isDivergent
""" """
if self.getSimulationState() in current_inventory_state_list: if self.getSimulationState() in target_inventory_state_list:
# When an order is delivered, the target quantity should be considered # When an order is delivered, the target quantity should be considered
# rather than the quantity # rather than the quantity
return Movement.getNetConvertedTargetQuantity(self) return Movement.getNetConvertedTargetQuantity(self)
......
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