[FIX] point_of_sale: handle fiscal positions that remove taxes
A tax can be mapped to nothing, so first check if _map_tax_fiscal_position actually returned something. Fixes #17963
This commit is contained in:
@@ -1360,6 +1360,9 @@ exports.Orderline = Backbone.Model.extend({
|
||||
if (!no_map_tax){
|
||||
tax = self._map_tax_fiscal_position(tax);
|
||||
}
|
||||
if (!tax){
|
||||
return;
|
||||
}
|
||||
if (tax.amount_type === 'group'){
|
||||
var ret = self.compute_all(tax.children_tax_ids, price_unit, quantity, currency_rounding);
|
||||
total_excluded = ret.total_excluded;
|
||||
|
||||
Reference in New Issue
Block a user