| Current Path : /var/www/html/mmishra/istore/staff/ |
| Current File : /var/www/html/mmishra/istore/staff/materialstatus.inc |
<h2 align='left'>Material Status</h2>
<table width='95%' border='1' style='border-collapse: collapse'>
<tr><th>Sr</th><th>Item Name</th><th>Specification</th><th>Opening<br>Stock</th><th>Received<br>Qty</th><th>Total<br>Qty</th><th>Issued<br>Qty</th>
<th>Balance<br>Qty</th><th>Closing<br>Stock</th><th>Dated</th></tr>
<?php
$tbl = 'stockbook';
$pgno = $_REQUEST["pgno"];
if (!$pgno) $pgno = 0;
$pgsz = 30;
$i = $pgno;
$rs = mysql_query("select * from $tbl order by item_name limit $pgno,$pgsz");
/* fetch values */
while ($o = mysql_fetch_object($rs)) {
$i++;
echo "<tr><td>$i</td>
<td><a href='staff/?pg=$pg&item_no=$o->item_no'>$o->item_name</a></td>
<td>$o->specification</td>
<td>$o->opening_stock</td>
<td>$o->received_qty</td>
<td>$o->total_qty</td>
<td>$o->issued_qty</td>
<td>$o->balance_qty</td>
<td>$o->closing_stock</td>
<td>$o->date_updation</td></tr>";
}
?>
</table>
<?php
if ($pgno) {
$pgno = $pgno - $pgsz;
echo "[ <a href='staff/?pg=$pg&pgno=$pgno'>Previous</a> ] ";
$pgno = $pgno + $pgsz;
}
if ($j % $pgsz == 0) {
$pgno = $pgno + $pgsz;
echo " [ <a href='staff/?pg=$pg&pgno=$pgno'>Next</a> ]";
}
?>