Exemple #1
0
        public void Flights([FromBody] List <Flight> fl)
        {
            Console.WriteLine("{0,6}   |{1,6}   |{2,6}   |{3,6}   |{4,6}   |{5,10}   |", "Flight", "From", "To", "Departure", "Arrival", "Status");
            Console.WriteLine("-----------------------------------------------------------------------------");
            foreach (var item in fl)
            {
                db.AddFlight(item);

                Console.WriteLine("{0,10}   |{1,10}   |{2,10}   |{3,10}   |{4,10}   |{5,10}", item.Id, item.From, item.To, item.TimeStart, item.TimeStop, item.TimeStop);
            }
            Console.WriteLine("Get schedule.");
        }
Exemple #2
0
        public void Flights([FromBody] List <Flight> fl)
        {
            Console.WriteLine("{0,6}   |{1,6}   |{2,6}   |{3,6}   |{4,6}   |{5,10}   |", "Рейс", "Откуда", "Куда", "Время вылета", "Время прилета", "Статус");
            Console.WriteLine("-----------------------------------------------------------------------------");
            foreach (var item in fl)
            {
                db.AddFlight(item);
                Console.WriteLine("{0,10}   |{1,10}   |{2,10}   |{3,10}   |{4,10}   |{5,10}", item.Id, item.From, item.To, item.TimeStart, item.TimeStop, item.TimeStop);
            }

            Console.WriteLine("1");
        }