?
Current Path : /home1/savoy/www/savoyglobal.net/drafthr/system/application/views/Report/ |
Linux gator3171.hostgator.com 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 |
Current File : /home1/savoy/www/savoyglobal.net/drafthr/system/application/views/Report/dailyactivitypdf.php |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?> <?php if ($search == "") $search = 'search'; if($fromdate == '') $fromdate = 'fromdate'; if($todate=='') $todate = 'todate'; if(!$company) $images=base_url() .'logo/default_header.jpg'; else { foreach($company as $company) { $loggo=$company['filename']; $images=base_url() .'logo/'.$loggo; // echo $image; } } $cov=$this->mastermodel->get_data_srow('staffpersonaldetails',$search,'id'); $bran_id=$this->customermodel->getSingleFieldValue('customer_account','branch_id','customer_id',$search); $bra_name=$this->customermodel->getSingleFieldValue('ourbranch','branchname','id',$bran_id); $csv_output=''; $image = '<img src="'.$images.'" width="285px" height="100px">'; $bullet = '<img src="'.base_url().'/assets/images/li_bullet.jpg" align="bottom">'; $csv_output='<html><head><body style="margin: 20px 20px 30px 20px;"> <table width="100%" border="0" cellpadding="2" cellspacing="2"> <tr><td colspan="2" align="left">'.$image.'</td></tr></table><br/>'; $csv_output.='<div style="text-align:center"><b><u>DAILY ACTIVITY REPORT</u></b> </div><br/><br/>'; $csv_output.=" <table> <tr><td>Employee Name:</td><td>$cov->name</td></tr> <tr><td>Branch:</td><td>$bra_name</td></tr> <tr><td>Period:</td><td>"; if ($todate != 'todate'){ $csv_output .= "$fromdate to $todate"; } $csv_output.="</td> </tr> </table> <table width='100%' border='1' class='sort'><thead> <tr> <th style='background-color:#80C0FF;'>Sl No</th> <th style='background-color:#80C0FF;'>Date</th> <th style='background-color:#80C0FF;'>Time</th> <th style='background-color:#80C0FF;'>Customer Name</th> <th style='background-color:#80C0FF;'>Contact Person</th> <th style='background-color:#80C0FF;'>Designation</th> <th style='background-color:#80C0FF;'>Tel No</th> <th style='background-color:#80C0FF;'>Remarks</th> </tr>"; $i=1; foreach($viewinfo as $updata) { $csv_output .= "<tr> <td>".$i++."</td> <td>".$this->mastermodel->convdatformat($updata['date'])."</td> <td>".$updata['time']."</td> <td>".$updata['name']."</td> <td>".$updata['contact_person']."</td> <td>".$updata['designation']."</td> <td>".$updata['tel_no']."</td> <td>".$updata['remarks']."</td> </tr>"; } $csv_output .= "</table>"; $footer=$this->reportmodel->getfootervalue(); $csv_output.='<script type="text/php"> if ( isset($pdf) ) { $font = Font_Metrics::get_font("verdana", "normal"); $pdf->page_text(75, 570, "'.$footer.' Page {PAGE_NUM} of {PAGE_COUNT}", $font, 10, array(0,0,0)); } </script>'; $csv_output.='</body></head></html>'; //echo $html; pdf_create($csv_output, 'Daily-Activity','true'); ?>