-- mejora es RSCO

This commit is contained in:
2022-08-16 22:02:44 -07:00
parent 5aed8fa593
commit 511f71de49
4 changed files with 27 additions and 34 deletions

View File

@@ -5963,7 +5963,7 @@ Public Class ClsInventarios
Public Function RepCompuestosVigencia(CveCompuesto As Integer, CveProveedor As Integer, FechaI As Date, FechaF As Date, VigenciaIndeterminada As Boolean, CveEmpresa As Integer, Optional ConCaducidad As Boolean = False) As Boolean
Public Function RepCompuestosVigencia(CveCompuesto As Integer, CveProveedor As Integer, FechaI As Date, FechaF As Date, VigenciaIndeterminada As Boolean, CveEmpresa As Integer, CveAlmacen As Integer, CveUsuario As Integer, Optional ConCaducidad As Boolean = False) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_CompuestosVigenciaRep")
@@ -5975,9 +5975,10 @@ Public Class ClsInventarios
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@VigenciaIndeterminada", SqlDbType.Int).Value = VigenciaIndeterminada
.Add("@CveAlmacen", SqlDbType.Int).Value = CveAlmacen
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@ConCaducidad", SqlDbType.Bit).Value = ConCaducidad
.Add("@ConCaducidad", SqlDbType.Bit).Value = If(ConCaducidad, 1, 0)
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
End With
Try

View File

@@ -179,6 +179,7 @@
<asp:BoundField HeaderText="Almacén" DataField="Almacen" ItemStyle-Width="160px" />
<asp:BoundField HeaderText="Cantidad" DataField="Cantidad" DataFormatString="{0:#,###.##}" ItemStyle-Width="80px" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField HeaderText="Producto" DataField="CodigoPS" />
<asp:BoundField HeaderText="Compuesto" DataField="Compuesto" />
<asp:BoundField HeaderText="Lote" DataField="Lote" ItemStyle-Width="150px" />
<asp:BoundField HeaderText="Fecha Caducidad" DataField="FechaCaducidad" DataFormatString = "{0:dd/MM/yyyy}" ItemStyle-Width="90px" />
<asp:TemplateField ItemStyle-Width="90px" ItemStyle-HorizontalAlign="Right" HeaderText="Días de Cad." Visible="false">

View File

@@ -90,41 +90,35 @@
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
</div>
<div class="portlet-body" style="display: none">
<div class="portlet-body" style="display: none">
<div class="row">
<label class="col-md-1 truncate" style="text-align:right">Almacén:</label>
<div class="col-md-1">
<asp:ListBox ID="ddlAlmacen" data-text="Todos" AppendDataBoundItems="true" CssClass="input-sm select2me Widthall" Style="width: 100%;" runat="server" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:ListBox>
</div>
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<br />
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False"
EmptyDataText="No se Encontraron Registros" ToolTip="Listado de Unidades" CssClass="table table-striped table-advance table-hover mysmallbtn " data-sort="true" Style="width: 100%" GridLines="None">
EmptyDataText="No se Encontraron Registros" ToolTip="Listado de Unidades" CssClass="table table-striped table-advance table-hover mysmallbtn ScrollAD " data-sort="true" Style="width: 100%" GridLines="None">
<Columns>
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Clasificacion" DataField="Clasificacion" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Producto" DataField="CodigoPS" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Compuesto" DataField="Compuesto" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Registro RSCO" DataField="RegistroRSCO" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Fecha. Vigencia" ItemStyle-HorizontalAlign="Center" DataField="FechaVigenciaRSCOStr" />
<asp:BoundField HeaderText="Usuario" DataField="Usuario" />
<asp:BoundField HeaderText="Fecha Ing." ItemStyle-HorizontalAlign="Center" DataField="Fecha" ItemStyle-Width="5%" DataFormatString="{0:d}" />
<asp:BoundField HeaderText="Proveedor" DataField="NombreComercial" />
<asp:BoundField HeaderText="Clasificacion" DataField="Clasificacion" />
<asp:BoundField HeaderText="Producto" DataField="CodigoPS" />
<asp:BoundField HeaderText="Compuesto" DataField="Compuesto" />
<asp:BoundField HeaderText="Registro RSCO" DataField="RegistroRSCO" ItemStyle-Width="200px" />
<asp:BoundField HeaderText="Fecha. Vigencia" DataField="FechaVigenciaRSCOStr" />
</Columns>
</asp:GridView>
</ContentTemplate>

View File

@@ -36,7 +36,7 @@ Partial Class Inventarios_RepRSCO
LnkDescargaExcel.Visible = False
If ObjInventarios.RepCompuestosVigencia(DdlCompuesto.SelectedValue.ToEntero, DdlProveedores.SelectedValue.ToEntero, txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, 1, UsuarioActual.CveEmpresa) Then
If ObjInventarios.RepCompuestosVigencia(DdlCompuesto.SelectedValue.ToEntero, DdlProveedores.SelectedValue.ToEntero, txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, 1, UsuarioActual.CveEmpresa, ddlAlmacen.SelectedValue.ToEntero, UsuarioActual.CveUsuario) Then
DTDatos = ObjInventarios.DtResultados
GvDatos.DataSource = DTDatos
@@ -63,6 +63,10 @@ Partial Class Inventarios_RepRSCO
DdlProveedores.SelectedText = "Todos"
DdlProveedores.SelectedValue = "-1"
ddlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
ddlAlmacen.DataBind()
ddlAlmacen.Items.Insert(0, New ListItem("Todos", "-1"))
ddlAlmacen.SelectedValue = "-1"
Dim ObjPS As New ClsProductosServicios
@@ -80,15 +84,8 @@ Partial Class Inventarios_RepRSCO
txtFechaF.Text = Now.ToString("dd/MM/yyyy")
txtFechaI.Text = txtFechaF.Text.ToDate.AddMonths(-2).ToString("dd/MM/yyyy")
End Sub
Protected Sub LnkDescargaExcel_Click(sender As Object, e As EventArgs)
ImprimirReporte("EXCEL")
End Sub