'Compute the amounts of the SO line.'

@api.depends('product_uom_qty', 'discount', 'price_unit', 'tax_id')
def _compute_amount(self):

    for line in self:
        price = (line.price_unit * (1 - ((line.discount or 0.0) / 100.0)))
        taxes = line.tax_id.compute_all(price, line.order_id.currency_id, line.product_uom_qty, product=line.product_id, partner=line.order_id.partner_shipping_id)
        line.update({'price_tax': (taxes['total_included'] - taxes['total_excluded']), 'price_total': taxes['total_included'], 'price_subtotal': taxes['total_excluded']})
