<!--#include file="../Include/Conno.asp" --><!--#include file="../Include/function.asp" --><!--#include file="../sql/Neeao_SqlIn.Asp" -->
<%
  if Request.ServerVariables("REQUEST_METHOD") = "POST" then
    dim rs,mSql
    set rs=Server.CreateObject("Adodb.recordset")
    mSql="Select * From Plane_OrderTicket"
    rs.Open mSql,conn,1,3
    rs.AddNew
    rs("F_RealName")=Trim(Request.Form("txtRealName"))
    rs("F_Berth")=Trim(Request.Form("radBerth"))
    rs("F_Tel")=Trim(Request.Form("txtTel"))
    'rs("F_Mobile")=Trim(Request.Form("txtMobile"))
    rs("F_Address")=Trim(Request.Form("txtAddress"))
  
    rs("F_Year")=Trim(Request.Form("txtYear"))
    rs("F_Month")=Trim(Request.Form("selMonth"))
    rs("F_Day")=Trim(Request.Form("selDay"))
    rs("F_Week")=Trim(Request.Form("selWeek"))
  
    rs("F_IDCard")=Trim(Request.Form("txtIDCard"))
    rs("F_Email")=Trim(Request.Form("txtEmail"))
 
 ' if Request.form("chkInsurance")=0 then
 '   rs("F_IsInsurance")=0
 '	else
 '   rs("F_IsInsurance")=1
 ' end if	
 
    rs("F_Memo")=Trim(Request.Form("memMemo"))
    rs("F_TakeOffTime")=Trim(Request.Form("hidTakeOffTime"))
    rs("F_ArriveTime")=Trim(Request.Form("hidArriveTime"))
    rs("F_Price")=Trim(Request.Form("hidOldPrice"))
    dim mPrice
    mPrice=cint(Request.Form("hidNewPrice"))
    if Request.Form("radBerth")="商务舱" then mPrice=mPrice+mPrice*0.3
    if Request.Form("radBerth")="头等舱" then mPrice=mPrice+mPrice*0.5
    rs("F_OrderNumber")=cint(Trim(Request.Form("txtOrderNumber")))
    rs("F_TotalAmount")=mPrice*cint(Trim(Request.Form("txtOrderNumber")))
    rs("F_StartStation")=Trim(Request.Form("hidStartStation"))
    rs("F_EndStation")=Trim(Request.Form("hidEndStation"))
    rs("F_PlaneType")=Trim(Request.Form("hidPlaneType"))
    rs("F_SFNumber")=Trim(Request.Form("hidSFNumberID"))
    rs("F_Addtime")=now
    rs.update
    rs.close
	set rs = nothing
	call msgbox("恭喜你，机票订购成功！",2)
  end if
%>