From 04f2b6e823278af87f69621f8d50777c4c471832 Mon Sep 17 00:00:00 2001 From: Richard Hitier Date: Wed, 14 Apr 2021 11:08:26 +0200 Subject: [PATCH] Fix period as category when value is integer --- app/main/static/js/charges.js | 3 +++ 1 file changed, 3 insertions(+), 0 deletions(-) diff --git a/app/main/static/js/charges.js b/app/main/static/js/charges.js index 255a3fa..28c0fed 100644 --- a/app/main/static/js/charges.js +++ b/app/main/static/js/charges.js @@ -302,6 +302,9 @@ function build_chart(div_selector, data_url, entity_name, category_type) { var categories_total_charge = {} data.forEach(function (d) { Object.keys(d).forEach(function (k) { + if (k === 'period') { + return; + } if (categories_total_charge.hasOwnProperty(k)) { categories_total_charge[k] += +d[k] } else { -- libgit2 0.21.2