2 $bgimg='tableHeader_gr.gif';
3 $tbg= 'background="'.$root_path.'gui/img/common/'.$theme_com_icon.'/'.$bgimg.'"';
7 function cancelAppointment(nr
) {
8 if(confirm('<?php echo $LDSureCancelAppt; ?>')){
9 if(reason
=prompt('<?php echo $LDEnterCancelReason; ?>','')){
10 window
.location
.href
="<?php echo $thisfile.URL_REDIRECT_APPEND."&currYear
=$currYear&currMonth
=$currMonth&currDay
=$currDay&target
=$target&mode
=appt_cancel
&nr
="; ?>"+nr+
"&reason="+reason
;
14 function checkApptDate(d
,e
,n
){
16 if(d
=="<?php echo date('Y-m-d'); ?>"){
19 if (confirm("<?php echo $LDAppointNotToday.'\n'.$LDSureAdmitAppoint; ?>")){
24 window
.location
.href
="<?php echo $root_path.'modules/registration_admission/aufnahme_start.php'.URL_REDIRECT_APPEND; ?>&pid=<?php echo $HTTP_SESSION_VARS['sess_pid'] ?>&origin=patreg_reg&encounter_class_nr="+e+
"&appt_nr="+n
;
31 <table border
=0 cellpadding
=3 cellspacing
=1 width
=100%
>
32 <tr
class="wardlisttitlerow">
33 <td
<?php
echo $tbg; ?
>><FONT SIZE
=-1 FACE
="Arial" color
="#000066"><?php
echo "$LDDate/$LDTime/$LDDetails"; ?
></td
>
34 <td
<?php
echo $tbg; ?
>><FONT SIZE
=-1 FACE
="Arial" color
="#000066"><?php
echo $LDPatient; ?
></td
>
35 <td
<?php
echo $tbg; ?
>><FONT SIZE
=-1 FACE
="Arial" color
="#000066"><?php
echo $LDAppointments; ?
></td
>
36 <td
<?php
echo $tbg; ?
> colspan
=2><FONT SIZE
=-1 FACE
="Arial" color
="#000066"><?php
echo $LDStatus; ?
></td
>
40 /* Get department info */
41 while($row=$result->FetchRow()){
42 if(($row['urgency']==7)&&($row['appt_status']=='pending')){
45 if($toggle) $bgc='wardlistrow2';
46 else $bgc='wardlistrow1';
49 $dept=$dept_obj->getDeptAllInfo($row['to_dept_nr']);
50 if($row['appt_status']=='cancelled') $tc='#9f9f9f';
54 <tr
class="<?php echo $bgc; ?>" >
55 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>"><?php
echo @formatDate2Local
($row['date'],$date_format); ?
></td
>
56 <td rowspan
=4 valign
="top"><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>"><font color
="<?php if(empty($tc)) echo '#0000cc'; else echo $tc; ?>"><b
>
57 <a href
="<?php echo $root_path.'modules/registration_admission/patient_register_show.php'.URL_APPEND.'&pid='.$row['pid']; ?>" title
="<?php echo "$LDRegistration: $LDClk2Show" ?>">
59 echo ucfirst($row['name_last']).'</b></font>, '.ucfirst($row['name_first']).'<br>';
60 echo @formatDate2Local
($row['date_birth'],$date_format);
62 if($row['death_date']&&$row['death_date']!=DBF_NODATE
){
63 echo ' <img '.createComIcon($root_path,'blackcross_sm.gif','0','',TRUE).'> '.@formatDate2Local
($row['death_date'],$date_format).'</font>';
69 case 'f': echo '<img '.$img_female.'>'; break;
70 case 'm': echo '<img '.$img_male.'>'; break;
71 default: echo ' '; break;
76 <td rowspan
=4 valign
="top"><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>">
78 echo nl2br($row['purpose']);
79 if($row['appt_status']=='cancelled'){
80 echo '<br>______________________<br>'.$LDCancelReason.'<br>'.nl2br($row['cancel_reason']);
84 <td
><FONT SIZE
=1 FACE
="Arial" color
="<?php echo $tc; ?>">
86 if($row['appt_status']!='cancelled'){
87 if($row['appt_status']=='done'){
88 $urg_img='check-r.gif';
90 $urg_img='level_'.$row['urgency'].'.gif';
92 echo '<img '.createComIcon($root_path,$urg_img,'0','absmiddle',TRUE).'>';
95 if($row['appt_status']=='done' && $row['encounter_nr']){
96 echo '<a href="'.$root_path.'modules/registration_admission/aufnahme_daten_zeigen.php'.URL_APPEND
.'&encounter_nr='.$row['encounter_nr'].'&origin=appt&target='.$target.'">'.$row['encounter_nr'].'</a>';
104 <td rowspan
=4 valign
="top">
106 if($row['appt_status']=='pending'){
107 if(!$row['death_date']||
$row['death_date']==DBF_NODATE
){
109 <a href
="<?php echo $editorfile.URL_APPEND.'&pid='.$row['pid'].'&target=&mode=select&nr='.$row['nr']; ?>"><img
<?php
echo createLDImgSrc($root_path,'edit_sm.gif','0'); ?
>></a
> <br
>
110 <!-- <a href
="<?php echo $root_path.'modules/registration_admission/aufnahme_start.php'.URL_APPEND; ?>&pid=<?php echo $row['pid'] ?>&origin=patreg_reg&encounter_class_nr=<?php echo $row['encounter_class_nr']; ?>&appt_nr=<?php echo $row['nr']; ?>"><img
<?php
echo createLDImgSrc($root_path,'admit_sm.gif','0'); ?
>></a
> <br
>
111 --> <a href
="javascript:checkApptDate('<?php echo $row['date'] ?>','<?php echo $row['encounter_class_nr'] ?>','<?php echo $row['nr'] ?>' )"><img
<?php
echo createLDImgSrc($root_path,'admit_sm.gif','0'); ?
>></a
> <br
>
116 <a href
="javascript:cancelAppointment(<?php echo $row['nr']; ?>)"><img
<?php
echo createLDImgSrc($root_path,'cancel_sm.gif','0'); ?
>></a
>
124 <tr
class="<?php echo $bgc; ?>" >
125 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>"><?php
echo $row['time']; ?
></td
>
126 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>">
128 $buffer='LD'.$row['appt_status'];
129 if(isset($
$buffer)&&!empty($
$buffer)) echo $
$buffer; else echo $row['appt_status'];
133 <tr
class="<?php echo $bgc; ?>" >
134 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>">
136 if(isset($
$dept['LD_var'])&&!empty($
$dept['LD_var'])) echo $
$dept['LD_var'];
137 else echo $dept['name_formal'];
139 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>">
141 if($row['remind']&&$row['appt_status']=='pending'){
142 if($row['remind_email']) echo '<img '.createComIcon($root_path,'email.gif','0','',TRUE).'> ';
143 if($row['remind_mail']) echo '<img '.createComIcon($root_path,'print.gif','0','',TRUE).'> ';
144 if($row['remind_phone']) echo '<img '.createComIcon($root_path,'violet_phone_2.gif','0','',TRUE).'> ';
148 <tr
class="<?php echo $bgc; ?>" >
149 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>"><?php
echo $row['to_personell_name']; ?
></td
>
150 <td
><FONT SIZE
=-1 FACE
="Arial" color
="<?php echo $tc; ?>">
152 $buf=$enc_class[$row['encounter_class_nr']]['LD_var'];
153 if (isset($
$buf)&&!empty($
$buf)) echo $
$buf;
154 else echo $enc_class[$row['encounter_class_nr']]['name'];