[FIX] account: allow to use quantity in taxes computated with python code
This commit is contained in:
parent
817ce8f912
commit
3540484138
|
@ -2022,7 +2022,7 @@ class account_tax(osv.osv):
|
|||
data['tax_amount']=quantity
|
||||
# data['amount'] = quantity
|
||||
elif tax.type=='code':
|
||||
localdict = {'price_unit':cur_price_unit, 'product':product, 'partner':partner}
|
||||
localdict = {'price_unit':cur_price_unit, 'product':product, 'partner':partner, 'quantity': quantity}
|
||||
exec tax.python_compute in localdict
|
||||
amount = localdict['result']
|
||||
data['amount'] = amount
|
||||
|
|
Loading…
Reference in New Issue