diff --git a/addons/account/invoice.py b/addons/account/invoice.py index 5887613940c..39e03c710ad 100644 --- a/addons/account/invoice.py +++ b/addons/account/invoice.py @@ -448,10 +448,10 @@ class account_invoice(osv.osv): ait_obj = self.pool.get('account.invoice.tax') cur_obj = self.pool.get('res.currency') acc_obj = self.pool.get('account.account') + self.button_compute(cr, uid, ids, context={}, set_total=True) for inv in self.browse(cr, uid, ids): if inv.move_id: continue - self.button_compute(cr, uid, ids, context={},set_total=True) if inv.type in ('in_invoice', 'in_refund') and abs(inv.check_total - inv.amount_total) >= (inv.currency_id.rounding/2.0): raise osv.except_osv(_('Bad total !'), _('Please verify the price of the invoice !\nThe real total does not match the computed total.')) if not inv.date_invoice: