summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorPierre Masereel <pim@odoo.com>2021-04-20 21:23:24 +0000
committerPierre Masereel <pim@odoo.com>2021-04-20 21:23:24 +0000
commit45a2a36f3f0a94731d44de201f0cd3d88f50b2b3 (patch)
treec1132459cae14b9acd512396bdfedb959e3afb01 /addons
parentfc1005aa1e0e348495bf2ceb00081b5d8d7c5550 (diff)
[FIX] point_of_sale: fix pricelist discount display
When a pricelist is set to display a discount, it also display the price difference when the price is increased for a reason. To avoid such an anoying behavior, that'll show that the price of a product as been increased by aplying a discount, we only show the old price when it has been decreased. closes odoo/odoo#69569 Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Diffstat (limited to 'addons')
-rw-r--r--addons/point_of_sale/static/src/js/Screens/ReceiptScreen/OrderReceipt.js2
-rw-r--r--addons/point_of_sale/static/src/xml/Screens/ProductScreen/Orderline.xml2
2 files changed, 2 insertions, 2 deletions
diff --git a/addons/point_of_sale/static/src/js/Screens/ReceiptScreen/OrderReceipt.js b/addons/point_of_sale/static/src/js/Screens/ReceiptScreen/OrderReceipt.js
index 39538809ca4..b7c5db5c456 100644
--- a/addons/point_of_sale/static/src/js/Screens/ReceiptScreen/OrderReceipt.js
+++ b/addons/point_of_sale/static/src/js/Screens/ReceiptScreen/OrderReceipt.js
@@ -34,7 +34,7 @@ odoo.define('point_of_sale.OrderReceipt', function(require) {
line.quantity === 1 &&
!(
line.display_discount_policy == 'without_discount' &&
- line.price != line.price_lst
+ line.price < line.price_lst
)
);
}
diff --git a/addons/point_of_sale/static/src/xml/Screens/ProductScreen/Orderline.xml b/addons/point_of_sale/static/src/xml/Screens/ProductScreen/Orderline.xml
index a285af942d0..258e44e2e98 100644
--- a/addons/point_of_sale/static/src/xml/Screens/ProductScreen/Orderline.xml
+++ b/addons/point_of_sale/static/src/xml/Screens/ProductScreen/Orderline.xml
@@ -37,7 +37,7 @@
<span> </span><t t-esc="props.line.get_unit().name" />
at
<t t-if="props.line.display_discount_policy() == 'without_discount' and
- props.line.get_unit_display_price() != props.line.get_lst_price()">
+ props.line.get_unit_display_price() &lt; props.line.get_lst_price()">
<s>
<t t-esc="env.pos.format_currency(props.line.get_fixed_lst_price(),'Product Price')" />
</s>