Correcion en catalogo de subtipos de AF

This commit is contained in:
2023-03-29 11:10:58 -07:00
parent 1233c1d0b4
commit e155bd3391
3 changed files with 12 additions and 11 deletions

View File

@@ -52,8 +52,8 @@
</thead>
<tr>
<td>
<asp:DropDownList ID="DdlTipos" runat="server" AppendDataBoundItems="true" DataValueField="CveTipoActivoFijo" DataTextField="TipoActivoFijo" ValidationGroup="GrpGuardar" Width="190px">
<asp:ListItem Selected="True" Text="Seleccione" Value="-1"></asp:ListItem>
<asp:DropDownList ID="DdlTipos" runat="server" DataValueField="CveTipoActivoFijo" DataTextField="TipoActivoFijo" ValidationGroup="GrpGuardar" Width="190px">
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVTipos" runat="server" ControlToValidate="DdlTipos" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipos''</b> es necesario, por favor ingréselo." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCOTipos" runat="server" HighlightCssClass="vco" TargetControlID="RFVTipos" Width="300px"></ajax:ValidatorCalloutExtender>

View File

@@ -18,8 +18,10 @@ Partial Class AF_CatSubTipos
End Sub
Private Sub CargaTipos()
DdlTipos.Items.Clear()
DdlTipos.DataSource = GlobalDTTipoActivoFijo(UsuarioActual.CveEmpresa) '.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
DdlTipos.DataBind()
DdlTipos.Items.Insert(0, New ListItem("Seleccione", "-1"))
End Sub
Private Sub CargaGlobal()
@@ -46,7 +48,6 @@ Partial Class AF_CatSubTipos
Else
CargaGrid("")
End If
CargaGlobal()
End Sub
#Region "G V D A T O S"
@@ -93,6 +94,7 @@ Partial Class AF_CatSubTipos
End If
If Not TieneError Then
CargaGlobal()
CargaDatos()
End If
End Sub
@@ -134,6 +136,7 @@ Partial Class AF_CatSubTipos
End If
If Not TieneError Then
CargaGlobal()
CargaDatos()
End If
End Sub
@@ -200,6 +203,8 @@ Partial Class AF_CatSubTipos
ObjAF.Dispose()
If Not TieneError Then
CargaGlobal()
CargaDatos()
End If

View File

@@ -104,11 +104,7 @@ Partial Class AF_CatTipos
UpDatos.Update()
End Sub
Private Sub CargaGlobal()
Dim ObjTipo As New ClsAF
If ObjTipo.GetTiposActivosFijos(-1) Then
GlobalDTTipoActivoFijo(-1) = ObjTipo.DtResultados
End If
ObjTipo.Dispose()
GlobalDTTipoActivoFijo(UsuarioActual.CveEmpresa) = Nothing
End Sub
#Region " G V - D A T O S"