boluscalc projection fix

This commit is contained in:
MilosKozak
2015-11-07 10:35:39 +01:00
parent 694569e7d9
commit c6710d9474
+2 -2
View File
@@ -295,8 +295,8 @@ function init(client, $, plugins) {
$('#bc_insulintotal').text(record.insulin.toFixed(2));
// Carbs needed if too much iob or in range message when nothing entered and in range
var outcome = record.bg - record.insulin * isf;
if (record.othercorrection === 0 && record.carbs === 0 && record.cob === 0 && outcome > targetBGLow && outcome < targetBGHigh) {
var outcome = record.bg - record.iob * isf;
if (record.othercorrection === 0 && record.carbs === 0 && record.cob === 0 && record.bg > 0 && outcome > targetBGLow && outcome < targetBGHigh) {
$('#bc_carbsneeded').text('');
$('#bc_insulinover').text('');
$('#bc_carbsneededtr').css('display','none');