Ejemplo n.º 1
0
        private void AddNewFlight()
        {
            TripModel newFlight = FlightsViewModel.CreateNewFlight();

            if (newFlight != null)
            {
                if (newFlight.DepOrArrFlag.Equals("departure"))
                {
                    Departures.Add(newFlight);
                    SelectedFlight = Departures.Last();
                }
                else if (newFlight.DepOrArrFlag.Equals("arrival"))
                {
                    Arrivals.Add(newFlight);
                    SelectedFlight = Arrivals.Last();
                }
            }
        }