Your IP : 216.73.216.40


Current Path : /var/www/html/mmishra/irp/istore/
Upload File :
Current File : /var/www/html/mmishra/irp/istore/inapproved.inc

<h2 align='left'>Approved Indents</h2>

<center>
<table width='90%' border='1' style='border-collapse: collapse'>
<tr><th>No.</th><th>Indent No.</th><th>Dated</th><th>Employee</th><th>Recommendation</th></tr>

<?php

$tbl = 'indents';
$indentno = $_REQUEST["indent_no"];

$rs = mysql_query("select * from $tbl where status='Approved' order by indent_no");
/* fetch values */
while ($o = mysql_fetch_object($rs)) {
	$i++;
	echo "<tr><td>$i</td>";

	if ($indentno == $o->indent_no) {
		echo "<td><b style='color: red'>$o->indent_no</b> <input type='hidden' name='indent_no' value='$o->indent_no'></td>";
	} else {
		echo "<td><a href='?pg=$pg&indent_no=$o->indent_no'>$o->indent_no</a></td>";
	}

	$status = $o->status;
	echo "<td>$o->indent_date</td><td>".employee_detail($o->employee)."</td><td>$o->recommendation</td></tr>";

	if ($indentno == $o->indent_no) {
		echo "<tr><th colspan='6' align='center'>
		<font color='red' size=+1>Particulars</font>
		<table width='90%' border='1' style='border-collapse: collapse'>
		<tr><th>No.</th><th>Indent Items</th><th>Qty Demand</th><th>Qty Out</th><th>Qty Approve</th><th>Approx Cost</th></tr>";

		$sr = mysql_query("select * from indent_items where indent_no=$indentno order by item");
		/* fetch values */
		while ($q = mysql_fetch_object($sr)) {
			$j++;
			echo "<tr><td>$j <input type='hidden' name='item[]' value='$q->item'></td>
			<td>".item_detail($q->item)."</td><td>$q->qty_demand</td><td>$q->qty_out</td>
			<td>$q->qty_approve</td><td>$q->approx_cost <input type='hidden' name='id[]' value='$q->id'></td></tr>";
		}
		echo "</table>
		</th></tr>";
	}
}
?>

</table>
</center>