<?php 
include("../../include/dbconnect.php");
?>
<title> Sales Register 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>Sales Register  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,invno,invdate,compcode,prodcode,drawing_no,quantity,rate,value,packing_percent,packing_amt,bed,bed_amt,cess,cess_amt,vat_percent,vat_amount,freight,total,round_off,gtotal,invstatus,po_no,po_date,schedule_no,schedule_date,month,year,salesreg.taxtype,duty_posted,prepare_time,remove_time,account_year,hcess,hcess_amt from salesreg 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>Printing Status</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="invstatus" value = <?php echo("'$row1[21]'");?>>  </td></tr>

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

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

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

<tr><td bgcolor="#FFFFFF"><font class="sbd"><b>Product Code </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   maxlength=14 size="14" readonly name="prodcode" value = <?php echo("'$row1[4]'");?>></td></tr>

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

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Quantity </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   maxlength=8 size="10" name="quantity" value = <?php echo($row1[6]);?>></td></tr>

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Rate  </b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   maxlength=8 size="10" name="rate" value = <?php echo($row1[7]);?>></td></tr>

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

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

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

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


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

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

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

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

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

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

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

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

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

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

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



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

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

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

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

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

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

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

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

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

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

<tr><td  bgcolor="#FFFFFF"><font class="sbd"><b>Account Year</b></font></td><td  bgcolor="#FFFFFF">
<input type="text"    onKeyPress="return event.keyCode!=13"   size="40" name="account_year" value = <?php echo("'$row1[32]'");?>>  </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>
