GlobalDT- para empresa llantera

This commit is contained in:
2024-01-08 19:01:39 -07:00
parent 3d04a8281a
commit 754f00ee54
2 changed files with 42 additions and 3 deletions

View File

@@ -986,11 +986,11 @@ Public Class ClsGenerales
End Try
Return Retorno
End Function
End Function
#End Region
#Region "R I M T A M A N I O S"
Public Function GetRimTamanios(CveEmpresa As Integer, Optional CveRinTamaño As Integer = -1) As Boolean
Public Function GetRinTamanios(CveEmpresa As Integer, Optional CveRinTamaño As Integer = -1) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Gral_TamañosGet")

View File

@@ -4401,6 +4401,45 @@ Public Class ClsPaginas
Application(AppNombre) = value
End Set
End Property
Public Shared Property GlobalDTPSRinTamaños(CveEmpresa As Integer, Optional CveRinTamaño As Integer = -1) As DataTable
Get
Dim AppNombre As String = $"GlobalDTPSRinTamaños-{CveEmpresa}"
If HttpContext.Current.Application(AppNombre) Is Nothing Then
Using ObjGral As New ClsGenerales()
If ObjGral.GetRinTamanios(CveEmpresa) Then HttpContext.Current.Application(AppNombre) = ObjGral.DtResultados Else HttpContext.Current.Application(AppNombre) = Nothing
End Using
End If
Dim Str As New StringBuilder
If CveRinTamaño > 0 Then Str.AppendFormat(" CveRinTamaño = {0} ", CveRinTamaño)
Dim Dv As New DataView(DirectCast(HttpContext.Current.Application(AppNombre), DataTable), Str.ToString, "", DataViewRowState.CurrentRows)
GlobalDTPSRinTamaños = Dv.ToTable
End Get
Set(value As DataTable)
Dim AppNombre As String = $"GlobalDTPSRinTamaños-{CveEmpresa}"
HttpContext.Current.Application(AppNombre) = value
End Set
End Property
Public Shared Property GlobalDTPSMedidas(CveEmpresa As Integer, Optional CveMedida As Integer = -1) As DataTable
Get
Dim AppNombre As String = $"GlobalDTPSMedidas-{CveEmpresa}"
If HttpContext.Current.Application(AppNombre) Is Nothing Then
Using ObjGral As New ClsGenerales()
If ObjGral.GetMedidas(CveEmpresa) Then HttpContext.Current.Application(AppNombre) = ObjGral.DtResultados Else HttpContext.Current.Application(AppNombre) = Nothing
End Using
End If
Dim Str As New StringBuilder
If CveMedida <> -1 Then Str.AppendFormat(" CveMedida = {0} ", CveMedida)
Dim Dv As New DataView(DirectCast(HttpContext.Current.Application(AppNombre), DataTable), Str.ToString, "", DataViewRowState.CurrentRows)
GlobalDTPSMedidas = Dv.ToTable
End Get
Set(value As DataTable)
Dim AppNombre As String = $"GlobalDTPSMedidas-{CveEmpresa}"
HttpContext.Current.Application(AppNombre) = value
End Set
End Property
#Region "CITRUS GAME"
Property GlobalDTGralEmpacados(CveEmpresa As Integer) As DataTable
Get