private async void GetEventsCommandAction()
 {
     Events = await _voucherService.GetEvents() ?? new List <Models.Event>()
     {
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         },
         new Models.Event()
         {
             Name = "Ev1"
         }
     };
 }
Example #2
0
        private async void GetEventsCommandAction(bool updateFromServer)
        {
            var events = await _voucherService.GetEvents(updateFromServer);

            if (events == null)
            {
                Events = new List <Event>();
            }
            else
            {
                Events = events;
            }
        }