From b98c131a34bc4fba513cc18f22f611c2dd5c637a Mon Sep 17 00:00:00 2001 From: Michael Kroes Date: Tue, 17 Nov 2020 09:50:48 +0100 Subject: [PATCH] Added a specific rendering for BG Check events on the Day to Day report. Added an option to hide BG Check and other events on the Day to Day report. --- lib/report/reportclient.js | 4 +++- lib/report/reportstorage.js | 4 +++- lib/report_plugins/daytoday.js | 15 +++++++++++++-- 3 files changed, 19 insertions(+), 4 deletions(-) diff --git a/lib/report/reportclient.js b/lib/report/reportclient.js index aed324d84a7..b62a5467b64 100644 --- a/lib/report/reportclient.js +++ b/lib/report/reportclient.js @@ -246,7 +246,9 @@ var init = function init () { options.cob = true; options.openAps = true; } - + options.bgcheck = $('#rp_optionsbgcheck').is(':checked'); + options.othertreatments = $('#rp_optionsothertreatments').is(':checked'); + const reportStorage = require('./reportstorage'); reportStorage.saveProps(options); var matchesneeded = 0; diff --git a/lib/report/reportstorage.js b/lib/report/reportstorage.js index e0a8d8b9d17..5997261d7eb 100644 --- a/lib/report/reportstorage.js +++ b/lib/report/reportstorage.js @@ -12,7 +12,9 @@ const defaultValues = { predicted: false, openAps: false, insulindistribution: true, - predictedTruncate: true + predictedTruncate: true, + bgcheck: true, + othertreatments: false }; let cachedProps; diff --git a/lib/report_plugins/daytoday.js b/lib/report_plugins/daytoday.js index 928c6b8579f..49aad99ed16 100644 --- a/lib/report_plugins/daytoday.js +++ b/lib/report_plugins/daytoday.js @@ -35,6 +35,8 @@ daytoday.html = function html (client) { `` + `` + `` + + `` + + `` + ' ' + translate('Size') + '