This commit is contained in:
@@ -183,7 +183,23 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
Else
|
||||
CveEmpresa = usuario.CveEmpresa
|
||||
Dim Name = IfNull(context.Request("Name"), "-1").ToString
|
||||
Dim dt As DataTable = DirectCast(context.Application("GlobalDTCliente"), DataTable).FiltraParametros($"CveEmpresa = {CveEmpresa}")
|
||||
Dim AppNombre As String = String.Format("GlobalDTCliente{0}", CveEmpresa)
|
||||
'sino existe, recarga los datos
|
||||
If context.Application(AppNombre) Is Nothing Then
|
||||
Dim ObjClientes As New ClsClientes
|
||||
If ObjClientes.GetClientes(-1, "-1", "-1", "-1", "-1", "-1", "-1", -1, CveEmpresa, Estatus:=-1) Then
|
||||
context.Application(AppNombre) = ObjClientes.DtResultados
|
||||
End If
|
||||
ObjClientes.Dispose()
|
||||
End If
|
||||
|
||||
'Dim ObjClientes As New ClsClientes
|
||||
'If ObjClientes.GetClientes(-1, Name, "-1", "-1", "-1", "-1", "-1", -1, CveEmpresa, Estatus:=-1) Then
|
||||
' DtRetorno = ObjClientes.DtResultados
|
||||
'End If
|
||||
'ObjClientes.Dispose()
|
||||
|
||||
Dim dt As DataTable = DirectCast(context.Application(AppNombre), DataTable).FiltraParametros($"CveEmpresa = {CveEmpresa}")
|
||||
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
|
||||
DtRetorno = dt.FiltraParametros($"NombreComercial like '%{Name}%'")
|
||||
End If
|
||||
@@ -214,7 +230,22 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
Else
|
||||
CveEmpresa = usuario.CveEmpresa
|
||||
Dim Name = IfNull(context.Request("Name"), "-1").ToString
|
||||
Dim dt As DataTable = DirectCast(context.Application("GlobalDTCompProveedores"), DataTable).FiltraParametros($"CveEmpresa = {CveEmpresa}")
|
||||
Dim AppNombre As String = String.Format("GlobalDTCompProveedores{0}", CveEmpresa)
|
||||
'sino existe, recarga los datos
|
||||
If context.Application(AppNombre) Is Nothing Then
|
||||
Dim ObjProveedores As New ClsCompProveedores
|
||||
If ObjProveedores.GetProveedores(ClsCompProveedores.TipoConsulta.ParaGlobalDT, -1, "-1", "-1", "-1", "-1", "-1", "-1", "-1", -1, CveEmpresa) Then
|
||||
context.Application(AppNombre) = ObjProveedores.DtResultados
|
||||
End If
|
||||
ObjProveedores.Dispose()
|
||||
End If
|
||||
|
||||
'Dim ObjProveedores As New ClsCompProveedores
|
||||
'If ObjProveedores.GetProveedores(ClsCompProveedores.TipoConsulta.ParaUsoEnEmpresa, -1, "-1", Name, "-1", "-1", "-1", "-1", "-1", -1, CveEmpresa) Then
|
||||
' DtRetorno = ObjProveedores.DtResultados
|
||||
'End If
|
||||
'ObjProveedores.Dispose()
|
||||
Dim dt As DataTable = DirectCast(context.Application(AppNombre), DataTable).FiltraParametros($"CveEmpresa = {CveEmpresa}")
|
||||
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
|
||||
DtRetorno = dt.FiltraParametros($"RazonSocial like '%{Name}%'")
|
||||
End If
|
||||
@@ -320,6 +351,7 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
If objInv.GetExistenciasProductosLike(Name, CveClasificacion, CveSubProyecto, Estatus.ToEntero, AplicaParaVenta, CveEmpresa) Then
|
||||
|
||||
' limpio los almacenes donde no tiene ningun producto existencia
|
||||
|
||||
Dim i As Integer = 0
|
||||
While i < objInv.DtResultados.Columns.Count
|
||||
|
||||
@@ -348,9 +380,18 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
End If
|
||||
|
||||
If UsaGlobal Then
|
||||
'se recarga el global, y el clspaginas, son los unicos 2 lugares
|
||||
Dim AppNombre As String = String.Format("GlobalDTPSSimplificado{0}", CveEmpresa)
|
||||
If context.Application(String.Format("GlobalDTPSSimplificado{0}", CveEmpresa)) Is Nothing Then
|
||||
Dim ObjPS As New ClsProductosServicios
|
||||
If ObjPS.GetPSSimplificado(CveEmpresa) Then context.Application(AppNombre) = ObjPS.DtResultados.AsEnumerable()
|
||||
ObjPS.Dispose()
|
||||
|
||||
'Dim DTPS = DirectCast(context.Application("GlobalDTPSSimplificado"), EnumerableRowCollection(Of DataRow))
|
||||
Dim DTPS = ClsPaginas.GlobalDTPSSimplificado(CveEmpresa).AsEnumerable
|
||||
End If
|
||||
|
||||
|
||||
Dim DTPS = DirectCast(context.Application(AppNombre), EnumerableRowCollection(Of DataRow))
|
||||
'Dim DTPS = ClsPaginas.GlobalDTPSSimplificado(CveEmpresa).AsEnumerable
|
||||
|
||||
If DTPS IsNot Nothing Then
|
||||
|
||||
@@ -580,14 +621,9 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
Dim UsaGlobal As Boolean = True
|
||||
|
||||
|
||||
|
||||
|
||||
If UsaGlobal Then
|
||||
|
||||
|
||||
|
||||
Dim DTPS = ClsPaginas.GlobalDTPSSimplificado(CveEmpresa).AsEnumerable ' DirectCast(context.Application("GlobalDTPSSimplificado"), EnumerableRowCollection(Of DataRow))
|
||||
|
||||
Dim DTPS = DirectCast(context.Application(String.Format("GlobalDTPSSimplificado{0}", CveEmpresa)), EnumerableRowCollection(Of DataRow))
|
||||
|
||||
If DTPS IsNot Nothing Then
|
||||
|
||||
|
||||
Reference in New Issue
Block a user