From 6366150484668ebfce98f9d7483db52103cca500 Mon Sep 17 00:00:00 2001 From: Nicolas Martinelli Date: Tue, 24 Oct 2017 14:16:26 +0200 Subject: [PATCH] [FIX] point_of_sale: apply fiscal position Commit https://github.com/odoo/odoo/commit/5afb5ecd04cf49be6bedb655b187b19a65e1e02d#diff-1c14accbe350f7a177b3e81e5846861bL1363 removed the call to `_map_tax_fiscal_position`. Fiscal positions are not applied anymore... Instead of applying the fiscal position in the `compute_all` method as it used to be, we apply it just before the call. This mimics the behavior of SO/PO/Invoices, where the taxes are changed directly on the order line. --- addons/point_of_sale/static/src/js/models.js | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/point_of_sale/static/src/js/models.js b/addons/point_of_sale/static/src/js/models.js index edc1114389a..5321e0ee13a 100644 --- a/addons/point_of_sale/static/src/js/models.js +++ b/addons/point_of_sale/static/src/js/models.js @@ -1482,6 +1482,7 @@ exports.Orderline = Backbone.Model.extend({ return t.id === el; })); }); + product_taxes = _.map(product_taxes, this._map_tax_fiscal_position.bind(this)); var all_taxes = this.compute_all(product_taxes, price_unit, this.get_quantity(), this.pos.currency.rounding); _(all_taxes.taxes).each(function(tax) {