<?php  include("../../include/dbconnect.php");?>
<?
//if ( isset($submit) && $submit == "submit")
//{
$quot_refdt = substr($sdt,6,4).'/'.substr($sdt,3,2).'/'.substr($sdt,0,2);
$yr_refdt = substr($ydt,6,4).'/'.substr($ydt,3,2).'/'.substr($ydt,0,2);

//echo "rec" . "$record";
//echo "for enquiry, cost sheet and quotatino";

$query = "insert into quotation (bcode, quot_refno, quot_refdt, attn, yr_refno, yr_refdt, enqrefno, enqrefdt, prodcode, drawing_no, prodname, rawoffer, rawwgt, rawrate, rawcost, invper, invcost, processcost, admnexp, scrapcost, tlcost, delperiod, st, exduty, pandf, payterms, price, subtot, tot, account_year, record) values('$bcode', '$quot_refno', '$quot_refdt', '$attn', '$yr_refno', '$yr_refdt', '$enqrefno', '$enqrefdt', '$prodcode', '$drawing_no', '$prodname', '$rawoffer',  '$rawwgt', '$rawrate', '$rawcost', '$invper', '$invcost', '$processcost', '$admnexp', '$scrapcost', '$tlcost', '$delperiod', '$st', '$exduty', '$pandf', '$payterms', '$price', '$subtot', '$tot', '$account_year', NULL)";


//echo "$query";	
mysql_query($query) or die (mysql_error());


$result1=mysql_query("update enquiry set quot_refno='$quot_refno', quot_refdt='$quot_refdt', tools_cost='$tlcost' where record='$rec'") or   die(mysql_error());

//}
?>
<meta http-equiv="refresh" content="0 url=index.html">
</body>





