Use default values when adding a record via on_change
review321002 (transplanted from 5aed7d67f16d93bbaec69b8dd4ca3ca14b94ff6e)
This commit is contained in:
1 parent
fd2a56d4f6
commit
6c36d5a37b
1 file changed
+3
-1
+3
-1
@@ -459,7 +459,9 @@ class Invoice(ModelWorkflow, ModelSQL, ModelView):
|
||||
if key not in tax_keys:
|
||||
res['tax_amount'] += computed_taxes[key]['amount']
|
||||
res['taxes'].setdefault('add', [])
|
||||
res['taxes']['add'].append(computed_taxes[key])
|
||||
value = tax_obj.default_get(tax_obj._columns.keys())
|
||||
value.update(computed_taxes[key])
|
||||
res['taxes']['add'].append(value)
|
||||
if currency:
|
||||
res['untaxed_amount'] = currency_obj.round(currency,
|
||||
res['untaxed_amount'])
|
||||
|
||||
Reference in new issue
Block a user