2 require_once("../../globals.php");
3 require_once("$srcdir/billing.inc");
4 require_once("$srcdir/formdata.inc.php");
6 $targparm = $GLOBALS['concurrent_layout'] ?
"" : "target='Main'";
10 addBilling($encounter, $type, $code, strip_escape_custom($text),$pid, $userauthorized,$_SESSION['authUserID']);
12 elseif ($mode == "delete") {
15 elseif ($mode == "clear") {
22 <?php
html_header_show();?
>
23 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
26 <body
class="body_top">
28 <?php
if ($GLOBALS['concurrent_layout']) { ?
>
29 <a href
="encounter_bottom.php" onclick
="top.restoreSession()">
31 <a href
="patient_encounter.php" target
="Main" onclick
="top.restoreSession()">
34 <span
class=title
><?php
xl('Billing','e'); ?
></span
>
35 <font
class=more
><?php
echo $tback;?
></font
></a
>
37 <table border
=0 cellpadding
=3 cellspacing
=0>
40 if ($result = getBillingByEncounter($pid,$encounter,"*") ) {
41 $billing_html = array();
42 foreach ($result as $iter) {
43 if ($iter["code_type"] == "ICD9") {
45 $html .= "<td valign=\"middle\"></td>" .
46 "<td><div><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
47 $iter{"code"} . "</b> " . ucwords(strtolower($iter{"code_text"})) .
49 $billing_html[$iter["code_type"]] .= $html;
52 elseif ($iter["code_type"] == "COPAY") {
53 $billing_html[$iter["code_type"]] .= "<tr><td></td>" .
54 "<td><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
55 $iter{"code"}."</b> " . ucwords(strtolower($iter{"code_text"})) .
59 $billing_html[$iter["code_type"]] .= "<tr><td></td>" .
60 "<td><a $targparm class='small' href='diagnosis_full.php' onclick='top.restoreSession()'><b>" .
61 $iter{"code"} . "</b> " . ucwords(strtolower($iter{"code_text"})) .
62 "</a><span class=\"small\">";
63 $js = split(":",$iter['justify']);
68 $billing_html[$iter["code_type"]] .= " (<b>$j</b>)";
71 $billing_html[$iter["code_type"]] .= " ($j)";
77 $billing_html[$iter["code_type"]] .= "</span></td>";
78 $billing_html[$iter["code_type"]] .= "<td>" .
79 "<a class=\"link_submit\" href='diagnosis_full.php?mode=clear&id=" .
80 $iter{"id"} . "' class='link' onclick='top.restoreSession()'>[" . xl('Clear Justification') .
84 $billing_html[$iter["code_type"]] .= "<td>" .
85 "<a class=\"link_submit\" href='diagnosis_full.php?mode=delete&id=" .
86 $iter{"id"} . "' class='link' onclick='top.restoreSession()'>[Delete]</a></td>";
87 $billing_html[$iter["code_type"]] .= "</tr>\n";
90 foreach ($billing_html as $key => $val) {
91 print "<tr><td>$key</td><td><table>$val</table><td></tr><tr><td height=\"5\"></td></tr>\n";