[Erp5-report] r32584 kazuhiko - /erp5/trunk/products/ERP5/Document/PaymentRule.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Tue Feb 16 09:52:57 CET 2010
Author: kazuhiko
Date: Tue Feb 16 09:52:53 2010
New Revision: 32584
URL: http://svn.erp5.org?rev=32584&view=rev
Log:
if calculated date is None, do not use it.
Modified:
erp5/trunk/products/ERP5/Document/PaymentRule.py
Modified: erp5/trunk/products/ERP5/Document/PaymentRule.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/PaymentRule.py?rev=32584&r1=32583&r2=32584&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/PaymentRule.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/PaymentRule.py [utf8] Tue Feb 16 09:52:53 2010
@@ -71,8 +71,12 @@
# Since we need to consider business_path only for bank movement,
# not for payable movement, we pass None as business_path here.
kw = self._getExpandablePropertyDict(applied_rule, input_movement, None)
- kw['start_date'] = business_path.getExpectedStartDate(input_movement)
- kw['stop_date'] = business_path.getExpectedStopDate(input_movement)
+ start_date = business_path.getExpectedStartDate(input_movement)
+ if start_date is not None:
+ kw['start_date'] = start_date
+ stop_date = business_path.getExpectedStopDate(input_movement)
+ if stop_date is not None:
+ kw['stop_date'] = stop_date
quantity = business_path.getExpectedQuantity(input_movement)
# one for payable
More information about the Erp5-report
mailing list