2 include_once("../../globals.php");
3 include_once("$srcdir/billing.inc");
5 $targparm = $GLOBALS['concurrent_layout'] ?
"" : "target='Main'";
9 addBilling($encounter, $type, $code, $text,$pid, $userauthorized,$_SESSION['authUserID']);
11 elseif ($mode == "delete") {
14 elseif ($mode == "clear") {
21 <?php
html_header_show();?
>
22 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
25 <body
class="body_top">
27 <?php
if ($GLOBALS['concurrent_layout']) { ?
>
28 <a href
="encounter_bottom.php" onclick
="top.restoreSession()">
30 <a href
="patient_encounter.php" target
="Main" onclick
="top.restoreSession()">
33 <span
class=title
><?php
xl('Billing','e'); ?
></span
>
34 <font
class=more
><?php
echo $tback;?
></font
></a
>
36 <table border
=0 cellpadding
=3 cellspacing
=0>
39 if ($result = getBillingByEncounter($pid,$encounter,"*") ) {
40 $billing_html = array();
41 foreach ($result as $iter) {
42 if ($iter["code_type"] == "ICD9") {
44 $html .= "<td valign=\"middle\"></td>" .
45 "<td><div><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
46 $iter{"code"} . "</b> " . ucwords(strtolower($iter{"code_text"})) .
48 $billing_html[$iter["code_type"]] .= $html;
51 elseif ($iter["code_type"] == "COPAY") {
52 $billing_html[$iter["code_type"]] .= "<tr><td></td>" .
53 "<td><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
54 $iter{"code"}."</b> " . ucwords(strtolower($iter{"code_text"})) .
58 $billing_html[$iter["code_type"]] .= "<tr><td></td>" .
59 "<td><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
60 $iter{"code"} . "</b> " . ucwords(strtolower($iter{"code_text"})) .
61 "</a><span class=\"small\">";
62 $js = split(":",$iter['justify']);
67 $billing_html[$iter["code_type"]] .= " (<b>$j</b>)";
70 $billing_html[$iter["code_type"]] .= " ($j)";
76 $billing_html[$iter["code_type"]] .= "</span></td>";
77 $billing_html[$iter["code_type"]] .= "<td>" .
78 "<a class=\"link_submit\" href='diagnosis_full.php?mode=clear&id=" .
79 $iter{"id"} . "' class='link' onclick='top.restoreSession()'>[" . xl('Clear Justification') .
83 $billing_html[$iter["code_type"]] .= "<td>" .
84 "<a class=\"link_submit\" href='diagnosis_full.php?mode=delete&id=" .
85 $iter{"id"} . "' class='link' onclick='top.restoreSession()'>[Delete]</a></td>";
86 $billing_html[$iter["code_type"]] .= "</tr>\n";
89 foreach ($billing_html as $key => $val) {
90 print "<tr><td>$key</td><td><table>$val</table><td></tr><tr><td height=\"5\"></td></tr>\n";