[Erp5-report] r31974 jerome - /erp5/trunk/products/ERP5/Document/Resource.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Tue Jan 26 14:13:19 CET 2010
Author: jerome
Date: Tue Jan 26 14:13:18 2010
New Revision: 31974
URL: http://svn.erp5.org?rev=31974&view=rev
Log:
ratio defined on quantity unit must be returned to keep compatibility with
quantities defined on quantity unit
Modified:
erp5/trunk/products/ERP5/Document/Resource.py
Modified: erp5/trunk/products/ERP5/Document/Resource.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/Resource.py?rev=31974&r1=31973&r2=31974&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/Resource.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/Resource.py [utf8] Tue Jan 26 14:13:18 2010
@@ -989,15 +989,13 @@
portal = self.getPortalObject()
quantity_unit_uid = quantity_unit_value.getUid()
- ratio = None
-
deprecated_quantity = quantity_unit_value.getProperty('quantity')
if deprecated_quantity is not None:
warn('quantity field of quantity_unit categories is deprecated.' \
' Please use Quantity Unit Conversion Definitions instead and' \
' reset the value of this field.', DeprecationWarning)
- ratio = float(deprecated_quantity)
+ return float(deprecated_quantity)
query = self.ResourceModule_zGetQuantityUnitDefinitionRatio(
quantity_unit_uid=quantity_unit_uid,
More information about the Erp5-report
mailing list