diff --git a/interface/login/login.php b/interface/login/login.php index 486d789ea0a..5026661d401 100644 --- a/interface/login/login.php +++ b/interface/login/login.php @@ -55,6 +55,7 @@ // If this script is called with app parameter, validate it without showing other apps. // // Build a list of valid entries +// Original merge v5.0.1 $emr_app = array(); $sql = "SELECT option_id, title,is_default FROM list_options WHERE list_id=? and activity=1 ORDER BY seq, option_id"; $rs = sqlStatement($sql, ['apps']); @@ -83,20 +84,21 @@ if (isset($_REQUEST['app']) && $emr_app[$_REQUEST['app']]) { $div_app = sprintf('', attr($_REQUEST['app'])); } else { + $opt_htm = ''; foreach ($emr_app as $opt_disp => $opt_value) { $opt_htm .= sprintf( '\n', attr($opt_disp), - ($opt_disp == $opt_default ? 'selected="selected"' : ''), + ($opt_disp == ($emr_app_def ?? '') ? 'selected="selected"' : ''), text(xl_list_label($opt_disp)) ); } $div_app = sprintf( ' -
- -
+
+ +
', @@ -208,16 +210,16 @@ function getLanguagesList(): array $viewArgs = [ 'title' => $openemr_name, - 'displayLanguage' => ($GLOBALS["language_menu_login"] && (count($languageList) != 1)) ? true : false, + 'displayLanguage' => $GLOBALS["language_menu_login"] && (count($languageList) != 1), 'defaultLangID' => $defaultLanguage['id'], 'defaultLangName' => $defaultLanguage['language'], 'languageList' => $languageList, 'relogin' => $relogin, - 'loginFail' => (isset($_SESSION["loginfailure"]) && $_SESSION["loginfailure"] == 1) ? true : false, - 'displayFacilities' => ($GLOBALS["login_into_facility"]) ? true : false, + 'loginFail' => isset($_SESSION["loginfailure"]) && $_SESSION["loginfailure"] == 1, + 'displayFacilities' => (bool)$GLOBALS["login_into_facility"], 'facilityList' => $facilities, 'facilitySelected' => $facilitySelected, - 'displayGoogleSignin' => (!empty($GLOBALS['google_signin_enabled']) && !empty($GLOBALS['google_signin_client_id'])) ? true : false, + 'displayGoogleSignin' => !empty($GLOBALS['google_signin_enabled']) && !empty($GLOBALS['google_signin_client_id']), 'googleSigninClientID' => $GLOBALS['google_signin_client_id'], 'displaySmallLogo' => $displaySmallLogo, 'smallLogoOne' => $smallLogoOne, @@ -226,7 +228,7 @@ function getLanguagesList(): array 'displayTagline' => $GLOBALS['show_tagline_on_login'], 'tagline' => $GLOBALS['login_tagline_text'], 'displayAck' => $GLOBALS['display_acknowledgements_on_login'], - 'hasSession' => (session_name()) ? true : false, + 'hasSession' => (bool)session_name(), 'cookieText' => $cookie, 'regTranslations' => $regTranslations, 'regConstants' => json_encode(['webroot' => $GLOBALS['webroot']]), diff --git a/interface/patient_file/encounter/find_code_dynamic_ajax.php b/interface/patient_file/encounter/find_code_dynamic_ajax.php index 87c4166fafb..6c4929ea1d5 100644 --- a/interface/patient_file/encounter/find_code_dynamic_ajax.php +++ b/interface/patient_file/encounter/find_code_dynamic_ajax.php @@ -339,7 +339,8 @@ function genFieldIdString($row) $arow[] = $row['title']; } else { $arow[] = str_replace('|', ':', rtrim($row['code'], '|')); - $arow[] = $row['description']; + $arow[] = $row['description'] ?? ""; + $arow[] = $row['modifier'] ?? ""; } $out['aaData'][] = $arow; }