Ejemplo n.º 1
0
        protected async override void OnAppearing()
        {
            base.OnAppearing();
            if (viewModel.IsInitialized)
            {
                return;
            }

            viewModel.IsInitialized = true;
            await viewModel.ExecuteLoadConferencesCommand();

            masterPicker.Items.Clear();
            foreach (var item in viewModel.MasterConferences)
            {
                masterPicker.Items.Add(item.Name);
            }

            var master = viewModel.MasterConferences.FirstOrDefault(c => c.MasterConferenceId == Settings.MasterConference);

            if (master != null)
            {
                masterPicker.SelectedIndex = viewModel.MasterConferences.IndexOf(master);
            }
        }