diff --git a/interface/patient_file/summary/demographics.php b/interface/patient_file/summary/demographics.php index d3ea72620a8..979bd6342da 100644 --- a/interface/patient_file/summary/demographics.php +++ b/interface/patient_file/summary/demographics.php @@ -26,6 +26,7 @@ */ require_once("../../globals.php"); + require_once("$srcdir/lists.inc.php"); require_once("$srcdir/patient.inc.php"); require_once("$srcdir/options.inc.php"); @@ -61,6 +62,10 @@ use OpenEMR\Services\PatientService; use Symfony\Component\EventDispatcher\EventDispatcher; +// Reset the previous name flag to allow normal operation. +// This is set in new.php so we can prevent new previous name from being added i.e no pid available. +OpenEMR\Common\Session\SessionUtil::setSession('disablePreviousNameAdds', 0); + $twig = new TwigContainer(null, $GLOBALS['kernel']); // Set session for pid (via setpid). Also set session for encounter (if applicable) diff --git a/library/specialty_forms.php b/library/specialty_forms.php index e7619ce0d5e..4201202ebc1 100644 --- a/library/specialty_forms.php +++ b/library/specialty_forms.php @@ -8,7 +8,7 @@ * @package OpenEMR * @link https://www.open-emr.org * @author Jerry Padgett - * @copyright Copyright (c) 2021 Jerry Padgett + * @copyright Copyright (c) 2021-2024 Jerry Padgett * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3 */ @@ -21,106 +21,121 @@ CsrfUtils::csrfNotVerified(); } +$disablePreviousNameAdds = (int)$_SESSION['disablePreviousNameAdds'] ?? 0; + $form = trim($_GET['form_handler']); echo ""; ?> -<?php echo xlt("Specialty Form"); ?> - - - + - -
-
- - - -
-

-
-
- - -
-
-
-
- - -
-
-
-
- - -
-
-
-
- - -
-
-
-
- - -
-
-
-
- - + " . xlt('Sorry! Add New not allowed here') . "

" . + xlt("Since we are creating a new patient and an associated patient id has not been created yet, we are unable to establish a relationship between patient and the new name to save.") . + "
" . xlt("You can add Previous Names after saving the new patient.") . "

"; + ?> +
+
+ + + +
-
-
-
- - + +
+ + + + +
+

+
+
+ + +
+
+
+
+ + +
+
+
+
+ + +
+
+
+
+ + +
+
+
+
+ + +
+
+
+
+ + +
+
+
+
+
+ + +
+
+
-
- -
- +