File manager - Edit - /home/autoph/public_html/portal/includes/chart/ave_urr_vs_bfr.php
Back
<?php if(!isset($_GET['startDate'])){ ?> <form action='' method='GET'> <input type='hidden' name='view' value='plist'> <input type='hidden' name='search' value=''> <input type='hidden' name='sum' value='true'> <input type='hidden' name='go' value='aurrbfr'> <input type='hidden' name='subView' value='hemo'> <br> <input id='datepicker' type="text" name="startDate" value ="<?php echo $toDate;?>" style="font-size:14px;font-weight:normal;color:blue;width:100px;height:28px;border:1px solid lightgray;text-align:left;background:white" onkeyup="addDateSeparator(event,this,'dd/mm/yyyy')" placeholder="mm/dd/yyyy" required> -<input id='datepickerA' type="text" name="endDate" value ="<?php echo $toDate;?>" style="font-size:14px;font-weight:normal;color:blue;width:100px;height:28px;border:1px solid lightgray;text-align:left;background:white" onkeyup="addDateSeparator(event,this,'dd/mm/yyyy')" placeholder="mm/dd/yyyy" required> <input type='submit' name='getDate' value='Search' style='width:80px;height:28px;'> <br> Date Range (Start Date - End Date) </form> <?php }else { $startDate = $_GET['startDate']; $endDate = $_GET['endDate']; ?> <form action='' method='GET'> <input type='hidden' name='view' value='plist'> <input type='hidden' name='search' value=''> <input type='hidden' name='sum' value='true'> <input type='hidden' name='go' value='aurrbfr'> <input type='hidden' name='subView' value='hemo'> <br> <input id='datepicker' type="text" name="startDate" value ="<?php echo $startDate;?>" style="font-size:14px;font-weight:normal;color:blue;width:100px;height:28px;border:1px solid lightgray;text-align:left;background:white" onkeyup="addDateSeparator(event,this,'dd/mm/yyyy')" placeholder="mm/dd/yyyy" required> -<input id='datepickerA' type="text" name="endDate" value ="<?php echo $endDate;?>" style="font-size:14px;font-weight:normal;color:blue;width:100px;height:28px;border:1px solid lightgray;text-align:left;background:white" onkeyup="addDateSeparator(event,this,'dd/mm/yyyy')" placeholder="mm/dd/yyyy" required> <input type='submit' name='getDate' value='Search' style='width:80px;height:28px;'> <br> Date Range (Start Date - End Date) </form> <?php $qq=mysql_query("SELECT * FROM `laboratory_info` WHERE `lab_date` BETWEEN '$startDate' AND '$endDate' AND `branch_id`='$compCode' ");// F6 //SCAN ALL LABORATORY WITHIN THE GIVEN DATE RANGE AND GET AVE. DIALYZER USED PER TYPE while($row = mysql_fetch_array($qq)){ $myBFR =$row['bfr']; if($myBFR < 200 ){ //GET ALL less 200 BFR $myBFRA = $myBFRA + $row['urr']; $myCountA = $myCountA + 1; }else if( $myBFR > 199 && $myBFR < 251){ //GET ALL BFR Higher than 199 lessthan 251 $myBFRB = $myBFRB + $row['urr']; $myCountB = $myCountB + 1; }else if( $myBFR > 250 && $myBFR < 301){ //GET ALL BFR Higher than 250 lessthan 300 $myBFRC = $myBFRC + $row['urr']; $myCountC = $myCountC + 1; }else { //GET ALL higher than 300 bfr $myBFRD = $myBFRD + $row['urr']; $myCountD = $myCountD + 1; } } //echo "Round - ".$fSixCount/$fsixRound; //break; $myBFRAA = number_format(($myBFRA / $myCountA),2,'.',','); $myBFRBB = number_format(($myBFRB / $myCountB),2,'.',','); $myBFRCC= number_format(($myBFRC / $myCountC),2,'.',','); $myBFRDD = number_format(($myBFRD / $myCountD),2,'.',','); ?> <html> <head> <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script> <script type="text/javascript"> google.charts.load("current", {packages:["corechart"]}); google.charts.setOnLoadCallback(drawChart); function drawChart() { var data = google.visualization.arrayToDataTable([ ['BFR', 'AVERAGE',{ role: 'annotation'}], ['Less 200 (<?php echo $myBFRAA;?>)',<?php echo $myBFRAA;?>,<?php echo $myBFRAA;?>,], ['200 - 250 (<?php echo $myBFRBB;?>)',<?php echo $myBFRBB;?>,<?php echo $myBFRBB;?>,], ['251 - 300 (<?php echo $myBFRCC;?>)',<?php echo $myBFRCC;?>,<?php echo $myBFRCC;?>,], ['Above 300 (<?php echo $myBFRDD;?>)',<?php echo $myBFRDD;?>,<?php echo $myBFRDD;?>,], ]); var options = { title: 'AVE. UREA REDUCTION RATE VS. DIALYZER USED <?php echo "(".$startDate." - ".$endDate.")";?> ', is3D: false, }; var chart = new google.visualization.PieChart(document.getElementById('piechart_3d')); chart.draw(data, options);y } google.load("visualization", "1", {packages:["corechart"]}); google.setOnLoadCallback(drawChart1); </script> </head> <body> <div id="piechart_3d" style="width:98%; height: 98%;background:white;font-size:14px;color:black"></div> <center> <?php echo $testLink; ?> </center> </body> </html> <?php }?>
| ver. 1.4 |
.
| PHP 7.3.33 | Generation time: 0 |
proxy
|
phpinfo
|
Settings