Beispiel #1
0
        public DsReporteCantidadGuiasDigitalizadas GetGuiasDigitalizadasDetallado()
        {
            DsReporteCantidadGuiasDigitalizadas ds = new DsReporteCantidadGuiasDigitalizadas();
            SqlParameter pTipoGuia     = new SqlParameter("@TipoGuia", TipoGuia);
            SqlParameter pFechaDesde   = new SqlParameter("@FechaDesde", FechaDesde);     // Utiles.BaseDatos.FechaToSql(FechaDesde));
            SqlParameter pFechaHasta   = new SqlParameter("@FechaHasta", FechaHasta);     // Utiles.BaseDatos.FechaToSql(FechaHasta));
            SqlParameter pNroCajaDesde = new SqlParameter("@NroCajaDesde", NroCajaDesde); // Utiles.BaseDatos.IntToSql(NroCajaDesde));
            SqlParameter pNroCajaHasta = new SqlParameter("@NroCajaHasta", NroCajaHasta); // Utiles.BaseDatos.IntToSql(NroCajaHasta));
            SqlParameter pNroLoteDesde = new SqlParameter("@NroLoteDesde", NroLoteDesde); // Utiles.BaseDatos.IntToSql(NroLoteDesde));
            SqlParameter pNroLoteHasta = new SqlParameter("@NroLoteHasta", NroLoteHasta); // Utiles.BaseDatos.IntToSql(NroLoteHasta));
            SqlParameter pCliente      = new SqlParameter("@Clientes", Clientes);

            Config.Conexion.LlenarTypeDataSet(ds.Detalle, System.Data.CommandType.StoredProcedure, "GuiasDigitalizadasDetalleSel", pTipoGuia, pFechaDesde, pFechaHasta, pNroCajaDesde, pNroCajaHasta, pNroLoteDesde, pNroLoteHasta, pCliente);
            return(ds);
        }
        private void BindGridDetallado()
        {
            SisPackController.AdministrarGrillas.Configurar(dtgDetallado, "CajaID", this.CantidadOpciones);

            IReporteCantidadGuiasDigitalizadas oReporte = ReporteCantidadGuiasDigitalizadasFactory.GetReporteCantidadGuiasDigitalizadas();

            oReporte.Clientes     = getListaCliente(chkClientesTodos, lstClientes);
            oReporte.FechaDesde   = this.txtFecha.Text != "" ? Utiles.Fechas.FormatFechaDDMMYYYY(this.txtFecha.Text) : Utiles.Fechas.FormatFechaDDMMYYYY("01/01/1900");
            oReporte.FechaHasta   = this.txtFechaHasta.Text != "" ? Utiles.Fechas.FormatFechaDDMMYYYY(this.txtFechaHasta.Text) : DateTime.Today;
            oReporte.NroCajaDesde = txtNroCajaDesde.Text == string.Empty ? 0 : int.Parse(txtNroCajaDesde.Text);
            oReporte.NroCajaHasta = txtNroCajaHasta.Text == string.Empty ? 10000 : int.Parse(txtNroCajaHasta.Text);
            oReporte.NroLoteDesde = txtNroLoteDesde.Text == string.Empty ? 0 : int.Parse(txtNroLoteDesde.Text);
            oReporte.NroLoteHasta = txtNroLoteHasta.Text == string.Empty ? 10000 : int.Parse(txtNroLoteHasta.Text);
            oReporte.TipoGuia     = getLista(lstTipoDigitalizacion);
            DsReporteCantidadGuiasDigitalizadas ds = oReporte.GetGuiasDigitalizadasDetallado();

            dtgDetallado.DataSource = ds.Detalle;
            dtgDetallado.DataBind();
        }