From 5407ebecb122a9b022f4ad009dff62060ef9db47 Mon Sep 17 00:00:00 2001 From: "DESKTOP-GENO133\\IvanPlex" Date: Thu, 1 Feb 2024 06:59:54 -0700 Subject: [PATCH] Fix UTF encoding bug in dashboard. --- Views/Vehicle/_GasCostByMonthReport.cshtml | 2 +- Views/Vehicle/_MPGByMonthReport.cshtml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Views/Vehicle/_GasCostByMonthReport.cshtml b/Views/Vehicle/_GasCostByMonthReport.cshtml index 7bbe2ee..3c23c43 100644 --- a/Views/Vehicle/_GasCostByMonthReport.cshtml +++ b/Views/Vehicle/_GasCostByMonthReport.cshtml @@ -16,7 +16,7 @@ var useDarkMode = getGlobalConfig().useDarkMode; @foreach (CostForVehicleByMonth gasCost in Model) { - @:barGraphLabels.push("@gasCost.MonthName"); + @:barGraphLabels.push(decodeHTMLEntities("@gasCost.MonthName")); @:barGraphData.push(globalParseFloat('@gasCost.Cost')); var index = sortedByMPG.FindIndex(x => x.MonthName == gasCost.MonthName); @:barGraphColors.push('@barGraphColors[index]'); diff --git a/Views/Vehicle/_MPGByMonthReport.cshtml b/Views/Vehicle/_MPGByMonthReport.cshtml index e0bf9e6..7725c88 100644 --- a/Views/Vehicle/_MPGByMonthReport.cshtml +++ b/Views/Vehicle/_MPGByMonthReport.cshtml @@ -17,7 +17,7 @@ var useDarkMode = getGlobalConfig().useDarkMode; @foreach (CostForVehicleByMonth gasCost in Model) { - @:barGraphLabels.push("@gasCost.MonthName"); + @:barGraphLabels.push(decodeHTMLEntities("@gasCost.MonthName")); @:barGraphData.push(globalParseFloat('@gasCost.Cost')); var index = sortedByMPG.FindIndex(x => x.MonthName == gasCost.MonthName); @:barGraphColors.push('@barGraphColors[index]');