Correción Compras Aplica Lote ps no encontrado, Vya Contrato Contrato detalle mensajes
This commit is contained in:
@@ -11135,8 +11135,15 @@ Partial Class Compras_Compras
|
||||
dRow("UUIDRow") = Guid.NewGuid().ToString()
|
||||
End If
|
||||
Dim CvePS As Integer = dRow("CvePS").ToString.ToEntero
|
||||
dRow("AplicaLote") = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaLote", $"CvePS={CvePS}"))
|
||||
dRow("AplicaCaducidad") = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaCaducidad", $"CvePS={CvePS}"))
|
||||
|
||||
dRow("AplicaLote") = False
|
||||
dRow("AplicaCaducidad") = False
|
||||
|
||||
If CvePS > 0 Then
|
||||
dRow("AplicaLote") = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaLote", $"CvePS={CvePS}"))
|
||||
dRow("AplicaCaducidad") = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaCaducidad", $"CvePS={CvePS}"))
|
||||
End If
|
||||
|
||||
Next
|
||||
TmpDT.AcceptChanges()
|
||||
|
||||
@@ -11229,8 +11236,14 @@ Partial Class Compras_Compras
|
||||
|
||||
Dim CvePS As Integer = e.Row.DataKey("CvePS").ToEntero
|
||||
|
||||
Dim AplicaLote As Boolean = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaLote", $"CvePS={CvePS}"))
|
||||
Dim AplicaCaducidad As Boolean = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaCaducidad", $"CvePS={CvePS}"))
|
||||
Dim AplicaLote As Boolean = False
|
||||
Dim AplicaCaducidad As Boolean = False
|
||||
|
||||
If CvePS > 0 Then
|
||||
AplicaLote = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaLote", $"CvePS={CvePS}"))
|
||||
AplicaCaducidad = Boolean.Parse(GlobalDTPSSimplificado(UsuarioActual.CveEmpresa).FiltroPrimeroValor("AplicaCaducidad", $"CvePS={CvePS}"))
|
||||
End If
|
||||
|
||||
|
||||
If AplicaLote Then
|
||||
e.Row.FCTextBox("TxtLote").Visible = True
|
||||
|
||||
@@ -541,6 +541,8 @@ Partial Class RepContratoDetalle
|
||||
Protected Sub UpdateContrato(sender As Object, e As EventArgs)
|
||||
Dim ArchivoUpdate As String = "-1"
|
||||
Dim ErrorProceso As Boolean = False
|
||||
Dim SeGeneroRemision As Boolean = False
|
||||
Dim SerieFolioRemision As String = ""
|
||||
If Session("FileExtension").ToString <> "" Then
|
||||
|
||||
'ArchivoUpdate = $"{CveContrato.ToString}.{ Session("FileExtension")}"
|
||||
@@ -584,8 +586,9 @@ Partial Class RepContratoDetalle
|
||||
|
||||
If Respuesta.CveVenta > 0 Then
|
||||
CveVentaRemision = Respuesta.CveVenta
|
||||
'SerieFolioRemision = Respuesta.SerieFolio
|
||||
SerieFolioRemision = Respuesta.SerieFolio
|
||||
ErrorProceso = False
|
||||
SeGeneroRemision = True
|
||||
Else
|
||||
ErrorProceso = True
|
||||
Alert("se presento un error al generar la remisión", TipoMensaje.MsgAdvertencia)
|
||||
@@ -593,10 +596,16 @@ Partial Class RepContratoDetalle
|
||||
End If
|
||||
|
||||
If Not ErrorProceso Then
|
||||
|
||||
ObjContratos.Commit()
|
||||
AgregarABitacora($"Actualización del contrato {CveContrato}")
|
||||
Alert("Contrato actualizado correctamente")
|
||||
|
||||
If SeGeneroRemision Then
|
||||
Alert($"Contrato actualizado correctamente..<br> Remisión Generada <a target='_blank' class='Texto' href='/Ventas/Ventas.aspx?CveVenta={CveVentaRemision}' ><b>{SerieFolioRemision}</b></a>", TipoMensaje.MsgInformacion, "window.location.reload();")
|
||||
Else
|
||||
Alert("Contrato actualizado correctamente", TipoMensaje.MsgInformacion, "window.location.reload();")
|
||||
End If
|
||||
|
||||
|
||||
Else
|
||||
Alert("Ocurrió un ocurrió un error al actualizar su boleto", TipoMensaje.MsgError)
|
||||
ObjContratos.RollBack()
|
||||
|
||||
@@ -211,7 +211,13 @@ Partial Class ListadoContratos
|
||||
|
||||
If Not ErrorProceso Then
|
||||
ObjContratos.Commit()
|
||||
Alert($"Agregado Correctamente.<br> Remisión Generada <a target='_blank' class='Texto' href='/Ventas/Ventas.aspx?CveVenta={CveVentaRemision}' ><b>{SerieFolioRemision}</b></a>")
|
||||
|
||||
If CveVentaRemision > 0 Then
|
||||
Alert($"Agregado Correctamente.<br> Remisión Generada <a target='_blank' class='Texto' href='/Ventas/Ventas.aspx?CveVenta={CveVentaRemision}' ><b>{SerieFolioRemision}</b></a>")
|
||||
Else
|
||||
Alert($"Agregado Correctamente")
|
||||
End If
|
||||
|
||||
Else
|
||||
ObjContratos.RollBack()
|
||||
Alert("Se presento un error al guardar el contrato.", TipoMensaje.MsgAdvertencia)
|
||||
|
||||
Reference in New Issue
Block a user