From 514bdcda31ee88ad94d62616247e1f1beea1f192 Mon Sep 17 00:00:00 2001 From: Milos Kozak Date: Fri, 14 Sep 2018 10:04:48 +0200 Subject: [PATCH] copy pumpId when converting EB -> TRB --- .../main/java/info/nightscout/androidaps/db/TemporaryBasal.java | 1 + .../plugins/PumpInsight/history/HistoryLogAdapter.java | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/info/nightscout/androidaps/db/TemporaryBasal.java b/app/src/main/java/info/nightscout/androidaps/db/TemporaryBasal.java index 09331a52ce..f36e9ae6c4 100644 --- a/app/src/main/java/info/nightscout/androidaps/db/TemporaryBasal.java +++ b/app/src/main/java/info/nightscout/androidaps/db/TemporaryBasal.java @@ -105,6 +105,7 @@ public class TemporaryBasal implements Interval { this.isFakeExtended = true; this.netExtendedRate = extendedBolus.absoluteRate(); this.absoluteRate = basal + extendedBolus.absoluteRate(); + this.pumpId = extendedBolus.pumpId; } public TemporaryBasal clone() { diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/PumpInsight/history/HistoryLogAdapter.java b/app/src/main/java/info/nightscout/androidaps/plugins/PumpInsight/history/HistoryLogAdapter.java index 1724c62344..fc44f25418 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/PumpInsight/history/HistoryLogAdapter.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/PumpInsight/history/HistoryLogAdapter.java @@ -83,7 +83,7 @@ class HistoryLogAdapter { log.debug("Create new EB: " + eventDate + " " + insulin + " " + durationInMinutes); } else { if (L.isEnabled(L.PUMP)) - log.debug("Loaded existing EB record: " + extendedBolusFromHistory.toString()); + log.debug("Loaded existing EB record: " + extendedBolusFromHistory.log()); if (Math.abs(eventDate - extendedBolusFromHistory.date) < MAX_TIME_DIFFERENCE) { if (extendedBolusFromHistory.source != Source.PUMP) { if (L.isEnabled(L.PUMP))