<?php //include('includes/config/config.php'); // include('includes/functions.php'); //include('pop_up_top.php'); include('pdf_header.php'); ?> <link href="includes/css-js/admin.css" rel="stylesheet" type="text/css" /> <body> <table width="100%" > <tr><div style="font-size:12px"> <td width="25%" align="left"> Run Date : <?php echo date("d-M-Y"); ?></td> <td width="50%" align="center" style="font-size:40px"><strong>Expiry List</strong></td> <td width="25%" align="left"> User : <?php echo $username ?></td> </tr> </table> <table border="1" width="100%" style="margin-top:100px"> <tr bgcolor='#eeeeee'><th width="5%">Sr.</th><th align="center" width="40%">Item</th><th width="5%" align="center" >Qty</th><th align="center" width="5%">Batch</th><th align="center" width="10%">Expiry Date</th></tr> <?php $count=0; $sql_expiry_items="SELECT * from cleanup_item_stock a order by a.expiry_date desc"; error_log($sql_expiry_items . "query"); $results_expiry_items = mysqli_query($GLOBALS['conn'],$sql_expiry_items); error_log($GLOBALS['conn']); while ($row_expiry_items= mysqli_fetch_assoc($results_expiry_items)) { $id=$row_expiry_items['stock_expiry_hist_id']; $item_name = getTableFieldValue('tbl_items','item_name','item_id',$row_expiry_items['item_id']); $item_qty=$row_expiry_items['cleanup_qty']; $item_batch=$row_expiry_items['batch_no']; $item_expiry_date=date_format(date_create($row_expiry_items['expiry_date']),"M-Y "); $count=$count+1; ?><tr><td><center><?php echo $count?></center></td><td><?php echo $item_name ?></td><td><center><?php echo $item_qty?></center></td><td><center><?php echo $item_batch?></center></td><td><center><?php echo $item_expiry_date?></center></td></td><?php } ?> </table> <?php include('pdf_footer.php'); ?>