[FIX] account_financial_report: crash in XSLX report on partner balance

pull/1241/head
Alexis de Lattre 2024-06-14 18:08:46 +02:00
parent 556fc41d50
commit f356445cb4
1 changed files with 2 additions and 3 deletions

View File

@ -597,9 +597,8 @@ class AbstractReportXslx(models.AbstractModel):
{"bold": True, "border": True, "bg_color": "#FFFFCC"}
)
report_data["field_name"] = format_amt
format_amount = "#,##0." + (
"0" * line_object["currency_id"].decimal_places
)
currency = self.env["res.currency"].browse(line_object["currency_id"])
format_amount = "#,##0." + ("0" * currency.decimal_places)
format_amt.set_num_format(format_amount)
return format_amt