[Erp5-report] r28937 - /erp5/trunk/products/ERP5/Document/
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Sep 11 13:01:15 CEST 2009
Author: jerome
Date: Fri Sep 11 13:01:14 2009
New Revision: 28937
URL: http://svn.erp5.org?rev=28937&view=rev
Log:
Supports using this movement group on movements that comes from invoice rule. In that case we cannot use same assumption to go up in simulation tree and find a delivery
Modified:
erp5/trunk/products/ERP5/Document/DeliveryCausalityAssignmentMovementGroup.py
Modified: erp5/trunk/products/ERP5/Document/DeliveryCausalityAssignmentMovementGroup.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/DeliveryCausalityAssignmentMovementGroup.py?rev=28937&r1=28936&r2=28937&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/DeliveryCausalityAssignmentMovementGroup.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/DeliveryCausalityAssignmentMovementGroup.py [utf8] Fri Sep 11 13:01:14 2009
@@ -39,6 +39,11 @@
def _addCausalityToEdit(self, movement, property_dict=None):
if property_dict is None:
property_dict = {}
+ if movement.getParentValue().isRootAppliedRule():
+ # Here movement probably comes from invoice rule, in that situation, we
+ # are not able to go up and find a delivery.
+ return property_dict
+
parent = movement.getParentValue().getParentValue()
# Go upper into the simulation tree in order to find a delivery link
while parent.getDeliveryValue() is None and not(parent.isRootAppliedRule()):
More information about the Erp5-report
mailing list