Beispiel #1
0
 /// <summary>
 /// Loads data info to Gender combobox
 /// </summary>
 protected void PoblarDropGenero() {
     if (log.IsDebugEnabled) {
         log.Debug("PoblarDropGenero Starts");
     }
     Entidad daoEnt = new Entidad();
     List<EntidadDto> entityList = daoEnt.getValoresEntidad(Settings.SysParamGender);
     List<KeyValue> l = new List<KeyValue>();
     l.Add(new KeyValue() { key = "-1", value = "-- SELECCIONE --" });
     entityList.ForEach(t => l.Add(new KeyValue() { key = t.idEntidad.ToString(), value = t.valorEntidad }));
     listGenero.DataSource = l;
     listGenero.DataTextField = "value";
     listGenero.DataValueField = "key";
     listGenero.DataBind();
     if (log.IsDebugEnabled) {
         log.Debug("PoblarDropGenero Ends");
     }
 }
Beispiel #2
0
 /// <summary>
 /// Loads Departamentos in combo box.
 /// </summary>
 private void PoblarDepartamentos() {
     if (log.IsDebugEnabled) {
         log.Debug("PoblarDepartamentos Starts ");
     }
     Entidad daoEntity = new Entidad();
     List<EntidadDto> countyList = daoEntity.getValoresEntidad(Settings.SysParamEstate);
     List<KeyValue> l = new List<KeyValue>();
     l.Add(new KeyValue() { key = "-1", value = "-- SELECCIONE --" });
     countyList.ForEach(t => l.Add(new KeyValue { key = t.idEntidad.ToString(), value = t.valorEntidad }));
     listaDepartamentos.DataSource = l;
     listaDepartamentos.DataTextField = "value";
     listaDepartamentos.DataValueField = "key";
     listaDepartamentos.DataBind();
     if (log.IsDebugEnabled) {
         log.Debug("PoblarDepartamentos Ends ");
     }
 }