<?php 
include("../../include/dbconnect.php");
?>
<title> Requirement details edit</title>
<body bgcolor="#ffffff"  topmargin=0>
<center>
<table cellpadding=0 cellspacing=4 width=590>
<tr>
<td style="padding:3px;" colspan=2 bgcolor="#93BEE2"><font ><b>Requirement  details edit</b></font></td>
</tr><tr valign="top"><td colspan=2>
<font >&nbsp;</font>
</td>
</tr>
</table>
<table border=0 cellpadding=3 cellspacing=4 width="590">
<form name="form1" method="POST"  action="update.php?record=<?echo($record);?>">
<?php 

$result=mysql_query("select record,qty,date,used_for,req_date,remarks,approved,app_date,approved_by,received_qty,po_prepared,indent_no,pur_ref,account_year,approved_qty,po_issued_qty,unit from matindent where record = '$record' ") or die(mysql_error());
$row1=mysql_fetch_row($result);
?>

<table border="0" cellspacing="1" cellpadding="4" align="center" width="500" bgcolor="#999999">
        

<input type="hidden" name="record" value="<? echo($row1[0]); ?>">

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Indent No</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="indent_no" value = <?php echo("'$row1[11]'");?>>  </td></tr>

<tr><td bgcolor="#FFFFFF"><font class="sbd"><b>Date of Indent </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   maxlength=12 size="10" name="date" value = <?php echo("'$row1[2]'");?>></td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Purchase Reference</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="pur_ref" value = <?php echo("'$row1[12]'");?>>  </td></tr>


<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Req. Qty </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="qty" value = <?php echo("'$row1[1]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Unit </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="unit" value = <?php echo("'$row1[15]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Used For  </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   maxlength=200 size="40" name="used_for" value = <?php echo($row1[3]);?>></td></tr>


<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Qty Required on</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="req_date" value = <?php echo("'$row1[4]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Specifications if any</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="remarks" value = <?php echo("'$row1[5]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Approved Status</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="approved" value = <?php echo("'$row1[6]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Approved Qty</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="approved_qty" value = <?php echo("'$row1[14]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>PO Issued Qty</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="po_issued_qty" value = <?php echo("'$row1[15]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Approved Date</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="app_date" value = <?php echo("'$row1[7]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Approved By</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="approved_by" value = <?php echo("'$row1[8]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Received Qty</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="received_qty" value = <?php echo("'$row1[9]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>P O Prepared</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="po_prepared" value = <?php echo("'$row1[10]'");?>>  </td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Accounting Year</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="11" name="account_year" value = <?php echo("'$row1[13]'");?>>  </td></tr>

<tr>
<td align=right>
 <blockquote>  <input  type =submit name=submit value = "Update"></td> <td><input type =submit name=submit value = "Delete"></blockquote>
</table>

<br><br><font size=1><center><a href= "index.html">Return to index page</center></font>
</body>
</form>
