diff --git a/interface/new/new.php b/interface/new/new.php
index c1cb39955ef..c7b4876cfc2 100644
--- a/interface/new/new.php
+++ b/interface/new/new.php
@@ -12,6 +12,9 @@
$form_mname = $_POST['mname' ] ? trim($_POST['mname' ]) : '';
$form_lname = $_POST['lname' ] ? trim($_POST['lname' ]) : '';
$form_refsource = $_POST['refsource'] ? trim($_POST['refsource']) : '';
+$form_sex = $_POST['sex' ] ? trim($_POST['sex' ]) : '';
+$form_refsource = $_POST['refsource'] ? trim($_POST['refsource']) : '';
+$form_dob = $_POST['DOB' ] ? trim($_POST['DOB' ]) : '';
$form_regdate = $_POST['regdate' ] ? trim($_POST['regdate' ]) : date('Y-m-d');
?>
@@ -117,6 +120,26 @@ function validate() {
+
>
:
diff --git a/interface/new/new_patient_save.php b/interface/new/new_patient_save.php
index 66ae2c4a7cb..1b6d933e117 100644
--- a/interface/new/new_patient_save.php
+++ b/interface/new/new_patient_save.php
@@ -39,7 +39,7 @@
$pid = 0;
}
-//what do we set for the public pid?
+// what do we set for the public pid?
if (isset($_POST["pubpid"]) && ($_POST["pubpid"] != "")) {
$mypubpid = $_POST["pubpid"];
} else {
@@ -48,118 +48,119 @@
if ($_POST['form_create']) {
- $form_fname = ucwords(trim($_POST["fname"]));
- $form_lname = ucwords(trim($_POST["lname"]));
- $form_mname = ucwords(trim($_POST["mname"]));
-
- // ===================
- // DBC SYSTEM
- $form_dbcprefix = ( $GLOBALS['dutchpc'] ) ? ucwords(trim($_POST["dbc_prefix"])) : '' ;
- $form_dbcprefixpartner = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_prefix_partner"]) : '' ;
- $form_dbclastpartner = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_lastname_partner"]) : '' ;
- $form_sex = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_sex"]) : '' ;
+ $form_fname = ucwords(trim($_POST["fname"]));
+ $form_lname = ucwords(trim($_POST["lname"]));
+ $form_mname = ucwords(trim($_POST["mname"]));
+
+ // ===================
+ // DBC SYSTEM
+ $form_dbcprefix = $GLOBALS['dutchpc'] ? ucwords(trim($_POST["dbc_prefix"])) : '' ;
+ $form_dbcprefixpartner = $GLOBALS['dutchpc'] ? trim($_POST["dbc_prefix_partner"]) : '' ;
+ $form_dbclastpartner = $GLOBALS['dutchpc'] ? trim($_POST["dbc_lastname_partner"]) : '' ;
+ $form_sex = $GLOBALS['dutchpc'] ? trim($_POST["dbc_sex"]) : trim($_POST["sex"]) ;
+ /****
// in db the value for sex is a word! so we must translate it
switch ( $form_sex ) {
case 1 : $form_sex = 'Male'; break;
case 2: $form_sex = 'Female'; break;
default: $form_sex = 'Male';
}
- $form_voorletters = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_voorletters"]) : '' ;
- $form_dob = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_geboort"]) : '' ;
- $form_street = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_straat"]) : '' ;
- $form_number = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_nummer"]) : '' ;
- $form_addition = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_toevoe"]) : '' ;
- $form_city = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_plaats"]) : '' ;
- $form_postcode = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_postal"]) : '' ;
- $form_countrycode = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_land"]) : '' ;
- $form_provider = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_insurance"]) : '' ;
- $form_insdate = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_insdatum"]) : '' ;
- $form_policy = ( $GLOBALS['dutchpc'] ) ? trim($_POST["dbc_policy"]) : '' ;
- // EOS DBC
- // ===================
-
- newPatientData(
- $_POST["db_id"],
- $_POST["title"],
- $form_fname,
- $form_lname,
- $form_mname,
- $form_sex, // sex
- $form_dob, // dob
- $form_street, // street
+ ****/
+ $form_voorletters = $GLOBALS['dutchpc'] ? trim($_POST["dbc_voorletters"]) : '' ;
+ $form_dob = $GLOBALS['dutchpc'] ? trim($_POST["dbc_geboort"]) : trim($_POST["DOB"]) ;
+ $form_street = $GLOBALS['dutchpc'] ? trim($_POST["dbc_straat"]) : '' ;
+ $form_number = $GLOBALS['dutchpc'] ? trim($_POST["dbc_nummer"]) : '' ;
+ $form_addition = $GLOBALS['dutchpc'] ? trim($_POST["dbc_toevoe"]) : '' ;
+ $form_city = $GLOBALS['dutchpc'] ? trim($_POST["dbc_plaats"]) : '' ;
+ $form_postcode = $GLOBALS['dutchpc'] ? trim($_POST["dbc_postal"]) : '' ;
+ $form_countrycode = $GLOBALS['dutchpc'] ? trim($_POST["dbc_land"]) : '' ;
+ $form_provider = $GLOBALS['dutchpc'] ? trim($_POST["dbc_insurance"]) : '' ;
+ $form_insdate = $GLOBALS['dutchpc'] ? trim($_POST["dbc_insdatum"]) : '' ;
+ $form_policy = $GLOBALS['dutchpc'] ? trim($_POST["dbc_policy"]) : '' ;
+ // EOS DBC
+ // ===================
+
+ newPatientData(
+ $_POST["db_id"],
+ $_POST["title"],
+ $form_fname,
+ $form_lname,
+ $form_mname,
+ $form_sex, // sex
+ $form_dob, // dob
+ $form_street, // street
$form_street, // DBC use ---- $nstreet
$form_number, // DBC use ---- $nnr
$form_addition, // DBC use ---- $nadd
- $form_postcode, // postal_code
- $form_city, // city
- "", // state
- $form_countrycode, // country_code
- "", // ss
- "", // occupation
- "", // phone_home
- "", // phone_biz
- "", // phone_contact
- "", // status
- "", // contact_relationship
- "", // referrer
- "", // referrerID
- "", // email
- "", // language
- "", // ethnoracial
- "", // interpreter
- "", // migrantseasonal
- "", // family_size
- "", // monthly_income
- "", // homeless
- "", // financial_review
- "$mypubpid",
- $pid,
- "", // providerID
- "", // genericname1
- "", // genericval1
- "", // genericname2
- "", // genericval2
- "", // phone_cell
- "", // hipaa_mail
- "", // hipaa_voice
- 0, // squad
- 0, // $pharmacy_id = 0,
- "", // $drivers_license = "",
- "", // $hipaa_notice = "",
- "", // $hipaa_message = "",
- $_POST['regdate'],
- // ======== dutch specific
- $form_dbcprefix, // $prefixlast
- $form_dbcprefixpartner, // $prefixlastpartner
- $form_dbclastpartner, // $lastpartner
- $form_voorletters, // initials
- "", // $provider_data
- "" // $referer_data
- // ======== EOS dutch specific
-
- );
-
- newEmployerData($pid);
- newHistoryData($pid);
- newInsuranceData($pid, "primary");
- newInsuranceData($pid, "secondary");
- newInsuranceData($pid, "tertiary");
-
-
- // DBC DUTCH INSURANCE DATA
- if ( $GLOBALS['dutchpc'] ) set_insurer_nl($pid, $form_provider, $form_insdate, $form_policy);
- // EOS DBC
-
- // Set referral source separately because we don't want it messed
- // with later by newPatientData().
- if ($refsource = trim($_POST["refsource"])) {
- sqlQuery("UPDATE patient_data SET referral_source = '$refsource' " .
- "WHERE pid = '$pid'");
- }
+ $form_postcode, // postal_code
+ $form_city, // city
+ "", // state
+ $form_countrycode, // country_code
+ "", // ss
+ "", // occupation
+ "", // phone_home
+ "", // phone_biz
+ "", // phone_contact
+ "", // status
+ "", // contact_relationship
+ "", // referrer
+ "", // referrerID
+ "", // email
+ "", // language
+ "", // ethnoracial
+ "", // interpreter
+ "", // migrantseasonal
+ "", // family_size
+ "", // monthly_income
+ "", // homeless
+ "", // financial_review
+ "$mypubpid",
+ $pid,
+ "", // providerID
+ "", // genericname1
+ "", // genericval1
+ "", // genericname2
+ "", // genericval2
+ "", // phone_cell
+ "", // hipaa_mail
+ "", // hipaa_voice
+ 0, // squad
+ 0, // $pharmacy_id = 0,
+ "", // $drivers_license = "",
+ "", // $hipaa_notice = "",
+ "", // $hipaa_message = "",
+ $_POST['regdate'],
+ // ======== dutch specific
+ $form_dbcprefix, // $prefixlast
+ $form_dbcprefixpartner, // $prefixlastpartner
+ $form_dbclastpartner, // $lastpartner
+ $form_voorletters, // initials
+ "", // $provider_data
+ "" // $referer_data
+ // ======== EOS dutch specific
+ );
+
+ newEmployerData($pid);
+ newHistoryData($pid);
+ newInsuranceData($pid, "primary");
+ newInsuranceData($pid, "secondary");
+ newInsuranceData($pid, "tertiary");
+
+
+ // DBC DUTCH INSURANCE DATA
+ if ( $GLOBALS['dutchpc'] ) set_insurer_nl($pid, $form_provider, $form_insdate, $form_policy);
+ // EOS DBC
+
+ // Set referral source separately because we don't want it messed
+ // with later by newPatientData().
+ if ($refsource = trim($_POST["refsource"])) {
+ sqlQuery("UPDATE patient_data SET referral_source = '$refsource' " .
+ "WHERE pid = '$pid'");
+ }
// DBC Dutch System
- if ( $GLOBALS['dutchpc'] ) {
- generate_id1250($pid); // generate an ID1250 number
+ if ( $GLOBALS['dutchpc'] ) {
+ generate_id1250($pid); // generate an ID1250 number
}
}
@@ -167,16 +168,16 @@
|