3 # Transfer data into array
4 while($row=$pregs->FetchRow()){
5 $pregbuf[$row['encounter_nr']]=$row;
6 $buffer=$row['encounter_nr'];
9 if(!isset($show_preg_enc)||
!$show_preg_enc){
11 $show_preg_enc=$HTTP_SESSION_VARS['sess_en'];
14 $show_preg_enc=$buffer;
19 <table border
=0 cellpadding
=0 cellspacing
=0 width
=100%
>
22 if($show_preg_enc&&isset($pregbuf[$show_preg_enc])){
25 $fields=&$obj->coreFieldNames();
26 # If not this encounterĀ“s pregnancy, show warn notice
32 <table border
=0 cellpadding
=1 cellspacing
=1 width
=100%
class="frame">
37 <tr bgcolor
="#fefefe">
38 <td
<?php
echo $tbg; ?
>><FONT color
="#ff0000"><b
><?php
echo $LDEncounterNr; ?
></b
></font
></td
>
39 <td
<?php
echo $tbg; ?
>><FONT color
="#ff0000"><?php
echo $pregbuf[$show_preg_enc]['encounter_nr'] ?
></font
></td
>
45 while(list($z,$x)=each($fields)){
46 if($x=='status') break;
47 if($x=='nr'||
$x=='encounter_nr'||
empty($pregbuf[$show_preg_enc][$x])) continue;
51 <tr bgcolor
="#fefefe">
52 <td
><FONT color
="#006600"><b
><?php
echo $LD[$x]; ?
></b
></font
></td
>
56 case 'delivery_date': echo formatDate2Local($pregbuf[$show_preg_enc][$x],$date_format); break;
57 case 'delivery_time': echo convertTimeToLocal($pregbuf[$show_preg_enc][$x]); break;
59 $buf=&$obj->getDeliveryMode($pregbuf[$show_preg_enc]['delivery_mode']);
60 if(isset($
$buf['LD_var'])&&$
$buf['LD_var']) echo $
$buf['LD_var'];
61 else echo $buf['name'];
64 $buf=&$obj->getOutcome($pregbuf[$show_preg_enc]['outcome']);
65 if(isset($
$buf['LD_var'])&&$
$buf['LD_var']) echo $
$buf['LD_var'];
66 else echo $buf['name'];
68 case 'induction_method':
69 $buf=&$obj->getInductionMethod($pregbuf[$show_preg_enc][$x]);
70 if(isset($
$buf['LD_var'])&&$
$buf['LD_var']) echo $
$buf['LD_var'];
71 else echo $buf['name'];
74 $buf=&$obj->getPerineum($pregbuf[$show_preg_enc][$x]);
75 if(isset($
$buf['LD_var'])&&$
$buf['LD_var']) echo $
$buf['LD_var'];
76 else echo $buf['name'];
78 case 'anaesth_type_nr':
79 $buf=&$obj->getAnaesthesia($pregbuf[$show_preg_enc][$x]);
80 if(isset($
$buf['LD_var'])&&$
$buf['LD_var']) echo $
$buf['LD_var'];
81 else echo $buf['name'];
83 case 'child_encounter_nr':
84 if($pregbuf[$show_preg_enc][$x]){
85 $buf=explode(' ',$pregbuf[$show_preg_enc][$x]);
86 while(list($q,$r)=each($buf)){
87 echo'<a href="aufnahme_daten_zeigen.php'.URL_APPEND
.'&encounter_nr='.$r.'&origin=admit&target='.$target.'">'.$r.'</a> ';
92 if($pregbuf[$show_preg_enc][$x]) echo $LDYes;
96 if($pregbuf[$show_preg_enc][$x]) echo $LDYes;
99 default: echo $pregbuf[$show_preg_enc][$x];
115 if($parent_admit&&$edit&&($show_preg_enc==$HTTP_SESSION_VARS['sess_en']||
$no_enc_preg)){
118 <td colspan
=2> 
;<br
>
119 <img
<?php
echo createComIcon($root_path,'bul_arrowgrnlrg.gif','0','absmiddle'); ?
>>
121 echo$thisfile.URL_APPEND.'&pid='.$HTTP_SESSION_VARS['sess_pid'].'&target='. strtr($target,' ','+').'&mode=new&allow_update='.$allow_update;
122 if($this_enc_preg) echo '&rec_nr='.$pregbuf[$show_preg_enc]['nr'];
125 if($no_enc_preg) echo $LDEnterNewRecord;
126 else echo $LD['update_preg_details'];
133 if($show_details&&$rows>1){
135 <tr bgcolor
="#f6f6f6" valign
="top">
136 <td colspan
=6><img
<?php
echo createComIcon($root_path,'dwnarrowgrnlrg.gif','absmiddle') ?
>> <font size
=3><?php
echo $LDOtherRecords; ?
></font
>
143 if($rows>1||
($no_enc_preg)){
146 <tr bgcolor
="#f6f6f6" valign
="top">
147 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"> 
;</td
>
148 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"><?php
echo $LDEncounterNr; ?
></td
>
149 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"><?php
echo $LDDelivery.' '.$LDDate; ?
></td
>
150 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"><?php
echo $LDDelivery.' '.$LDMode; ?
></td
>
151 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"><?php
echo $LDOutcome; ?
></td
>
152 <td
<?php
echo $tbg; ?
>><FONT color
="#000066"><?php
echo $LDNrOfFetus; ?
></td
>
155 while(list($x,$v)=each($pregbuf)){
156 # Do not list this encounterĀ“s pregnancy in the admission module
157 if($x==$show_preg_enc) continue;
159 <tr bgcolor
="#fefefe" valign
="top">
162 if($parent_admit&&($v['encounter_nr']==$HTTP_SESSION_VARS['sess_en'])) echo '<img '.createComIcon($root_path,'info3.gif','0').'>';
166 <td
><a href
="<?php echo $thisfile.URL_APPEND.'&target='.$target.'&show_preg_enc='.$v['encounter_nr'] ?>"><?php
echo $v['encounter_nr']; ?
></a
></td
>
167 <td
><?php
echo @formatDate2Local
($v['delivery_date'],$date_format); ?
></td
>
168 <td
><?php
echo $v['delivery_mode']; ?
></td
>
169 <td
><?php
echo $v['outcome']; ?
></td
>
170 <td
><?php
echo $v['nr_of_fetuses']; ?
></td
>