?> "> <div><?php echo $q["logDetails"]; ?> </div> <div class="vls_grey" style="padding:5px 0px 0px 0px"><strong>Warning Type:</strong> <?php echo $warningType; ?> </div> </td> <td class="<?php echo $count < mysqlnumrows($query) ? "vl_tdstandard" : "vl_tdnoborder"; ?> "><?php echo getFormattedTimeLessS($q["created"]); ?> </td> </tr> <? } } ?> </table> </div> </td> </tr> <tr> <td><img src="/images/spacer.gif" width="10" height="10" /></td> </tr> <tr>
$count+=1; $status=0; $status=getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]'","outcome"); if($count<$num) { echo "<tr> <td class=\"vl_tdstandard\">$q[formNumber]</td> <td class=\"vl_tdstandard\"><a href=\"/verify/find.and.edit/$q[id]/1/\">$q[vlSampleID]</a></td> <td class=\"vl_tdstandard\">".($status?$status:"Pending")."</td> <td class=\"vl_tdstandard\">".getFormattedDate($q["created"])." at ".getFormattedTimeLessS($q["created"])."</td> </tr>"; } else { echo "<tr> <td class=\"vl_tdnoborder\">$q[formNumber]</td> <td class=\"vl_tdnoborder\"><a href=\"/verify/find.and.edit/$q[id]/1/\">$q[vlSampleID]</a></td> <td class=\"vl_tdnoborder\">".($status?$status:"Pending")."</td> <td class=\"vl_tdnoborder\">".getFormattedDate($q["created"])." at ".getFormattedTimeLessS($q["created"])."</td> </tr>"; } } ?> </table> </div> </fieldset> </td> </tr> </table> </div> </td> </tr> <? } else { ?> <tr>
//Date/Time Rejected $row[]=(getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]' and outcome='Rejected' and created!='' limit 1","id")?getRawFormattedDateLessDay(getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]' and outcome='Rejected' limit 1","created")):"")." ".(getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]' and outcome='Rejected' and created!='' limit 1","id")?getFormattedTimeLessS(getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]' and outcome='Rejected' limit 1","created")):""); //Rejection Reason $row[]=getDetailedTableInfo2("vl_appendix_samplerejectionreason","id='".getDetailedTableInfo2("vl_samples_verify","sampleID='$q[id]' and outcome='Rejected' limit 1","outcomeReasonsID")."' limit 1","appendix"); //Date/Time Added to Worksheet $row[]=(getDetailedTableInfo2("vl_samples_worksheet","sampleID='$q[id]' and created!='' limit 1","id")?getRawFormattedDateLessDay(getDetailedTableInfo2("vl_samples_worksheet","sampleID='$q[id]' order by created desc limit 1","created")):"")." ".(getDetailedTableInfo2("vl_samples_worksheet","sampleID='$q[id]' and created!='' limit 1","id")?getFormattedTimeLessS(getDetailedTableInfo2("vl_samples_worksheet","sampleID='$q[id]' order by created desc limit 1","created")):""); //Date/Time Latest Results Uploaded $row[]=($dateLatestResultsUploaded?getRawFormattedDateLessDay($dateLatestResultsUploaded):"")." ".($dateLatestResultsUploaded?getFormattedTimeLessS($dateLatestResultsUploaded):""); //Date/Time Results Printed $row[]=($dateLatestResultsPrinted?getRawFormattedDateLessDay($dateLatestResultsPrinted):"")." ".($dateLatestResultsPrinted?getFormattedTimeLessS($dateLatestResultsPrinted):""); //Date Received at CPHL $row[]=getRawFormattedDateLessDay($q["receiptDate"])." 10:00"; //Date/Time First Printed $row[]=($dateFirstPrinted?getRawFormattedDateLessDay($dateFirstPrinted):"")." ".($dateFirstPrinted?getFormattedTimeLessS($dateFirstPrinted):""); //Date/Time Sample was Captured $row[]=getRawFormattedDateLessDay($q["created"])." ".getFormattedTimeLessS($q["created"]); $xls->addRow($row); } //output to browser $xls->sendFile(); } break; case "facilitiesexcel": //filename of the excel file to be downloaded $filename=0; $filename="excel.facilities.".getFormattedDateCRB($datetime).".xls"; //create an instance of the class $xls = new ExportXLS($filename); $query=0;
<td> <fieldset style="width: 100%"> <legend><strong>ENTRANT'S DETAILS</strong></legend> <div style="padding:5px 0px 0px 0px"> <table width="100%" border="0" class="vl"> <tr> <td width="30%" style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6">Captured By</td> <td width="70%" style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6"><?php echo $createdby; ?> </td> </tr> <tr> <td style="padding:4px 0px">On</td> <td style="padding:4px 0px"><?php echo getFormattedDate($created) . " at " . getFormattedTimeLessS($created); ?> </td> </tr> </table> </div> </fieldset> </td> </tr> </table> </div> </td> </tr> <tr> <td><img src="/images/spacer.gif" width="10" height="10" /></td> </tr>
//compile $from and $to $from=0; $from="$fromYear-$fromMonth-$fromDay"; $to=0; $to="$toYear-$toMonth-$toDay"; $query=0; $query=mysqlquery("select * from vl_logs_warnings where date(created)>='$from' and date(created)<='$to'"); if(mysqlnumrows($query)) { $q=array(); while($q=mysqlfetcharray($query)) { $warningType=0; switch($q["logCategory"]) { case "changedPatientsGender": $warningType="Change in patient's gender"; break; case "capturedRepeatVLTest": $warningType="Capture of a repeat VL test"; break; } $csv.="\"$warningType\",\"$q[logDetails]\",\"".getFormattedTimeLessS($q["created"])."\",\"$q[createdby]\"\n"; } } //output header("Content-type: application/vnd.ms-excel"); header("Content-disposition: attachment; filename=".($id?"$qFilename":"download.csv")); print $csv; ?>
<td> <fieldset style="width: 100%"> <legend><strong>REPEAT SAMPLE DETAILS</strong></legend> <div style="padding:5px 0px 0px 0px"> <table width="100%" border="0" class="vl"> <tr> <td width="30%" style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6">Scheduled for Repeat on</td> <td width="70%" style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6"><?php echo getFormattedDate($scheduledOn) . " at " . getFormattedTimeLessS($scheduledOn); ?> </td> </tr> <tr> <td style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6">Repeated on</td> <td style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6"><?php echo getFormattedDate($repeatedOn) . " at " . getFormattedTimeLessS($repeatedOn); ?> </td> </tr> <tr> <td style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6">Repeat Results</td> <td style="padding:4px 0px; border-bottom: 1px dashed #dfe6e6"><?php echo $repeatedResult; ?> </td> </tr> <tr> <td style="padding:4px 0px">Repeat Factor</td> <td style="padding:4px 0px">x<?php echo $repeatedFactor; ?>