Ejemplo n.º 1
0
        protected void gvAirCarriers_SelectedIndexChanged(object sender, EventArgs e)
        {
            AirSVC.AirCarrier objAirCarrier = new AirSVC.AirCarrier();
            string            carrierName   = gvAirCarriers.SelectedRow.Cells[1].Text;

            if (carrierName == "American Airlines")
            {
                objAirCarrier.AirCarrierID = 1;
            }
            else if (carrierName == "Delta Air Lines")
            {
                objAirCarrier.AirCarrierID = 2;
            }
            else
            {
                objAirCarrier.AirCarrierID = 3;
            }
            gvFlights.DataSource = pxyAir.GetFlights(objAirCarrier, ddlCity.SelectedValue, ddlState.SelectedValue, ddlCity2.SelectedValue, ddlState2.SelectedValue);
            gvFlights.DataBind();
            lbldirection2.Visible  = true;
            btnFilter.Visible      = true;
            ddlSeatingType.Visible = true;
            chkboxNonStop.Visible  = true;
            lblDirection3.Visible  = true;
            lblSeatingType.Visible = true;
        }
Ejemplo n.º 2
0
        protected void btnFilter_Click(object sender, EventArgs e)
        {
            AirSVC.AirCarrier objAirCarrier = new AirSVC.AirCarrier();
            string            carrierName   = gvAirCarriers.SelectedRow.Cells[1].Text;

            if (carrierName == "American Airlines")
            {
                objAirCarrier.AirCarrierID = 1;
            }
            else if (carrierName == "Delta Air Lines")
            {
                objAirCarrier.AirCarrierID = 2;
            }
            else
            {
                objAirCarrier.AirCarrierID = 3;
            }

            AirSVC.FlightRequirement objFlightRequirement = new AirSVC.FlightRequirement();
            objFlightRequirement.Nonstop     = chkboxNonStop.Checked;
            objFlightRequirement.SeatingType = ddlSeatingType.SelectedValue;

            gvFlights.DataSource = pxyAir.FilterFlightsByCarrier(objAirCarrier, objFlightRequirement, ddlCity.SelectedValue, ddlState.SelectedValue, ddlCity2.SelectedValue, ddlState2.SelectedValue);
            gvFlights.DataBind();
        }
Ejemplo n.º 3
0
 public System.Data.DataSet GetFlights(AirCarrier airCarrierID, string departureCity, string departureState, string arrivalCity, string arrivalState)
 {
     object[] results = this.Invoke("GetFlights", new object[] {
         airCarrierID,
         departureCity,
         departureState,
         arrivalCity,
         arrivalState
     });
     return((System.Data.DataSet)(results[0]));
 }
Ejemplo n.º 4
0
 public bool Reserve(AirCarrier airCarrierObj, Flight flightObj, Customer custObj, string travelSiteID, string travelSitePassword)
 {
     object[] results = this.Invoke("Reserve", new object[] {
         airCarrierObj,
         flightObj,
         custObj,
         travelSiteID,
         travelSitePassword
     });
     return((bool)(results[0]));
 }
Ejemplo n.º 5
0
 public System.Data.DataSet FilterFlightsByCarrier(AirCarrier airCarrierID, FlightRequirement requirements, string departureCity, string departureState, string arrivalCity, string arrivalState)
 {
     object[] results = this.Invoke("FilterFlightsByCarrier", new object[] {
         airCarrierID,
         requirements,
         departureCity,
         departureState,
         arrivalCity,
         arrivalState
     });
     return((System.Data.DataSet)(results[0]));
 }
Ejemplo n.º 6
0
 /// <remarks/>
 public void ReserveAsync(AirCarrier airCarrierObj, Flight flightObj, Customer custObj, string travelSiteID, string travelSitePassword, object userState)
 {
     if ((this.ReserveOperationCompleted == null))
     {
         this.ReserveOperationCompleted = new System.Threading.SendOrPostCallback(this.OnReserveOperationCompleted);
     }
     this.InvokeAsync("Reserve", new object[] {
         airCarrierObj,
         flightObj,
         custObj,
         travelSiteID,
         travelSitePassword
     }, this.ReserveOperationCompleted, userState);
 }
Ejemplo n.º 7
0
 /// <remarks/>
 public void GetFlightsAsync(AirCarrier airCarrierID, string departureCity, string departureState, string arrivalCity, string arrivalState, object userState)
 {
     if ((this.GetFlightsOperationCompleted == null))
     {
         this.GetFlightsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetFlightsOperationCompleted);
     }
     this.InvokeAsync("GetFlights", new object[] {
         airCarrierID,
         departureCity,
         departureState,
         arrivalCity,
         arrivalState
     }, this.GetFlightsOperationCompleted, userState);
 }
Ejemplo n.º 8
0
 /// <remarks/>
 public void FilterFlightsByCarrierAsync(AirCarrier airCarrierID, FlightRequirement requirements, string departureCity, string departureState, string arrivalCity, string arrivalState, object userState)
 {
     if ((this.FilterFlightsByCarrierOperationCompleted == null))
     {
         this.FilterFlightsByCarrierOperationCompleted = new System.Threading.SendOrPostCallback(this.OnFilterFlightsByCarrierOperationCompleted);
     }
     this.InvokeAsync("FilterFlightsByCarrier", new object[] {
         airCarrierID,
         requirements,
         departureCity,
         departureState,
         arrivalCity,
         arrivalState
     }, this.FilterFlightsByCarrierOperationCompleted, userState);
 }
Ejemplo n.º 9
0
 /// <remarks/>
 public void ReserveAsync(AirCarrier airCarrierObj, Flight flightObj, Customer custObj, string travelSiteID, string travelSitePassword)
 {
     this.ReserveAsync(airCarrierObj, flightObj, custObj, travelSiteID, travelSitePassword, null);
 }
Ejemplo n.º 10
0
 /// <remarks/>
 public void FilterFlightsByCarrierAsync(AirCarrier airCarrierID, FlightRequirement requirements, string departureCity, string departureState, string arrivalCity, string arrivalState)
 {
     this.FilterFlightsByCarrierAsync(airCarrierID, requirements, departureCity, departureState, arrivalCity, arrivalState, null);
 }
Ejemplo n.º 11
0
 /// <remarks/>
 public void GetFlightsAsync(AirCarrier airCarrierID, string departureCity, string departureState, string arrivalCity, string arrivalState)
 {
     this.GetFlightsAsync(airCarrierID, departureCity, departureState, arrivalCity, arrivalState, null);
 }