public async void LoadData() { try { _allNamedays = await NamedayRepository.GetAllNamedaysAsync(); PerformFiltering(); LoadingState = LoadingStates.Loaded; } catch { LoadingState = LoadingStates.Error; } var now = DateTime.Now; SelectedNameday = _allNamedays.FirstOrDefault( d => d.Day == now.Day && d.Month == now.Month); }
private async void LoadData() { try { _allNamedays = await NamedayRepository.GetAllNamedaysAsync(); PerformFiltering(); LoadingState = LoadingStates.Loaded; } catch { LoadingState = LoadingStates.Error; } // get current nameday var now = DateTime.Now; SelectedNameday = _allNamedays.FirstOrDefault(n => n.Day == now.Day && n.Month == now.Month); }
public async void LoadData() { _allNamedays = await NamedayRepository.GetAllNamedaysAsync(); PerformFiltering(); }