From 6444292d6c728bb4448b2e5d5294170294c98f15 Mon Sep 17 00:00:00 2001 From: Jonathan Alexis Perez Morales Date: Tue, 10 Mar 2020 19:50:00 -0700 Subject: [PATCH] seleccionar multiples marcas --- App_Code/ClsInventarios.vb | 4 +- Inventarios/KardexAlmacenHorizontal.aspx | 502 ++++++++++---------- Inventarios/KardexAlmacenHorizontal.aspx.vb | 40 +- 3 files changed, 271 insertions(+), 275 deletions(-) diff --git a/App_Code/ClsInventarios.vb b/App_Code/ClsInventarios.vb index 2a6016ebd..dcb5e33bb 100644 --- a/App_Code/ClsInventarios.vb +++ b/App_Code/ClsInventarios.vb @@ -1472,7 +1472,7 @@ Public Class ClsInventarios Return Retorno End Function - Public Function GetKardexAlmacenHorizontal(CvePS As Integer, FechaFin As Date, CveAlmacen As Integer, CveUnidadMedida As Integer, CveProveedor As Integer, CveTipoAlmacen As Integer, IncluyeTransitorios As Integer, CveClasificacion As Integer, CveUsuario As Integer, CveEmpresa As Integer, Optional CondicionExistencias As Integer = 0, Optional Orden As Integer = -1, Optional CveMarca As Integer = -1) As Boolean + Public Function GetKardexAlmacenHorizontal(CvePS As Integer, FechaFin As Date, CveAlmacen As Integer, CveUnidadMedida As Integer, CveProveedor As Integer, CveTipoAlmacen As Integer, IncluyeTransitorios As Integer, CveClasificacion As Integer, CveUsuario As Integer, CveEmpresa As Integer, Optional CondicionExistencias As Integer = 0, Optional Orden As Integer = -1, Optional Marcas As String = "-1") As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Inv_KardexAlmacenHorizontalGet") @@ -1491,7 +1491,7 @@ Public Class ClsInventarios .Add("@CveTipoAlmacen", SqlDbType.Int).Value = CveTipoAlmacen .Add("@ExistenciasCondicion", SqlDbType.Int).Value = CondicionExistencias .Add("@Orden", SqlDbType.Int).Value = Orden - .Add("@CveMarca", SqlDbType.Int).Value = CveMarca + .Add("@Marcas", SqlDbType.VarChar).Value = Marcas End With Try diff --git a/Inventarios/KardexAlmacenHorizontal.aspx b/Inventarios/KardexAlmacenHorizontal.aspx index f7338501b..f72ee33b9 100644 --- a/Inventarios/KardexAlmacenHorizontal.aspx +++ b/Inventarios/KardexAlmacenHorizontal.aspx @@ -1,254 +1,256 @@ -<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="KardexAlmacenHorizontal.aspx.vb" Inherits="Inventarios_KardexAlmacen" %> - - - - - - - - - - Kardex Almacén Horizontal - - - - - - -
  • - Generar Excel -
  • -
    - - - - - - - -
    -
    -
    - - "> - -
    -
    -
    -
    Proveedor
    -
    - -
    - -
    - -
    -
    -
    - -
    - - - -
    -
    -
    - -
    -
    -
    - - - - -
    - - -
    -
    - -
    - - - - -
    -
    -
    -
    -
    > -
    - -
    - - - -
    - -
    - - - -
    - -
    - -
    - -
    - - - -
    - -
    - - - - - - <%----%> -
    -
    - - -
    - - - - - - -
    -
    -
    -
    -
    -
    -
    - " style="display: inline-block; margin-right: -20px; width: 150px;" /> - " style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"> -
    - - - - - - + +
    - - - -
    -
    - - - - - - +<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="KardexAlmacenHorizontal.aspx.vb" Inherits="Inventarios_KardexAlmacen" %> + + + + + + + + + + Kardex Almacén Horizontal + + + + + + +
  • + Generar Excel +
  • +
    + + + + + + + +
    +
    +
    + + "> + +
    +
    +
    +
    Proveedor
    +
    + +
    + +
    + +
    + +
    +
    +
    + + + + +
    + + +
    +
    + +
    + + + + +
    +
    +
    +
    +
    > +
    + +
    + + + +
    + +
    + + + +
    + +
    + +
    + +
    + + + +
    + +
    + + + + + + <%----%> +
    +
    + + +
    + + + + + + +
    +
    +
    + +
    + + + +
    +
    +
    +
    +
    +
    +
    +
    +
    + " style="display: inline-block; margin-right: -20px; width: 150px;" /> + " style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"> +
    + + + + + + - -
    + + + +
    +
    + + + + + + Código - - -
    - -
    -
    -
    - - + + + +
    + +
    +
    +
    + + Producto - - -
    - -
    -
    -
    -
    -
    -
    -
    -
    -
    - - - + +
    + +
    + +
    +
    +
    +
    +
    +
    +
    +
    +
    + + + diff --git a/Inventarios/KardexAlmacenHorizontal.aspx.vb b/Inventarios/KardexAlmacenHorizontal.aspx.vb index f3ca82ff8..2b5325e8f 100644 --- a/Inventarios/KardexAlmacenHorizontal.aspx.vb +++ b/Inventarios/KardexAlmacenHorizontal.aspx.vb @@ -22,9 +22,6 @@ Partial Class Inventarios_KardexAlmacen ddlProducto2.SelectedValue = If(Request("CvePS") IsNot Nothing, Request("CvePS").ToString, "-1") End If End Sub - Private Function isWithFamily() As Boolean - Return (UsuarioActual.CveEmpresa = 66) - End Function Private Sub CargaCombos() CargaFuncionalidad105() @@ -55,25 +52,21 @@ Partial Class Inventarios_KardexAlmacen End Sub Private Sub CargaClasificaciones() - Dim CveClasificacion = If(Request("CveClasificacion") IsNot Nothing, Request("CveClasificacion").ToString, "-1") - - If isWithFamily() Then - DdlClasificacion.DataSource = GlobalDTSubFamilias(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion") - Else - Dim ObjClasificaciones As New ClsClasificaciones - If UsuarioActual.Empresa.UsaAC Then - If ObjClasificaciones.GetClasificacionesExistencias(UsuarioActual.CveEmpresa) Then - DdlClasificacion.DataSource = ObjClasificaciones.DtResultados - DdlClasificacion.DataBind() - End If - Else - If ObjClasificaciones.GetClasificacionesExistencias(UsuarioActual.CveEmpresa) Then - DdlClasificacion.DataSource = ObjClasificaciones.DtResultados - DdlClasificacion.DataBind() - End If - End If - ObjClasificaciones.Dispose() - End If + Dim CveClasificacion = If(Request("CveClasificacion") IsNot Nothing, Request("CveClasificacion").ToString, "-1") + + Dim ObjClasificaciones As New ClsClasificaciones + If UsuarioActual.Empresa.UsaAC Then + If ObjClasificaciones.GetClasificacionesExistencias(UsuarioActual.CveEmpresa) Then + DdlClasificacion.DataSource = ObjClasificaciones.DtResultados + DdlClasificacion.DataBind() + End If + Else + If ObjClasificaciones.GetClasificacionesExistencias(UsuarioActual.CveEmpresa) Then + DdlClasificacion.DataSource = ObjClasificaciones.DtResultados + DdlClasificacion.DataBind() + End If + End If + ObjClasificaciones.Dispose() DdlClasificacion.DataBind() DdlClasificacion.SelectedValueExist(CveClasificacion) @@ -139,8 +132,9 @@ Partial Class Inventarios_KardexAlmacen Dim FechaF As Date = TxtFechaF.Text.ToDate Dim CveAlmacen As Integer = ddlAlmacen.SelectedValue.ToEntero Dim CveProveedorCompra As Integer = If(DdlProveedor.SelectedValue.ToEntero > 0, DdlProveedor.SelectedValue.ToEntero, -1) + Dim Marcas As String = If(DdlMarca.GetSelectedValuesM = "", "-1", DdlMarca.GetSelectedValuesM) - If ObjMovimientos.GetKardexAlmacenHorizontal(CvePS, FechaF, CveAlmacen, DdlUnidadMedida.SelectedValue.ToEntero, CveProveedorCompra, DdlTipoAlmacen.SelectedValue.ToEntero(), DdlIncluyeTransitorios.SelectedValue.ToEntero(), DdlClasificacion.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CondicionExistencias:=DdlExistencia.SelectedValue, Orden:=DdlOrden.SelectedValue.ToEntero(), CveMarca:=DdlMarca.SelectedValue.ToEntero()) Then + If ObjMovimientos.GetKardexAlmacenHorizontal(CvePS, FechaF, CveAlmacen, DdlUnidadMedida.SelectedValue.ToEntero, CveProveedorCompra, DdlTipoAlmacen.SelectedValue.ToEntero(), DdlIncluyeTransitorios.SelectedValue.ToEntero(), DdlClasificacion.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CondicionExistencias:=DdlExistencia.SelectedValue, Orden:=DdlOrden.SelectedValue.ToEntero(), Marcas:=Marcas) Then If ObjMovimientos.DtResultados IsNot Nothing AndAlso ObjMovimientos.DtResultados.Rows.Count > 0 Then dt = ObjMovimientos.DtResultados Dim ListaBorrar As New List(Of DataColumn)