Esempio n. 1
0
        public async Task <CustomError> AddHoliday(string name, string description, string destination, DateTime holidayDepartureDate)
        {
            Holiday holiday = new Holiday(name, description, destination, holidayDepartureDate);

            (Holiday h, CustomError c) = await HolidayService.AddHoliday(holiday);

            if (h.ID >= 0 && c.Message == null)
            {
                Holidays.Add(h);
            }

            return(c);
        }