Ejemplo n.º 1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                lblPrice.Text     = (String)Session["price"];
                lblDuration.Text  = (String)Session["duration"];
                lblDepart.Text    = (String)Session["pickUpAddress"];
                lblArrive.Text    = (String)Session["destination"];
                lblName.Text      = (String)Session["Username"];
                lblDriver.Text    = (String)Session["driverName"];
                lblVehicleNo.Text = functionReturnPlate();
                string transactionTime = DateTime.Now.ToString();
                //Label1.Text = transactionTime;

                RetrieveDataDataContext trans = new RetrieveDataDataContext();



                TRANSACTION2 order = new TRANSACTION2
                {
                    price       = Session["price"].ToString(),
                    email       = Session["Email"].ToString(),
                    paymentTime = Convert.ToDateTime(transactionTime)
                };

                RESERVATION reserve = new RESERVATION
                {
                    ReservationStartTime = Convert.ToDateTime(Session["reserveTime"]),
                    ReservationEndTime   = Convert.ToDateTime(Session["reachTime"]),
                    PickUpLocation       = (String)Session["pickUpAddress"],
                    Destination          = (String)Session["destination"],
                    Email    = (String)Session["Email"],
                    DriverID = (String)Session["driver"],
                    Price    = (String)Session["price"]
                };

                trans.RESERVATIONs.InsertOnSubmit(reserve);
                trans.TRANSACTION2s.InsertOnSubmit(order);
                trans.SubmitChanges();
            }
        }
Ejemplo n.º 2
0
 private void detach_RESERVATIONs(RESERVATION entity)
 {
     this.SendPropertyChanging();
     entity.MEMBER = null;
 }
Ejemplo n.º 3
0
 partial void DeleteRESERVATION(RESERVATION instance);
Ejemplo n.º 4
0
 partial void UpdateRESERVATION(RESERVATION instance);
Ejemplo n.º 5
0
 partial void InsertRESERVATION(RESERVATION instance);
Ejemplo n.º 6
0
 private void attach_RESERVATIONs(RESERVATION entity)
 {
     this.SendPropertyChanging();
     entity.DRIVER = this;
 }