Пример #1
0
 function _consult_report()
 {
     //
     // main API to reports
     //
     if (func_num_args() > 0) {
         $arg_list = func_get_args();
         $menu_id = $arg_list[0];
         $post_vars = $arg_list[1];
         $get_vars = $arg_list[2];
         $validuser = $arg_list[3];
         $isadmin = $arg_list[4];
         //print_r($arg_list);
     }
     // always check dependencies
     if ($exitinfo = $this->missing_dependencies('consult_report')) {
         return print $exitinfo;
     }
     print "<span class='patient'>" . FTITLE_CONSULT_REPORTS . "</span><br/><br/>";
     $c = new consult_report();
     $g = new graph();
     $c->report_menu($menu_id, $post_vars, $get_vars);
     print "<table><tr><td>";
     // column 1
     switch ($get_vars["report_menu"]) {
         case "TCL":
             if ($post_vars["submitreport"]) {
                 $n->process_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
             }
             $c->form_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
             $c->display_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
             break;
         case "SUMMARY":
             $c->form_summary_date($menu_id, $post_vars, $get_vars);
             if ($post_vars["submitreport"]) {
                 $c->generate_summary($menu_id, $post_vars, $get_vars);
             }
             break;
         case "GRAPHS":
             $g->graph_menu($menu_id, $post_vars, $get_vars);
             switch ($get_vars["graph"]) {
                 case "LINE":
                     $get_vars["module"] = $this->module;
                     $g->graph_line($menu_id, $post_vars, $get_vars);
                     break;
                 case "BAR":
                     $get_vars["module"] = $this->module;
                     $g->graph_bar($menu_id, $post_vars, $get_vars);
                     break;
                 case "PIE":
                     $get_vars["module"] = $this->module;
                     $g->graph_pie($menu_id, $post_vars, $get_vars);
                     break;
             }
             break;
     }
     print "</td></tr></table>";
 }
 function _consult_report() {
 //
 // main API to reports
 //
     if (func_num_args()>0) {
         $arg_list = func_get_args();
         $menu_id = $arg_list[0];
         $post_vars = $arg_list[1];
         $get_vars = $arg_list[2];
         $validuser = $arg_list[3];
         $isadmin = $arg_list[4];
         //print_r($arg_list);
     }
     // always check dependencies
     if ($exitinfo = $this->missing_dependencies('consult_report')) {
         return print($exitinfo);
     }
     print "<span class='patient'>".FTITLE_CONSULT_REPORTS."</span><br/><br/>";
     $c = new consult_report;
     $g = new graph;
     $c->report_menu($menu_id, $post_vars, $get_vars);
     print "<table><tr valign='top'><td>";
     // column 1
     switch($get_vars["report_menu"]) {
     case "TCL":
         if ($post_vars["submitreport"]) {
             $n->process_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
         }
         $c->form_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
         $c->display_tcl_inclusive_dates($menu_id, $post_vars, $get_vars);
         break;
     case "SUMMARY":
         if ($post_vars["submitreport"]) {
             $c->generate_summary($menu_id, $post_vars, $get_vars);
         }
         $c->form_summary_date($menu_id, $post_vars, $get_vars);
         $c->display_summary_reports($menu_id, $post_vars, $get_vars);
         break;
     case "GRAPHS":
         $g->graph_menu($menu_id, $post_vars, $get_vars);
         switch($get_vars["graph"]) {
         case "LINE":
             $get_vars["module"] = $this->module;
             $g->graph_line($menu_id, $post_vars, $get_vars);
             break;
         case "BAR":
             $get_vars["module"] = $this->module;
             $g->graph_bar($menu_id, $post_vars, $get_vars);
             break;
         case "PIE":
             $get_vars["module"] = $this->module;
             $g->graph_pie($menu_id, $post_vars, $get_vars);
             break;
         }
         break;
     }
     print "</td><td>";
     // column 2
     print "<b>CONSULT SUMMARY REPORT NOTES</b><br/>";
     print "<p>The <b>consult summary report</b> gets its contents ".
           "from several modules: <b>patient</b>, <b>notes</b>, <b>ICD10</b>, <b>family</b> ".
           "or <b>clinical reminders</b> and <b>barangay</b>. <font color='red'>Therefore, ".
           "it is very important that data in these modules are completely ".
           "and accurately filled up.</font></p>";
     print "<p>".
           "PATIENT MODULE<br/>".
           "- provides patient name, age and gender<br/><br/>".
           "NOTES MODULE<br/>".
           "- provides complaint list, diagnosis (if ICD10 is not filled up), and treatment plan<br/><br/>".
           "ICD10 MODULE<br/>".
           "- provides diagnosis data<br/><br/>".
           "FAMILY MODULE<br/>".
           "- provides family ID, address and barangay<br/><br/>".
           "CLINICAL REMINDERS MODULE<br/>".
           "- provides address and barangay if family registry contains no corresponding entries<br/>".
           "</p>";
     print "</td></tr></table>";
 }