**Impacted versions:**
* 9.0

**Steps to reproduce:**
* Enable multi currencies
* Make sure that the current rate of a foreign currency (i.e. EUR) is not 1.0 (i.e. 0.84)
* Create a purchasable product with a cost (i.e. 33$)
* Create a vendor bill in a foreign currency (i.e. EUR)
* Add the product on the invoice

**Current behavior:**
* The unit price will be 23.28 == (33 * 0.84) * 0.84

**Expected behavior:**
* The unit price should be 27,72 == 33 * 0.84
* Probably due to this line of code: https://github.com/odoo/odoo/blob/9.0/addons/account/models/account_invoice.py#L1241

**Video/Screenshot link (optional):**
* On Runbot Community 9.0: https://www.youtube.com/watch?v=60qPmczo5vk


addons/account/models/account_invoice.py
base = fields.Monetary(string='Base', compute='_compute_base_amount')
class AccountPaymentTerm(models.Model):
    _name = "account.payment.term"
    _description = "Payment Term"
    _order = "name"
    def _default_line_ids(self):
        return [(0, 0, {'value': 'balance', 'value_amount': 0.0, 'sequence': 9, 'days': 0, 'option': 'day_after_invoice_date'})]
    name = fields.Char(string='Payment Term', translate=True, required=True)
    active = fields.Boolean(default=True, help="If the active field is set to False, it will allow you to hide the payment term without removing it.")
    note = fields.Text(string='Description on the Invoice', translate=True)
    line_ids = fields.One2many('account.payment.term.line', 'payment_id', string='Terms', copy=True, default=_default_line_ids)
    company_id = fields.Many2one('res.company', string='Company', required=True, default=lambda self: self.env.user.company_id)
    @api.constrains('line_ids')
    @api.one
    def _check_lines(self):
        payment_term_lines = self.line_ids.sorted()
        if payment_term_lines and payment_term_lines[-1].value != 'balance':
            raise ValidationError(_('A Payment Term should have its last line of type Balance.'))
        lines = self.line_ids.filtered(lambda r: r.value == 'balance')
        if len(lines) > 1:
            raise ValidationError(_('A Payment Term should have only one line of type Balance.'))
    @api.one
    def compute(self, value, date_ref=False):
        date_ref = date_ref or fields.Date.today()
        amount = value
        sign = value < 0 and -1 or 1
        result = []
        if self.env.context.get('currency_id'):
            currency = self.env['res.currency'].browse(self.env.context['currency_id'])
        else: