/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// protected void btn_Submit_Click(object sender, EventArgs e) { long TransectionCounter = GTICKBOL.TransactionCounter_Max(); Session[TransectionCounter.ToString()] = TransectionCounter; Session["play_Val"] = ddl_Play.SelectedValue; Session["play_Val_Location"] = ddl_Location.SelectedItem; Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + "JHUMROOOFFER" + "," + "" + "," + TransectionCounter;; Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Render Seat Layout for " + Session_value); GTICKBOL.Insert_ShowDetail(Session_value, TransectionCounter); Session["a" + "JHUMROOOFFER"] = ""; Response.Redirect("Seat-Layout.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()), false); }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// protected void btn_Submit_Click(object sender, EventArgs e) { long TransectionCounter = GTICKBOL.TransactionCounter_Max(); Session[TransectionCounter.ToString()] = TransectionCounter; if (Request.QueryString["Router"] == "" || Request.QueryString["Router"] == null) { Session["Router"] = ""; } else if (Request.QueryString["Router"] != "buzzintown") { Session["Router"] = ""; } else { Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Booking Through" + Request.QueryString["Router"].ToString()); Session["Router"] = Request.QueryString["Router"].ToString(); } //***************if routed from other website***************** //**************************************************************** Session["play_Val"] = ddl_Play.SelectedValue; Session["play_Val_Location"] = ddl_Location.SelectedItem; Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + "OCTOBERFEST" + "," + "" + "," + TransectionCounter;; Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Render Seat Layout for " + Session_value); GTICKBOL.Insert_ShowDetail(Session_value, TransectionCounter); if (Request.QueryString["Router"] == "buzzintown") { Session["a" + "OCTOBERFEST"] = ""; Response.Redirect("Seat-Layout.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()) + "&Router=" + Request.QueryString["Router"], false); } else { Session["a" + "OCTOBERFEST"] = ""; Response.Redirect("Seat-Layout.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()), false); } }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// protected void btn_Submit_Click(object sender, EventArgs e) { long TransectionCounter = GTICKBOL.TransactionCounter_Max(); Session[TransectionCounter.ToString()] = TransectionCounter; //***************if routed from other website***************** if (Request.QueryString["Router"] == "" || Request.QueryString["Router"] == null) { Session["Router"] = ""; } else if (Request.QueryString["Router"] != "buzzintown" && Request.QueryString["Router"] != "airfaresau") { Session["Router"] = ""; } else { Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Booking Through" + Request.QueryString["Router"].ToString()); Session["Router"] = Request.QueryString["Router"].ToString(); } //**************************************************************** Session["play_Val"] = ddl_Play.SelectedValue; Session["play_Val_Location"] = ddl_Location.SelectedItem; if (promotions == false) { Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + "" + "," + "" + "," + TransectionCounter;; Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Render Seat Layout for " + Session_value); } else { KoDTicketingLibrary.DTO.Promotion PromoSession = (KoDTicketingLibrary.DTO.Promotion)Session["a" + Decrypt(Request.QueryString["promo"])]; if (package == false) { Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + PromoSession.PromotionCode.ToString().ToUpper() + "," + "" + "," + TransectionCounter; } else { //Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + // "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + // "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + PromoSession.PromotionCode.ToString().ToUpper() + "," + Session["Package"].ToString() + "," + TransectionCounter; Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + ddl_Category.SelectedItem.Text + "," + PromoSession.PromotionCode.ToString().ToUpper() + "," + Session["Package"].ToString() + "," + TransectionCounter; } Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Render Seat Layout for " + Session_value); } if (Session["Hotel"] == null) { Session["Hotel"] = ""; } GTICKBOL.Insert_ShowDetail(Session_value, TransectionCounter); KoDTicketing.GTICKV.LogEntry(TransectionCounter.ToString(), "User Try to move from Default to Seat layout Page.", "1", ""); if (Request.QueryString["Router"] == "buzzintown" || Request.QueryString["Router"] == "airfaresau") { Response.Redirect("Seat-Layout.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()) + "&Router=" + Request.QueryString["Router"], false); } else { if (Request.QueryString["promo"] != null) { Session["a" + Decrypt(Request.QueryString["promo"])] = ""; } Response.Redirect("Seat-Layout.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()), false); } }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// protected void btn_Submit_Click(object sender, EventArgs e) { long TransectionCounter = GTICKBOL.TransactionCounter_Max(); Session[TransectionCounter.ToString()] = TransectionCounter; //***************if routed from other website***************** if (Request.QueryString["Router"] == "" || Request.QueryString["Router"] == null) { Session["Router"] = ""; } else if (Request.QueryString["Router"] != "buzzintown" && Request.QueryString["Router"] != "airfaresau") { Session["Router"] = ""; } else { Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Booking Through" + Request.QueryString["Router"].ToString()); Session["Router"] = Request.QueryString["Router"].ToString(); } //**************************************************************** Session["play_Val"] = ddl_Play.SelectedValue; Session["play_Val_Location"] = ddl_Location.SelectedItem; string Category_SelectedItem = ""; if (ddl_Category.SelectedItem.Text == "CHILD, Rs. 2999") { Category_SelectedItem = "COPPER, Rs. 2999"; } else if (ddl_Category.SelectedItem.Text == "SINGLE, Rs. 6999") { Category_SelectedItem = "GOLD, Rs. 6999"; } else if (ddl_Category.SelectedItem.Text == "COUPLE, Rs. 11999") { Category_SelectedItem = "PLATINUM, Rs. 11999"; } else if (ddl_Category.SelectedItem.Text == "TEEN, Rs. 3999") { Category_SelectedItem = "SILVER, Rs. 3999"; } Session_value = ddl_Location.SelectedValue + "," + ddl_Play.SelectedValue + "," + Convert.ToDateTime(dateofshow.Text.ToString()).ToString("dd/MM/yyyy") + "," + ddl_ShowTimes.SelectedValue + "," + ddl_Category.SelectedValue + "," + drp_TotalSeats.SelectedValue + "," + ddl_Location.SelectedItem.Text + "," + ddl_ShowTimes.SelectedItem.Text + "," + Category_SelectedItem + "," + "" + "," + "" + "," + TransectionCounter; Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Render Seat Layout for " + Session_value); GTICKBOL.Insert_ShowDetail(Session_value, TransectionCounter); DataTable dt_NewyearSeat = GTICKBOL.Select_NewYearSeat(ddl_ShowTimes.SelectedValue, TransectionCounter, Convert.ToInt32(drp_TotalSeats.SelectedValue)); string seatinfonewyear = ""; foreach (DataRow row in dt_NewyearSeat.Rows) { seatinfonewyear += row[0] + ","; } if (dt_NewyearSeat != null) { GTICKBOL.Insert_SeatInfo(seatinfonewyear.TrimEnd(','), TransectionCounter); } if (Request.QueryString["Router"] == "buzzintown" || Request.QueryString["Router"] == "airfaresau") { Response.Redirect("ContactDetails.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()) + "&Router=" + Request.QueryString["Router"], false); } else { Response.Redirect("ContactDetails.aspx?SessionId=" + Encrypt(TransectionCounter.ToString()), false); } }
protected void btnProceed_Click(object sender, EventArgs e) { if (Session["seat_Val"] != null) { try { string[] date = Session["seat_Val"].ToString().Split(','); if (date.Length < 4) { String err = "Cannot render seat layour because seat selection in Session invalid or expired. Session: " + Session["seat_Val"].ToString(); Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write(err); throw new Exception(err); } else { string filmCode = date[3].ToString(); string[] confimseats = hidtempseats.Value.Split('|'); int totalSeats = int.Parse(confimseats[0]); string strchktempseat = "", Seat_info = ""; for (int u = 0; u < totalSeats; u++) { strchktempseat += confimseats[2 + u].Split('_')[0] + ","; Seat_info += confimseats[2 + u].Split('_')[1] + ","; } string SeatNo = strchktempseat.TrimEnd(','); int status; TransactionRecord _tr = new TransactionRecord(); //assign filmCode from Session _tr.Play = filmCode; _tr.TotalSeats = totalSeats; //Generate Transaction ID _tr.SeatInfo = SeatNo; _tr.BookingID = GTICKBOL.TransactionCounter_Max(); status = GTICKBOL.Check_Seats_BeforeProceed(_tr); if (status == 0) { KoDTicketing.GTICKV.LogEntry(_tr.BookingID.ToString(), "User Detail > " + Session["seat_Val"].ToString() + ", Browser Version : " + HiddenBrowser.Value, "1", ""); KoDTicketing.GTICKV.LogEntry(_tr.BookingID.ToString(), "Checking Seats Availability", "2", ""); ClientScript.RegisterStartupScript(GetType(), "myscript", "<script>alert('The seats you have selected are not available at this time, please select different seats');</script>"); Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Setting up the seat layout again as the selected seats are not available. Session : " + Session["seat_Val"].ToString()); set_seatLayout(); return; } else { KoDTicketing.GTICKV.LogEntry(_tr.BookingID.ToString(), "Seats are available.", "3", ""); Session["Seat_info"] = Seat_info.TrimEnd(','); Session["Seat_TransactionID"] = _tr.BookingID; Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Request Contact Details for Transaction... : " + Session["Seat_TransactionID"].ToString()); Response.Redirect("ContactDetails.aspx", false); } } } catch (Exception ex) { Microsoft.Practices.EnterpriseLibrary.Logging.Logger.Write("Seat Layout Page Error: " + ex.Message); Session.Abandon(); ClientScript.RegisterStartupScript(GetType(), "myscript", "<script>alert('Session Timeout. Please start" + " the transaction again');window.location.href='TicketBooking.aspx';</script>"); } } }