From c1279ee66f2879164808e47a2962b29259cb0d36 Mon Sep 17 00:00:00 2001 From: peitra Date: Fri, 19 Jun 2020 08:36:40 +0100 Subject: [PATCH 1/3] Fix in Patience Issue Showing Incorrect Date --- interface/patient_file/summary/stats_full.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interface/patient_file/summary/stats_full.php b/interface/patient_file/summary/stats_full.php index 57b7224ce..d7e396e1e 100644 --- a/interface/patient_file/summary/stats_full.php +++ b/interface/patient_file/summary/stats_full.php @@ -285,8 +285,8 @@ function newEncounter() { echo " \n"; echo " " . text($disptitle) . "\n"; - echo " " . text(date(DateFormatRead(true), strtotime($row['begdate']))) . " \n"; - echo " " . text(date(DateFormatRead(true), strtotime($row['enddate']))) . " \n"; + echo " " . text($row['begdate']) . " \n"; + echo " " . text($row['enddate']) . " \n"; // both codetext and statusCompute have already been escaped above with htmlspecialchars) echo " " . $codetext . "\n"; echo " " . $statusCompute . " \n"; From 6442ca9f302bea08db78f666f55f7bed06f42b62 Mon Sep 17 00:00:00 2001 From: peitra Date: Thu, 2 Jul 2020 15:04:04 +0100 Subject: [PATCH 2/3] A Fix In Patience Issues Showing Incorrect Date Without An Entry --- interface/patient_file/summary/stats_full.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interface/patient_file/summary/stats_full.php b/interface/patient_file/summary/stats_full.php index d7e396e1e..fd2d0b71c 100644 --- a/interface/patient_file/summary/stats_full.php +++ b/interface/patient_file/summary/stats_full.php @@ -285,8 +285,8 @@ function newEncounter() { echo " \n"; echo " " . text($disptitle) . "\n"; - echo " " . text($row['begdate']) . " \n"; - echo " " . text($row['enddate']) . " \n"; + echo " " . text(date(DateFormatRead(true), date($row['begdate']))) . " \n"; + echo " " . text(date(DateFormatRead(true), date($row['enddate']))) . " \n"; // both codetext and statusCompute have already been escaped above with htmlspecialchars) echo " " . $codetext . "\n"; echo " " . $statusCompute . " \n"; From acff3d7322a974cbac1c99494f0671b03ecb5a90 Mon Sep 17 00:00:00 2001 From: peitra Date: Mon, 20 Jul 2020 08:39:16 +0100 Subject: [PATCH 3/3] A fix in issue #1555 --- interface/patient_file/summary/stats_full.php | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/interface/patient_file/summary/stats_full.php b/interface/patient_file/summary/stats_full.php index fd2d0b71c..ad4cf4204 100644 --- a/interface/patient_file/summary/stats_full.php +++ b/interface/patient_file/summary/stats_full.php @@ -282,11 +282,21 @@ function newEncounter() { $click_class='statrow'; if($row['erx_source']==1 && $focustype=='allergy') $click_class=''; elseif($row['erx_uploaded']==1 && $focustype=='medication') $click_class=''; - + echo " \n"; echo " " . text($disptitle) . "\n"; - echo " " . text(date(DateFormatRead(true), date($row['begdate']))) . " \n"; - echo " " . text(date(DateFormatRead(true), date($row['enddate']))) . " \n"; + + if (!is_null($row['begdate'])){ + echo " " . text(date(DateFormatRead(true), strtotime($row['begdate']))) . " \n"; + } else { + echo " \n"; + } + if (!is_null($row['enddate'])){ + echo " " . text(date(DateFormatRead(true), strtotime($row['enddate']))) . " \n"; + } else { + echo " \n"; + } + // both codetext and statusCompute have already been escaped above with htmlspecialchars) echo " " . $codetext . "\n"; echo " " . $statusCompute . " \n";