diff --git a/portal_pos_order_amount/controllers/main.py b/portal_pos_order_amount/controllers/main.py index f5389d1b0..0ec84b26e 100644 --- a/portal_pos_order_amount/controllers/main.py +++ b/portal_pos_order_amount/controllers/main.py @@ -5,7 +5,6 @@ from itertools import groupby from odoo.http import request -from odoo.tools import float_repr from odoo.addons.portal.controllers.portal import CustomerPortal @@ -28,15 +27,12 @@ def _prepare_portal_layout_values(self): ] ) ) - values["pos_order_amount"] = float_repr( - sum(po.amount_total for po in owned_pos_order), 2 - ) + values["pos_order_amount"] = sum(po.amount_total for po in owned_pos_order) values["pos_order_amount_by_year"] = [ { "year": year, - "amount": float_repr( - sum(pos_order.amount_total for pos_order in grouped_pos_orders), - 2, + "amount": sum( + pos_order.amount_total for pos_order in grouped_pos_orders ), } for year, grouped_pos_orders in groupby( diff --git a/portal_pos_order_amount/templates/portal_pos_order_amount.xml b/portal_pos_order_amount/templates/portal_pos_order_amount.xml index 64af3ad78..83fdc41f2 100644 --- a/portal_pos_order_amount/templates/portal_pos_order_amount.xml +++ b/portal_pos_order_amount/templates/portal_pos_order_amount.xml @@ -20,9 +20,8 @@ You have purchased a total amount of - . + t-options='{"widget": "monetary", "display_currency": company_currency}' + />.

@@ -40,7 +39,7 @@