Your IP : 216.73.216.40


Current Path : /var/www/html/mmishra/iws8/html/mcell/backup/
Upload File :
Current File : /var/www/html/mmishra/iws8/html/mcell/backup/right.php

<?php
include "page_header.inc";
//include "admin/stock_update.inc";
?>
<b>STOCK SUMMARY</b>
<center>
<table id='orange_box'>
<tr><th>No.</th><th nowrap>Items</th><th>Stock<br>Qty</th><th>Issued<br>Qty</th><th>Scrap<br>Qty</th></tr>

<?php
$sql = "select description, stock_quantity as qty1, issued_quantity as qty2, scrap_quantity as qty3, total_cost as tcost from category_master order by description";
$result = mysql_query($sql, $link_id);
$i=0;
while ($query_data = mysql_fetch_array($result)){
  $i++;
  $description = $query_data["description"];
  //$model_make = $query_data["model_make"];
  $qty1 = $query_data["qty1"];
  $qty2 = $query_data["qty2"];
  $qty3 = $query_data["qty3"];
//  $cost = $query_data["tcost"];
  echo "<tr id='";
  if ($i % 2) echo "row1'>"; else echo "row2'>";
  echo "<td>$i</td>";
  echo "<td>$description</td><td align='center'>$qty1</td><td align='center'>$qty2</td><td align='center'>$qty3</td></tr>";
//<td align='right' nowrap>$cost</td></tr>";
//  $tcost += $cost;
  $tqty1 += $qty1;
  $tqty2 += $qty2;
  $tqty3 += $qty3;
}
$tcost = number_format($tcost, 2);
echo "<tr><th colspan='2'>Total</th><th>$tqty1</th><th>$tqty2</th><th>$tqty3</th></tr>";
//<th align='right' nowrap>$tcost</th></tr>";
echo "</table><p>";
?>

<pre>




</pre>
<?php
include "page_footer.inc";
?>