void NivelEstudios(DataUserResponse profile) { if (profile.data.id_nivel_estudios == null) { } else { pickernivelestudios.SelectedIndex = (int)profile.data.id_nivel_estudios; } }
void Working(DataUserResponse profile) { if (profile.data.trabaja == null || profile.data.trabaja == 0) { pickerjob.SelectedIndex = 2; } else { pickerjob.SelectedIndex = (int)profile.data.trabaja; } }
void Social(DataUserResponse profile) { if (profile.data.apoyo_proyectos_sociales == null || profile.data.apoyo_proyectos_sociales == 2) { pickersocial.SelectedIndex = 2; } else { pickersocial.SelectedIndex = 1; inputSocial.Text = profile.data.proyectos_sociales + ""; } }
void Trophy(DataUserResponse profile) { if (profile.data.premios == null || profile.data.premios == "") { pickerawards.SelectedIndex = 2; } else { pickerawards.SelectedIndex = 1; inputMention.Text = profile.data.premios + ""; } }
void Able(DataUserResponse profile) { if (profile.data.id_capacidad_diferente == null) { pickerhandicap.SelectedIndex = 2; } else { pickerhandicap.SelectedIndex = 1; pickerPhysic.SelectedIndex = (int)profile.data.id_capacidad_diferente; } }
void Etnia(DataUserResponse profile) { if (profile.data.id_pueblo_indigena == null) { pickerpopulation.SelectedIndex = 2; } else { pickerpopulation.SelectedIndex = 1; pickerEtnia.SelectedIndex = (int)profile.data.id_pueblo_indigena; } }
void Beneficiario(DataUserResponse profile) { if (profile.data.id_programa_beneficiario == null || profile.data.id_programa_beneficiario == 0) { pickerbeneficiario.SelectedIndex = 2; } else { pickerbeneficiario.SelectedIndex = 1; pickerEstado.SelectedIndex = (int)profile.data.id_programa_beneficiario; } }
void SetInfo(DataUserResponse profile) { _imageView.Source = profile.data.ruta_imagen; url = profile.data.ruta_imagen; NivelEstudios(profile); Beneficiario(profile); Working(profile); Etnia(profile); Able(profile); Trophy(profile); Social(profile); Idioms(profile); }
void Idioms(DataUserResponse profile) { if (profile.data.idiomas == null) { return; } if (profile.data.idiomas.Count == 0) { return; } if (HelperIdioma.InfioIdiomas.Count > 0) { HelperIdioma.InfioIdiomas.Clear(); } foreach (var idioma in profile.data.idiomas) { var infoIdioma = new InfoIdioma() { Nombre = getIdioma((int)idioma.id_idioma_adicional), id_datos_usuario = idioma.id_datos_usuario, id_idioma_adicional = idioma.id_idioma_adicional, lectura = idioma.lectura, escritura = idioma.escritura, conversacion = idioma.conversacion }; HelperIdioma.InfioIdiomas.Add(getIdioma((int)idioma.id_idioma_adicional), infoIdioma); } if (HelperIdioma.InfioIdiomas.Count > 0) { foreach (var keyPair in HelperIdioma.InfioIdiomas) { _idiomasStack.Children.Add(new IdiomaItemView(keyPair.Value)); } } }