diff --git a/apps/monitor/calc.py b/apps/monitor/calc.py index 364a8bf..c828389 100644 --- a/apps/monitor/calc.py +++ b/apps/monitor/calc.py @@ -52,7 +52,8 @@ class Calc: return {"startdate": startRate[0], "startvalue": startRate[1], "curdate": endRate[0], "curvalue": endRate[1], "mindate": minRate[0], "minvalue": minRate[1], - "maxdate": maxRate[0], "maxvalue": maxRate[1]} + "maxdate": maxRate[0], "maxvalue": maxRate[1], + "diffPercentage": (Decimal(endRate[1])-Decimal(startRate[1]))/Decimal(startRate[1])*100} return None diff --git a/apps/monitor/templates/monitor.html b/apps/monitor/templates/monitor.html index c7d5c9f..1dfc8de 100644 --- a/apps/monitor/templates/monitor.html +++ b/apps/monitor/templates/monitor.html @@ -101,10 +101,11 @@