コード例 #1
0
    if ($rows = $enc_obj->LastRecordCount()) {
        $mode = 'show';
        # If $get_nr is non-empty, get the  single record
        if (isset($get_nr) && $get_nr) {
            if (!($single_obj =& $enc_obj->getSicknessConfirm($get_nr))) {
                $get_nr = 0;
            }
        } else {
            $get_nr = 0;
        }
    } else {
        $mode = '';
    }
}
# Get the insurance data of the encounter
if ($insure_obj = $enc_obj->EncounterInsuranceData()) {
    $insurance = $insure_obj->FetchRow();
} else {
    $insurance = false;
}
if ((!isset($pid) || !$pid) && $_SESSION['sess_pid']) {
    $pid = $_SESSION['sess_pid'];
} elseif (isset($pid) && $pid && !$_SESSION['sess_pid']) {
    $_SESSION['sess_pid'] = $pid;
}
if (!isset($user_id) || !$user_id) {
    $user_id = $local_user . $sid;
    $user_id = ${$user_id};
}
if (isset($pid) && $pid != '') {
    $person_obj = new Person($pid);