reparando error lógico
This commit is contained in:
@@ -20211,23 +20211,25 @@ Partial Class Compras_Compras
|
||||
CvePSGRuposAux.AppendFormat("{0},", CvePSIndividual)
|
||||
Next
|
||||
|
||||
Dim CvePSGRupos As String = Left(CvePSGRuposAux.ToString, CvePSGRuposAux.Length - 1)
|
||||
If CvePSGRuposAux.Length > 0 Then
|
||||
Dim CvePSGRupos As String = Left(CvePSGRuposAux.ToString, CvePSGRuposAux.Length - 1)
|
||||
|
||||
Dim PSSat As DataTable = GlobalDTPS(UsuarioActual.CveEmpresa).FiltraParametros(String.Format("CvePS IN ({0})", CvePSGRuposAux))
|
||||
Dim PSSat As DataTable = GlobalDTPS(UsuarioActual.CveEmpresa).FiltraParametros(String.Format("CvePS IN ({0})", CvePSGRuposAux))
|
||||
|
||||
Dim ProductosCodigoSATNoPermitidos As New StringBuilder("")
|
||||
For Each PS As GridViewRow In GvPS.Rows
|
||||
Dim PSIndividual As String = PS.DataKey("PS")
|
||||
Dim ClavePSSAT As String = PSSat.FiltroPrimeroValor("CveSATPS", String.Format("PS = '{0}'", PSIndividual))
|
||||
If ClavePSSAT = "46920" Then
|
||||
ProductosCodigoSATNoPermitidos.AppendFormat("{0}</br>", PSIndividual)
|
||||
Dim ProductosCodigoSATNoPermitidos As New StringBuilder("")
|
||||
For Each PS As GridViewRow In GvPS.Rows
|
||||
Dim PSIndividual As String = PS.DataKey("PS")
|
||||
Dim ClavePSSAT As String = PSSat.FiltroPrimeroValor("CveSATPS", String.Format("PS = '{0}'", PSIndividual))
|
||||
If ClavePSSAT = "46920" Then
|
||||
ProductosCodigoSATNoPermitidos.AppendFormat("{0}</br>", PSIndividual)
|
||||
End If
|
||||
Next
|
||||
|
||||
If ProductosCodigoSATNoPermitidos.ToString.Length > 0 Then
|
||||
Dim mensajeAdvertencia As String = String.Format("No se permite vinculación de productos con código SAT '01010101', revise los productos:</br></br>{0}", ProductosCodigoSATNoPermitidos.ToString)
|
||||
Alert(mensajeAdvertencia, TipoMensaje.MsgAdvertencia)
|
||||
Return False
|
||||
End If
|
||||
Next
|
||||
|
||||
If ProductosCodigoSATNoPermitidos.ToString.Length > 0 Then
|
||||
Dim mensajeAdvertencia As String = String.Format("No se permite vinculación de productos con código SAT '01010101', revise los productos:</br></br>{0}", ProductosCodigoSATNoPermitidos.ToString)
|
||||
Alert(mensajeAdvertencia, TipoMensaje.MsgAdvertencia)
|
||||
Return False
|
||||
End If
|
||||
|
||||
Return True
|
||||
|
||||
Reference in New Issue
Block a user