From afdee99f4b696877efd288e14837edc48a773335 Mon Sep 17 00:00:00 2001 From: nicomacr Date: Fri, 24 Nov 2017 13:32:37 -0300 Subject: [PATCH] 9.0-del-purchase usability _onchange_journal_id --- purchase_usability/models/account_invoice.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/purchase_usability/models/account_invoice.py b/purchase_usability/models/account_invoice.py index 1961e0f..33c1eb6 100644 --- a/purchase_usability/models/account_invoice.py +++ b/purchase_usability/models/account_invoice.py @@ -28,13 +28,3 @@ def add_purchase_line_moves(self): ('company_id', '=', self.company_id.id), ] return action_read - - # We do this for a bug when creating an invoice from - # the PO that does not get the correct currency from the PO, by default - # bring the currency of the newspaper. - @api.onchange('journal_id') - def _onchange_journal_id(self): - if self._context.get('default_currency_id', False): - self.currency_id = self._context.get('default_currency_id') - else: - super(AccountInvoice, self)._onchange_journal_id()