From 896cee4e9f28ec6ff26fba389ca0502505dd3af4 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 27 Dec 2024 19:22:29 -0700 Subject: [PATCH 01/32] =?UTF-8?q?--=20mejora=20en=20sincronizaci=C3=B3n=20?= =?UTF-8?q?de=20fraquincias,=20que=20sea=20la=20b=C3=BAsqueda=20de=20globa?= =?UTF-8?q?ldt,=20para=20que=20el=20c=C3=B3digo=20sea=20ex=C3=A1cto?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Ventas/ProductosServicios.aspx.vb | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/Ventas/ProductosServicios.aspx.vb b/Ventas/ProductosServicios.aspx.vb index 4361a0c36..2d60ba1bb 100644 --- a/Ventas/ProductosServicios.aspx.vb +++ b/Ventas/ProductosServicios.aspx.vb @@ -3345,12 +3345,10 @@ Partial Class ProductosyServicios End If Else - - If ObjPS.GetPS(-1, -1, CveEmpresaFranquicia, Codigo:=TxtCodigo.Text.Trim.ToUpper) Then - - If ObjPS.DtResultados IsNot Nothing AndAlso ObjPS.DtResultados.Rows.Count = 1 Then - Dim CvePS As Integer = ObjPS.DtResultados.FiltroPrimeroValor("CvePS", String.Format(" Codigo = '{0}'", TxtCodigo.Text.Trim.ToUpper)).ToEntero() - If Not ObjPS.UpdatePS(CveClasificacion, -1, CveUnidadMedida, TxtCodigo.Text.Trim, TxtNumeroParte.Text.Trim, TxtCodigoBarras.Text.Trim, PSS, TxtPrecio.Text.Trim.ToDouble, DdlIVA.SelectedValue.ToDouble, + Dim CvePS As Integer = GlobalDTPSSimplificado(CveEmpresaFranquicia, Codigo:=TxtCodigo.Text.Trim.ToUpper).FiltroPrimeroValor("CvePS").ToEntero + If CvePS > 0 Then + 'Dim CvePS As Integer = ObjPS.DtResultados.FiltroPrimeroValor("CvePS", String.Format(" Codigo = '{0}'", TxtCodigo.Text.Trim.ToUpper)).ToEntero() + If Not ObjPS.UpdatePS(CveClasificacion, -1, CveUnidadMedida, TxtCodigo.Text.Trim, TxtNumeroParte.Text.Trim, TxtCodigoBarras.Text.Trim, PSS, TxtPrecio.Text.Trim.ToDouble, DdlIVA.SelectedValue.ToDouble, (TxtRetIVA.Text.Trim.ToDouble / 100), ChkInventariable.Checked, -1, True, ChkAplicaParaVenta.Checked, ChkEstado.Checked, UsuarioActual.CveUsuario, CvePS, CveMetodoInv, EsPaquete, DdlSATPS.SelectedValue.ToEntero, CveEmpresaFranquicia, CveTipoPS:=DdlTipoPS.SelectedValue.ToEntero, TipoServicio:=-1, CveClasificacion2:=CveClasificacion2, CveMarca:=CveMarcaFranquicia, AlmacenSeccion:=TxtAlmacenSeccion.Text.Trim, AplicaIEPS:=ChkAplicaIeps.Checked, IEPSPorcentaje:=DdlIEPSPorcentaje.SelectedValue.ToDecimal, @@ -3363,15 +3361,8 @@ Partial Class ProductosyServicios ClaveImpuestoUM:=DdlImpUM.SelectedValue.ToString, ClaveCategoriaToxicidad:=DdlCategoriaToxicidad.SelectedValue.ToString, ClaveImpuestoTipoProducto:=DdlImpTipoProducto.SelectedValue.ToString, AplicaSerie:=ChkSerie.Checked, AplicaLote:=ChkLote.Checked, AplicaCaducidad:=ChkCaducidad.Checked, AplicaSeccion:=ChkSeccion.Checked, TiempoCaducidad:=TxtTiempoCaducidad.Text.ToEntero()) Then - Return True - - End If - - Else - Alert(String.Format("El producto no existe en la franquicia: '{0}'", GlobalDTEmpresas(CveEmpresaFranquicia).FiltroPrimeroValor("Empresa")), TipoMensaje.MsgAdvertencia) Return True End If - Else Alert(String.Format("Se presento un error al consultar la existencia en la franquicia: '{0}'", GlobalDTEmpresas(CveEmpresaFranquicia).FiltroPrimeroValor("Empresa")), TipoMensaje.MsgAdvertencia) Return True From 71e1ffce4571ac0ba8db382dd1a09607fd343b7a Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 27 Dec 2024 22:08:18 -0700 Subject: [PATCH 02/32] - cambio de promociones --- App_Code/ClsVentas.vb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/App_Code/ClsVentas.vb b/App_Code/ClsVentas.vb index 96e987c23..3d72b5bff 100644 --- a/App_Code/ClsVentas.vb +++ b/App_Code/ClsVentas.vb @@ -2473,20 +2473,21 @@ Public Class ClsVentas 'End Function #Region " PROMOCIONES " - Public Function GetPromociones(CvePromocion As Integer, Fecha As String, CveVendedor As Integer, CveCliente As Integer, Estatus As Integer, CveEmpresa As Integer, - CveSubProyecto As Integer, Optional CveMarca As Integer = -1) As Boolean + Public Function GetPromociones(CvePromocion As Integer, Fecha As Date, CveVendedor As Integer, CveCliente As Integer, Estatus As Integer, CveEmpresa As Integer, + CveSubProyecto As Integer, Optional CveMarca As Integer = -1, Optional CveUsuario As Integer = -1) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Vta_PromocionesGet") With SqlAdapter.SelectCommand.Parameters .Add("@CvePromocion", SqlDbType.Int).Value = CvePromocion - .Add("@Fecha", SqlDbType.VarChar).Value = Fecha + .Add("@Fecha", SqlDbType.Date).Value = Fecha .Add("@Estatus", SqlDbType.Int).Value = Estatus .Add("@CveVendedor", SqlDbType.Int).Value = CveVendedor .Add("@CveCliente", SqlDbType.Int).Value = CveCliente .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto .Add("@CveMarca", SqlDbType.Int).Value = CveMarca + .Add("@CveUsuarioConsulta", SqlDbType.Int).Value = CveUsuario End With Try From 0035ae33edb59d692de07dfbf447159fd7d40ba2 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 27 Dec 2024 22:09:21 -0700 Subject: [PATCH 03/32] =?UTF-8?q?--=20surtido=20autom=C3=A1tico=20--=20si?= =?UTF-8?q?=20hay=20un=20subproyecto=20asignado=20que=20lo=20asigne=20en?= =?UTF-8?q?=20la=20carga=20de=20factura?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Compras/Compras.aspx | 2 +- Compras/Compras.aspx.vb | 131 +++++++++++++--------------------------- 2 files changed, 44 insertions(+), 89 deletions(-) diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx index bbc5e7a95..4f4952174 100644 --- a/Compras/Compras.aspx +++ b/Compras/Compras.aspx @@ -5171,7 +5171,7 @@