/// <summary> /// Obteners the valores pantalla. /// </summary> /// <returns></returns> private Excursion ObtenerValoresDePantalla() { Excursion evento = new Excursion(); evento = propEvento; if (!esNuevo) { evento.idAgendaActividad = propAgenda.idAgendaActividad; evento.idEventoAgenda = propEvento.idEventoAgenda; } evento.fechaEvento = Convert.ToDateTime(calFechaEvento.ValorFecha); evento.horaDesde = Convert.ToDateTime(txtHoraDesdeEdit.Text.Trim()); evento.horaHasta = Convert.ToDateTime(txtHoraHastaEdit.Text.Trim()); evento.destino = txtDestinoEdit.Text.Trim(); evento.descripcion = txtDescripcionEdit.Text.Trim(); evento.activo = chkActivoEdit.Checked; evento.usuario.username = ObjSessionDataUI.ObjDTUsuario.Nombre; evento.fechaAlta = DateTime.Now; return evento; }
/// <summary> /// Buscars the filtrando. /// </summary> private void BuscarFiltrando() { calfechas.ValidarRangoDesdeHasta(false); Excursion evento = new Excursion(); evento.activo = chkActivo.Checked; evento.fechaEventoDesde = Convert.ToDateTime(calfechas.ValorFechaDesde); evento.fechaEventoHasta = Convert.ToDateTime(calfechas.ValorFechaHasta); if (txtHoraDesdeEdit.Text.Trim().Length > 1) evento.horaDesde = Convert.ToDateTime(txtHoraDesdeEdit.Text); if (txtHoraHastaEdit.Text.Trim().Length > 1) evento.horaHasta = Convert.ToDateTime(txtHoraHastaEdit.Text); propFiltroEvento = evento; BuscarAgenda(evento); }
/// <summary> /// Cargars the lista. /// </summary> /// <param name="evento">The evento.</param> private void CargarLista(Excursion evento) { objBLAgenda = new BLAgendaActividades(); evento.idAgendaActividad = propAgenda.idAgendaActividad; listaEventos = objBLAgenda.GetExcursionesAgenda(evento); }
/// <summary> /// Buscars the eventos. /// </summary> /// <param name="evento">The evento.</param> private void BuscarAgenda(Excursion evento) { CargarLista(evento); CargarGrilla(); }