Cambios en folios de garantia
This commit is contained in:
@@ -455,7 +455,7 @@
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtConsecutivoAjuste" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
|
||||
<asp:TextBox ID="TxtConsecutivoAjuste" CssClass="form-control" runat="server" MaxLength="25" AutoPostBack="true"></asp:TextBox>
|
||||
<%--<asp:RequiredFieldValidator ID="RFVConsecutivoAjuste" runat="server" ControlToValidate="TxtConsecutivoAjuste" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Consec.''</b> es necesario, por favor ingréselo." ValidationGroup="VGMAjuste"></asp:RequiredFieldValidator>
|
||||
<%--<ajax:ValidatorCalloutExtender ID="VCEConsecutivoAjuste" runat="server" HighlightCssClass="vco" TargetControlID="RFVConsecutivoAjuste"></ajax:ValidatorCalloutExtender>--%>
|
||||
<%--<label for="<%= TxtConsecutivoAjuste.ClientID.ToString()%>">Consec.:</label>--%>
|
||||
|
||||
@@ -3258,6 +3258,11 @@ Partial Class Inventarios_RecepcionUsados
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not ValidaConsecutivo() Then
|
||||
Alert("Ya existe un consecutivo vigente en este folio", TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Dim ObjPS As New ClsProductosServicios
|
||||
Try
|
||||
Dim CveTamaño As Integer = -1
|
||||
@@ -3489,6 +3494,29 @@ Partial Class Inventarios_RecepcionUsados
|
||||
UpAjuste.Update()
|
||||
End Sub
|
||||
|
||||
Protected Sub TxtConsecutivoAjuste_TextChanged(sender As Object, e As EventArgs) Handles TxtConsecutivoAjuste.TextChanged
|
||||
If Not ValidaConsecutivo() Then
|
||||
Alert("Ya existe un consecutivo vigente en este folio", TipoMensaje.MsgAdvertencia)
|
||||
Exit Sub
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Function ValidaConsecutivo() As Boolean
|
||||
Dim Retorno As Boolean = True
|
||||
|
||||
If DdlFolioGarantia.SelectedValue.ToEntero() > 0 Then
|
||||
Using ObjAcum As New ClsAcumuladores
|
||||
If ObjAcum.GetFoliosGarantiasDetalle(DdlFolioGarantia.SelectedValue.ToEntero(), CveEstatusConsecutivo:=1, Consec:=TxtConsecutivoAjuste.Text.ToEntero()) Then
|
||||
If ObjAcum.DtResultados.Rows.Count > 0 Then
|
||||
Retorno = False
|
||||
End If
|
||||
End If
|
||||
End Using
|
||||
End If
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
#Region "P O L I Z A - V I R T U A L"
|
||||
Private Sub CreaDTmpDTPolizaVirtual()
|
||||
TmpDTPolizaVirtual = New DataTable
|
||||
|
||||
Reference in New Issue
Block a user