Funcionalidad 545, para validar productos de contratos de obra
This commit is contained in:
@@ -4281,11 +4281,13 @@ Partial Class Compras_Compras
|
||||
Next
|
||||
If ErrorValidacion Then Exit Sub
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(545) = "1" Then
|
||||
Dim dtPSInvalidos As String = ValidarPSContrato(TmpDT.FiltraParametros("", "", {"CveSubProyecto", "CvePS", "Cantidad", "PU"}))
|
||||
If dtPSInvalidos <> "" Then
|
||||
Alert(dtPSInvalidos, TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
'RECORRO LOS PRODUCTOS O SERVICIOS PARA REGISTRARLOS LOS QUE NO EXISTEN EN EL CATÁLOGO
|
||||
Dim tCve As Integer
|
||||
@@ -18106,9 +18108,10 @@ Partial Class Compras_Compras
|
||||
End If
|
||||
|
||||
ActualizaTotales = True
|
||||
Dim ObjContratos As New ClsContratos
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(545) = "1" Then
|
||||
Dim TieneError As Boolean = False
|
||||
Dim dttemp As New DataTable ' GlobalDTContratos().FiltraParametros(String.Format("CveSubProyecto = {0}", DdlSubProyecto.SelectedValue.ToString))
|
||||
Dim dttemp As New DataTable '= GlobalDTContratos().FiltraParametros(String.Format("CveSubProyecto = {0}", DdlSubProyecto.SelectedValue.ToString))
|
||||
dttemp.Columns.Add("CveSubProyecto", GetType(Integer))
|
||||
dttemp.Columns.Add("CvePS", GetType(Integer))
|
||||
dttemp.Columns.Add("Cantidad", GetType(Decimal))
|
||||
@@ -18124,7 +18127,12 @@ Partial Class Compras_Compras
|
||||
Dim dtPSInvalidos As String = ValidarPSContrato(dttemp)
|
||||
If dtPSInvalidos <> "" Then
|
||||
TieneError = True
|
||||
Alert(dtPSInvalidos, TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
'If dttemp IsNot Nothing AndAlso dttemp.Rows.Count > 0 Then
|
||||
' Dim drContrato As DataRow = dttemp.Rows(0)
|
||||
' If ObjContratos.GetContratosDetalle(drContrato("CveContrato").ToString.ToEntero) Then
|
||||
@@ -18157,8 +18165,9 @@ Partial Class Compras_Compras
|
||||
|
||||
' End If
|
||||
'End If
|
||||
ObjContratos.Dispose()
|
||||
If Not TieneError Then
|
||||
|
||||
|
||||
|
||||
Select Case Modalidad
|
||||
Case "A" 'ADD
|
||||
|
||||
@@ -18200,30 +18209,6 @@ Partial Class Compras_Compras
|
||||
CompruebaAgregar()
|
||||
GuardaAC()
|
||||
End If
|
||||
Else
|
||||
Alert(dtPSInvalidos, TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
|
||||
'If UsuarioActual.Empresa.Funcionalidad(577).ToString = "1" Then
|
||||
|
||||
' 'If UsuarioActual.CveRol = 1 Then
|
||||
' ' Alert($"Ok funcionalidad 577 RetencionIVA { RetencionIVA} IVAOriginal {IVAOriginal}")
|
||||
' 'End If
|
||||
|
||||
' If RetencionIVA = 0 And IVAOriginal > 0 Then
|
||||
' For Each dRow As DataRow In TmpDT.Rows
|
||||
' If dRow("CveTipoPS").ToString.ToEntero = 1 Then
|
||||
' 'Comnetado para reubicar el boton
|
||||
' 'tdIVA6.Visible = True
|
||||
' Exit For
|
||||
' End If
|
||||
' Next
|
||||
' End If
|
||||
|
||||
'End If
|
||||
|
||||
|
||||
|
||||
UpPS.Update()
|
||||
CargaGvPersonal()
|
||||
@@ -20938,6 +20923,7 @@ Partial Class Compras_Compras
|
||||
Next
|
||||
End If
|
||||
End If
|
||||
objContratos.Dispose()
|
||||
|
||||
If MensajeProducto.Length <> 64 Then
|
||||
Retorno = MensajeProducto
|
||||
|
||||
Reference in New Issue
Block a user