diff --git a/App_Code/ClsMovimientos.vb b/App_Code/ClsMovimientos.vb index 35896829d..74e9f319d 100644 --- a/App_Code/ClsMovimientos.vb +++ b/App_Code/ClsMovimientos.vb @@ -1438,7 +1438,8 @@ Public Class ClsMovimientos Optional EstatusCliente As Integer = -1, Optional CveUsuarioConsulta As Integer = -1, Optional CveBanco As Integer = -1, Optional CveCuenta As Integer = -1, Optional TipoCambio As Integer = -1, Optional TCEspecifico As Double = 0, Optional CveClienteClasificacion As Integer = -1, - Optional EsDistribuidor As Integer = -1, Optional FechaAplicadoI As Date = MinFecha, Optional FechaAplicadoF As Date = MaxFecha) As Boolean + Optional EsDistribuidor As Integer = -1, Optional FechaAplicadoI As Date = MinFecha, Optional FechaAplicadoF As Date = MaxFecha, + Optional FechaRegistroIEI As Date = MinFecha, Optional FechaRegistroIEF As Date = MaxFecha) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Vta_RepRecuperacion") With SqlAdapter.SelectCommand.Parameters @@ -1464,7 +1465,10 @@ Public Class ClsMovimientos .Add("@EsDistribuidor", SqlDbType.Int).Value = EsDistribuidor .Add("@FechaAplicadoI", SqlDbType.Date).Value = FechaAplicadoI.ToShortDateString - .Add("@FechaAplicadoF", SqlDbType.Date).Value = FechaAplicadoF.ToShortDateString + .Add("@FechaAplicadoF", SqlDbType.Date).Value = FechaAplicadoF.ToShortDateString + + .Add("@FechaRegistroIEI", SqlDbType.Date).Value = FechaRegistroIEI.ToShortDateString + .Add("@FechaRegistroIEF", SqlDbType.Date).Value = FechaRegistroIEF.ToShortDateString End With Try SqlAdapter.Fill(Data) @@ -1518,7 +1522,8 @@ Public Class ClsMovimientos Optional CveCuenta As Integer = -1, Optional Grupo As String = "-1", Optional TipoCambio As Integer = -1, Optional TCEspecifico As Double = 0, Optional CveMoneda As Integer = -1, Optional CveClienteClasificacion As Integer = -1, Optional Tipo As Integer = -1, - Optional EsDistribuidor As Integer = -1, Optional FechaAplicadoI As Date = Nothing, Optional FechaAplicadoF As Date = Nothing) As Boolean + Optional EsDistribuidor As Integer = -1, Optional FechaAplicadoI As Date = Nothing, Optional FechaAplicadoF As Date = Nothing, + Optional FechaRegistroIEI As Date = MinFecha, Optional FechaRegistroIEF As Date = MaxFecha) As Boolean Dim Retorno As Boolean = False @@ -1549,9 +1554,10 @@ Public Class ClsMovimientos .Add("@Tipo", SqlDbType.Int).Value = Tipo .Add("@EsDistribuidor", SqlDbType.Int).Value = EsDistribuidor - .Add("@FechaAplicadoI", SqlDbType.Date).Value = FechaAplicadoI.ToShortDateString - .Add("@FechaAplicadoF", SqlDbType.Date).Value = FechaAplicadoF.ToShortDateString + .Add("@FechaAplicadoF", SqlDbType.Date).Value = FechaAplicadoF.ToShortDateString + .Add("@FechaRegistroIEI", SqlDbType.Date).Value = FechaRegistroIEI.ToShortDateString + .Add("@FechaRegistroIEF", SqlDbType.Date).Value = FechaRegistroIEF.ToShortDateString End With diff --git a/Ventas/RepRecuperacion.aspx b/Ventas/RepRecuperacion.aspx index e41e0c19f..fd77085ef 100644 --- a/Ventas/RepRecuperacion.aspx +++ b/Ventas/RepRecuperacion.aspx @@ -209,6 +209,36 @@ +
F. Registro IE inicio:
+
+
+ + + + +
+ + + + + + +
+
F. Registro IE Fin:
+
+
+ + + + +
+ + + + + + +
diff --git a/Ventas/RepRecuperacion.aspx.vb b/Ventas/RepRecuperacion.aspx.vb index c3c3b4e99..c47103ad0 100644 --- a/Ventas/RepRecuperacion.aspx.vb +++ b/Ventas/RepRecuperacion.aspx.vb @@ -129,13 +129,16 @@ Partial Class Ventas_RepRecuperacion End If Dim FechaAplicadoI As Date = If(IsDate(TxtFechaAplicadoI.Text), TxtFechaAplicadoI.Text.ToDate, MinFecha) - Dim FechaAplicadoF As Date = If(IsDate(TxtFechaAplicadoF.Text), TxtFechaAplicadoF.Text.ToDate, MaxFecha) + Dim FechaAplicadoF As Date = If(IsDate(TxtFechaAplicadoF.Text), TxtFechaAplicadoF.Text.ToDate, MaxFecha) + + Dim FechaRegistroIEI As Date = If(IsDate(TxtFechaRegistroIEI.Text), TxtFechaRegistroIEI.Text.ToDate, MinFecha) + Dim FechaRegistroIEF As Date = If(IsDate(TxtFechaRegistroIEF.Text), TxtFechaRegistroIEF.Text.ToDate, MaxFecha) If ObjMovtos.GetRepRecuperacion(txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, DdlClientes.SelectedValue.ToEntero, DdlSubProyecto.SelectedValue.ToEntero, DdlVendedor.SelectedValue.ToEntero, DdlUsuario.SelectedValue.ToEntero, -1, "-1", UsuarioActual.CveEmpresa, DdlGrupo.SelectedValue.ToEntero, DdlResponsable.SelectedValue.ToEntero, DdlTipoDocto.SelectedValue.ToString, CveBanco:=DdlBanco.SelectedValue.ToEntero, CveCuenta:=DdlCuentaBancaria.SelectedValue.ToEntero, EstatusCliente:=DdlEstatusCliente.SelectedValue.ToEntero, CveUsuarioConsulta:=UsuarioActual.CveUsuario, TipoCambio:=RblTipoCambio.SelectedValue.ToEntero, TCEspecifico:=TCEspecifico, CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, - EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero(), FechaAplicadoI:=FechaAplicadoI, FechaAplicadoF:=FechaAplicadoF) Then + EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero(), FechaAplicadoI:=FechaAplicadoI, FechaAplicadoF:=FechaAplicadoF, FechaRegistroIEI:=FechaRegistroIEI, FechaRegistroIEF:=FechaRegistroIEF) Then GvDatos.DataSource = ObjMovtos.DtResultados DtDatos = ObjMovtos.DtResultados Else @@ -158,12 +161,14 @@ Partial Class Ventas_RepRecuperacion Private Sub GvDatos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvDatos.RowDataBound If e.Row.RowType = DataControlRowType.DataRow Then Dim Css As String = "Texto" - Dim FechaI, FechaF, FechaAplicadoI, FechaAplicadoF As String + Dim FechaI, FechaF, FechaAplicadoI, FechaAplicadoF, FechaRegistroIEI, FechaRegistroIEF As String Dim CveClienteSucursal As Integer = -1 FechaI = If(IsDate(txtFechaI.Text.Trim()), txtFechaI.Text.Trim(), "-1") FechaF = If(IsDate(txtFechaF.Text.Trim()), txtFechaF.Text.Trim(), "-1") FechaAplicadoI = If(IsDate(TxtFechaAplicadoI.Text.Trim()), TxtFechaAplicadoI.Text.Trim(), MinFecha.ToShortDateString.ToString) - FechaAplicadoF = If(IsDate(TxtFechaAplicadoF.Text.Trim()), TxtFechaAplicadoF.Text.Trim(), MaxFecha.ToShortDateString.ToString) + FechaAplicadoF = If(IsDate(TxtFechaAplicadoF.Text.Trim()), TxtFechaAplicadoF.Text.Trim(), MaxFecha.ToShortDateString.ToString) + FechaRegistroIEI = If(IsDate(TxtFechaRegistroIEI.Text.Trim()), TxtFechaRegistroIEI.Text.Trim(), MaxFecha.ToShortDateString.ToString) + FechaRegistroIEF = If(IsDate(TxtFechaRegistroIEF.Text.Trim()), TxtFechaRegistroIEF.Text.Trim(), MaxFecha.ToShortDateString.ToString) If e.Row.DBCampo("Orden") = "" Then e.Row.CssClass = "Totales" End If @@ -175,15 +180,15 @@ Partial Class Ventas_RepRecuperacion End If End If - Dim Liga4 As String = String.Format("/Ventas/RepRecuperacionDetalle.aspx?GPO={0}&CveCliente={1}&CveSubProyecto={2}&Vendedor={3}&CveUsuario={4}&CveEstatusFactura={5}&IVA={6}&FechaI={7}&FechaF={8}&CveResponsable={9}&TipoDocto={10}&CveClienteSucursal={11}&CveBanco{12}&CveCuenta{13}&Grupo={14}&TipoCambio={15}&TCEspecifico={16}&CveMoneda={17}&Tipo={18}&EsDistribuidor={19}&FechaAplicadoI={20}&FechaAplicadoF={21}", + Dim Liga4 As String = String.Format("/Ventas/RepRecuperacionDetalle.aspx?GPO={0}&CveCliente={1}&CveSubProyecto={2}&Vendedor={3}&CveUsuario={4}&CveEstatusFactura={5}&IVA={6}&FechaI={7}&FechaF={8}&CveResponsable={9}&TipoDocto={10}&CveClienteSucursal={11}&CveBanco{12}&CveCuenta{13}&Grupo={14}&TipoCambio={15}&TCEspecifico={16}&CveMoneda={17}&Tipo={18}&EsDistribuidor={19}&FechaAplicadoI={20}&FechaAplicadoF={21}&FechaRegistroIEI={22}&FechaRegistroIEF={23}", DdlGrupo.SelectedValue, e.Row.DBCampo("CveCliente"), e.Row.DBCampo("CveSubProyecto"), e.Row.DBCampo("CveVendedor"), - e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"), e.Row.DBCampo("GPO_IVA"), FechaI, FechaF, DdlResponsable.SelectedValue, e.Row.DBCampo("TipoDocto"), CveClienteSucursal, e.Row.DBCampo("CveBanco"), e.Row.DBCampo("CveCuenta"), e.Row.DBCampo("GPO"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveMoneda"), 2, e.Row.DBCampo("EsDistribuidor"), FechaAplicadoI, FechaAplicadoF) + e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"), e.Row.DBCampo("GPO_IVA"), FechaI, FechaF, DdlResponsable.SelectedValue, e.Row.DBCampo("TipoDocto"), CveClienteSucursal, e.Row.DBCampo("CveBanco"), e.Row.DBCampo("CveCuenta"), e.Row.DBCampo("GPO"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveMoneda"), 2, e.Row.DBCampo("EsDistribuidor"), FechaAplicadoI, FechaAplicadoF, FechaRegistroIEI, FechaRegistroIEF) e.Row.FCHyperLink("HplPagado").NavigateUrl = Liga4 - Dim Liga5 As String = String.Format("/Ventas/RepRecuperacionDetalle.aspx?GPO={0}&CveCliente={1}&CveSubProyecto={2}&Vendedor={3}&CveUsuario={4}&CveEstatusFactura={5}&IVA={6}&FechaI={7}&FechaF={8}&CveResponsable={9}&TipoDocto={10}&CveClienteSucursal={11}&CveBanco{12}&CveCuenta{13}&Grupo={14}&TipoCambio={15}&TCEspecifico={16}&CveMoneda={17}&Tipo={18}&EsDistribuidor={19}&FechaAplicadoI={20}&FechaAplicadoF={21}", + Dim Liga5 As String = String.Format("/Ventas/RepRecuperacionDetalle.aspx?GPO={0}&CveCliente={1}&CveSubProyecto={2}&Vendedor={3}&CveUsuario={4}&CveEstatusFactura={5}&IVA={6}&FechaI={7}&FechaF={8}&CveResponsable={9}&TipoDocto={10}&CveClienteSucursal={11}&CveBanco{12}&CveCuenta{13}&Grupo={14}&TipoCambio={15}&TCEspecifico={16}&CveMoneda={17}&Tipo={18}&EsDistribuidor={19}&FechaAplicadoI={20}&FechaAplicadoF={21}&FechaRegistroIEI={22}&FechaRegistroIEF={23}", DdlGrupo.SelectedValue, e.Row.DBCampo("CveCliente"), e.Row.DBCampo("CveSubProyecto"), e.Row.DBCampo("CveVendedor"), - e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"), e.Row.DBCampo("GPO_IVA"), FechaI, FechaF, DdlResponsable.SelectedValue, e.Row.DBCampo("TipoDocto"), CveClienteSucursal, e.Row.DBCampo("CveBanco"), e.Row.DBCampo("CveCuenta"), e.Row.DBCampo("GPO"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveMoneda"), 1, e.Row.DBCampo("EsDistribuidor"), FechaAplicadoI, FechaAplicadoF) + e.Row.DBCampo("CveUsuario"), e.Row.DBCampo("CveEstatusFactura"), e.Row.DBCampo("GPO_IVA"), FechaI, FechaF, DdlResponsable.SelectedValue, e.Row.DBCampo("TipoDocto"), CveClienteSucursal, e.Row.DBCampo("CveBanco"), e.Row.DBCampo("CveCuenta"), e.Row.DBCampo("GPO"), e.Row.DBCampo("TipoCambio"), e.Row.DBCampo("TCEspecifico"), e.Row.DBCampo("CveMoneda"), 1, e.Row.DBCampo("EsDistribuidor"), FechaAplicadoI, FechaAplicadoF, FechaRegistroIEI, FechaRegistroIEF) e.Row.FCHyperLink("HplVendido").NavigateUrl = Liga5 diff --git a/Ventas/RepRecuperacionDetalle.aspx b/Ventas/RepRecuperacionDetalle.aspx index a4b0ca3b5..36f8d1fac 100644 --- a/Ventas/RepRecuperacionDetalle.aspx +++ b/Ventas/RepRecuperacionDetalle.aspx @@ -216,7 +216,39 @@ - + +
+
F. Registro IE inicio:
+
+
+ + + + +
+ + + + + + +
+
F. Registro IE Fin:
+
+
+ + + + +
+ + + + + + +
+
diff --git a/Ventas/RepRecuperacionDetalle.aspx.vb b/Ventas/RepRecuperacionDetalle.aspx.vb index 76a99761f..fb8bbe4e1 100644 --- a/Ventas/RepRecuperacionDetalle.aspx.vb +++ b/Ventas/RepRecuperacionDetalle.aspx.vb @@ -85,7 +85,7 @@ Partial Class Ventas_RepRecuperacionDetalle Private Sub CargaCombos() Dim CveCliente, CveVendedor, CveUsuario, CveSubProyecto, CveEstatus, CveResponsable, CveAgrupador, CveBanco, CveCuenta, CveClienteSucursal, CveMoneda, CveClienteClasificacion As Integer - Dim FechaI, FechaF, TipoDocto, TipoCambio, FechaAplicadoI, FechaAplicadoF As String + Dim FechaI, FechaF, TipoDocto, TipoCambio, FechaAplicadoI, FechaAplicadoF, FechaRegistroIEI, FechaRegistroIEF As String 'Carga Clientes If (UsuarioActual.Empresa.Funcionalidad(105) = "1" Or UsuarioActual.Empresa.Funcionalidad(141) = "1") Then @@ -147,14 +147,24 @@ Partial Class Ventas_RepRecuperacionDetalle End If FechaAplicadoI = If(Request("FechaAplicadoI") IsNot Nothing, Request("FechaAplicadoI").ToString, "-1").ToString - FechaAplicadoF = If(Request("FechaAplicadoF") IsNot Nothing, Request("FechaAplicadoF").ToString, "-1").ToString + FechaAplicadoF = If(Request("FechaAplicadoF") IsNot Nothing, Request("FechaAplicadoF").ToString, "-1").ToString + + FechaRegistroIEI = If(Request("FechaRegistroIEI") IsNot Nothing, Request("FechaRegistroIEI").ToString, "-1").ToString + FechaRegistroIEF = If(Request("FechaRegistroIEF") IsNot Nothing, Request("FechaRegistroIEF").ToString, "-1").ToString + If FechaAplicadoF <> "-1" Then TxtFechaAplicadoF.Text = FechaAplicadoF End If If FechaAplicadoI <> "-1" Then TxtFechaAplicadoI.Text = FechaAplicadoI + End If + + If FechaRegistroIEF <> "-1" Then + TxtFechaRegistroIEF.Text = FechaRegistroIEF + End If + If FechaRegistroIEI <> "-1" Then + TxtFechaRegistroIEI.Text = FechaRegistroIEI End If - TipoDocto = IfNull(Request("TipoDocto"), "-1").ToString CveClienteSucursal = IfNull(Request("CveClienteSucursal"), "-1").ToString.ToEntero @@ -239,7 +249,7 @@ Partial Class Ventas_RepRecuperacionDetalle Iva.ToString, DdlGrupo.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, DdlResponsable.SelectedValue.ToEntero, DdlTipoDocto.SelectedValue, CveUsuarioConsulta:=UsuarioActual.CveUsuario, CveBanco:=DdlBanco.SelectedValue.ToEntero, CveCuenta:=DdlCuentaBancaria.SelectedValue.ToEntero, Grupo:=Grupo, TipoCambio:=RblTipoCambio.SelectedValue.ToEntero, TCEspecifico:=TCEspecifico, CveMoneda:=DdlMoneda.SelectedValue.ToEntero, CveClienteClasificacion:=DdlClienteClasificacion.SelectedValue.ToEntero, Tipo:=Tipo, - EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero(), FechaAplicadoI:=TxtFechaAplicadoI.Text.ToDate, FechaAplicadoF:=TxtFechaAplicadoF.Text.ToDate) Then + EsDistribuidor:=DdlDistribuidor.SelectedValue.ToEntero(), FechaAplicadoI:=TxtFechaAplicadoI.Text.ToDate, FechaAplicadoF:=TxtFechaAplicadoF.Text.ToDate, FechaRegistroIEI:=TxtFechaRegistroIEI.Text.ToDate, FechaRegistroIEF:=TxtFechaRegistroIEF.Text.ToDate) Then GvDatos.DataSource = ObjMovtos.DtResultados DtDatos = ObjMovtos.DtResultados