Mostrar ddl PS y filtrar por clasificacion
This commit is contained in:
@@ -152,10 +152,11 @@
|
|||||||
<asp:DropDownList ID="DdlClasificacion" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="Clasificacion" DataValueField="CveClasificacion" Width="95%">
|
<asp:DropDownList ID="DdlClasificacion" runat="server" CssClass=" form-control input-sm select2me" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="Clasificacion" DataValueField="CveClasificacion" Width="95%">
|
||||||
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
||||||
</asp:DropDownList>
|
</asp:DropDownList>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-1" style="display:none;">Producto Servicio:</div>
|
|
||||||
|
<div class="col-md-1">Producto Servicio:</div>
|
||||||
<div class="col-md-2">
|
<div class="col-md-2">
|
||||||
<ADS:Dropdownlost runat="server" ID="DdlPS" CssStyle="width: 100%;" CssClassDdl="select2me" DataTextField="PSCodigo" DataValueField="CvePS" Width="95%" />
|
<ADS:Dropdownlost runat="server" ID="DdlPS" CssStyle="width: 100%;" CssClassDdl="select2me" DataTextField="PSCodigo" DataValueField="CvePS" Width="95%" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ Partial Class Compras_RepComprasAF
|
|||||||
Private Sub Compras_RepComprasAFaspx_Load(sender As Object, e As EventArgs) Handles Me.Load
|
Private Sub Compras_RepComprasAFaspx_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||||
If Not IsPostBack Then
|
If Not IsPostBack Then
|
||||||
CargaCombos()
|
CargaCombos()
|
||||||
DdlPS.ddl.Visible = False
|
'DdlPS.ddl.Visible = False
|
||||||
If UsuarioActual.Empresa.GralSoloProyecto Then
|
If UsuarioActual.Empresa.GralSoloProyecto Then
|
||||||
LblSubProyecto.Text = "Proyecto:"
|
LblSubProyecto.Text = "Proyecto:"
|
||||||
DdlSubProyecto.Items.Clear()
|
DdlSubProyecto.Items.Clear()
|
||||||
@@ -429,5 +429,24 @@ Partial Class Compras_RepComprasAF
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
Protected Sub DdlClasificacion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClasificacion.SelectedIndexChanged
|
||||||
|
CargaPS(DdlClasificacion.SelectedValue.ToEntero)
|
||||||
|
End Sub
|
||||||
|
Private Sub CargaPS(CveClasificacion As Integer)
|
||||||
|
|
||||||
|
DdlPS.setEsWebService(If(UsuarioActual.Empresa.Funcionalidad(105).ToString = "1", True, False))
|
||||||
|
|
||||||
|
If Not UsuarioActual.Empresa.Funcionalidad(105).ToString = "1" Then
|
||||||
|
DdlPS.ddl.Items.Clear()
|
||||||
|
DdlPS.ddl.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=CveClasificacion, Estatus:=1)
|
||||||
|
DdlPS.ddl.DataBind()
|
||||||
|
DdlPS.ddl.Items.Insert(0, New ListItem("*** Actualizar listado de Productos o Servicios ***", "-2"))
|
||||||
|
DdlPS.ddl.Items.Insert(0, New ListItem("Seleccione el Producto", "-1"))
|
||||||
|
Else
|
||||||
|
DdlPS.ddlWS.Attributes.Add("data-cveclasificacion", DdlClasificacion.SelectedValue)
|
||||||
|
DdlPS.SelectedText = "Todos"
|
||||||
|
DdlPS.SelectedValue = "-1"
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -448,4 +448,24 @@ Partial Class Compras_RepComprasAFDetalle
|
|||||||
|
|
||||||
Return filtro
|
Return filtro
|
||||||
End Function
|
End Function
|
||||||
|
Protected Sub DdlClasificacion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClasificacion.SelectedIndexChanged
|
||||||
|
CargaPS(DdlClasificacion.SelectedValue.ToEntero)
|
||||||
|
End Sub
|
||||||
|
Private Sub CargaPS(CveClasificacion As Integer)
|
||||||
|
|
||||||
|
DdlPS.setEsWebService(If(UsuarioActual.Empresa.Funcionalidad(105).ToString = "1", True, False))
|
||||||
|
|
||||||
|
If Not UsuarioActual.Empresa.Funcionalidad(105).ToString = "1" Then
|
||||||
|
DdlPS.ddl.Items.Clear()
|
||||||
|
DdlPS.ddl.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=CveClasificacion, Estatus:=1)
|
||||||
|
DdlPS.ddl.DataBind()
|
||||||
|
DdlPS.ddl.Items.Insert(0, New ListItem("*** Actualizar listado de Productos o Servicios ***", "-2"))
|
||||||
|
DdlPS.ddl.Items.Insert(0, New ListItem("Seleccione el Producto", "-1"))
|
||||||
|
Else
|
||||||
|
DdlPS.ddlWS.Attributes.Add("data-cveclasificacion", DdlClasificacion.SelectedValue)
|
||||||
|
DdlPS.SelectedText = "Todos"
|
||||||
|
DdlPS.SelectedValue = "-1"
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
Reference in New Issue
Block a user