Commit 00b0a169 authored by Julien Muchembled's avatar Julien Muchembled

TradeModelLine: fix r36902 to ignore quantity only if it is not specified

(default value for quantity is 0)

git-svn-id: https://svn.erp5.org/repos/public/erp5/sandbox/amount_generator@37402 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f70b5541
......@@ -83,7 +83,8 @@ class TradeModelLine(MappedValue, XMLMatrix, Amount, AmountGeneratorMixin):
result = self._baseGetMappedValuePropertyList()
if result:
return result
if self._baseGetQuantity() is not None: # If quantity is defined, then tax works as transformed resource
# If quantity is defined, then tax works as transformed resource
if self._baseGetQuantity(None) is not None:
return ('quantity', 'price', 'step')
# Else tax provides only a ratio on amount
return ('price', 'efficiency')
......
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