Tareas varias

This commit is contained in:
2019-09-10 18:11:50 -07:00
parent 0213d4a945
commit 0e24e74e4d
9 changed files with 1627 additions and 1460 deletions

View File

@@ -300,7 +300,8 @@ Public Class ClsInventarios
Return Retorno
End Function
Public Function GetRepAlmacenes(FechaInicio As String, FechaFin As String, CveEmpresa As Integer, CveTipoAlmacen As String, Contabilizable As Integer, Inventariable As Boolean, Optional SoloMovimientosContables As Boolean = False) As Boolean
Public Function GetRepAlmacenes(FechaInicio As String, FechaFin As String, CveEmpresa As Integer, CveTipoAlmacen As String, Contabilizable As Integer, Inventariable As Boolean,
Optional SoloMovimientosContables As Boolean = False, Optional Almacenes As String = "-1", Optional CveSubProyecto As Integer = -1) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Inv_AlmacenesRepGet")
@@ -311,7 +312,9 @@ Public Class ClsInventarios
.Add("@CveTipoAlmacen", SqlDbType.VarChar).Value = CveTipoAlmacen
.Add("@Inventariable", SqlDbType.Bit).Value = Inventariable
.Add("@SoloMovimientosContables", SqlDbType.Bit).Value = SoloMovimientosContables
.Add("@Modalidad", SqlDbType.Int).Value = Contabilizable
.Add("@Modalidad", SqlDbType.Int).Value = Contabilizable
.Add("@Almacenes", SqlDbType.VarChar).Value = Almacenes
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
End With
Try
SqlAdapter.Fill(Data)
@@ -2415,15 +2418,15 @@ Public Class ClsInventarios
Return Retorno
End Function
Public Function GetInventarioFisicoDetalle(CveInventarioFisico As Integer, CveUsuario As Integer) As Boolean
Public Function GetInventarioFisicoDetalle(CveInventarioFisico As Integer, CveUsuario As Integer, Optional Agrupar As Boolean = False) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Inv_InventarioFisicoDetalleGet")
With SqlAdapter.SelectCommand.Parameters
.Add("@CveInventarioFisico", SqlDbType.Int).Value = CveInventarioFisico
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@Agrupar", SqlDbType.Bit).Value = Agrupar
End With
Try
@@ -2438,10 +2441,10 @@ Public Class ClsInventarios
End Try
Return Retorno
End Function
End Function
#End Region
#Region "I N V E N T A R I O - F I S I C O - R E S U L T A D O"
Public Function AddInventarioFisicoResultados(CveInventarioFisico As Integer, CveUsuario As Integer) As Boolean
Dim Retorno As Boolean = False

View File

@@ -380,7 +380,6 @@
<asp:Literal ID="LtlDescrip" runat="server" Text='<%# Eval("Descripcion", "<div>{0}</div>")%>'></asp:Literal>
<span style='display: none'><%# Eval("RazonSocial")%></span>
</ItemTemplate>
<HeaderTemplate>
<div>
<asp:LinkButton ID="LbMoneda_RazonSocial" runat="server" CausesValidation="false" Text="Proveedor" OnClick="LbOrden_Click" CommandArgument="Moneda,RazonSocial"></asp:LinkButton>&nbsp;<asp:ImageButton ID="ImgMoneda_RazonSocial" runat="server" CausesValidation="false" ImageUrl="/Imagenes/FlechasAbajo.gif" OnClick="LbOrden_Click" CommandArgument="Moneda,RazonSocial" />/<asp:LinkButton ID="LbMoneda_OrdenMonedaProveedor_SerieFolio" runat="server" CausesValidation="false" Text="Factura" OnClick="LbOrden_Click" CommandArgument="Moneda,OrdenMonedaProveedor,SerieFolio"></asp:LinkButton>&nbsp;<asp:ImageButton ID="ImgMoneda_OrdenMonedaProveedor_SerieFolio" runat="server" CausesValidation="false" ImageUrl="/Imagenes/FlechasAbajo.gif" OnClick="LbOrden_Click" CommandArgument="Moneda,OrdenMonedaProveedor,SerieFolio" />

View File

@@ -3,10 +3,10 @@ Imports Extensiones
Imports Microsoft.Reporting.WebForms
Partial Class Bancos_RepProgramarRecursos
Inherits ClsPaginas
Inherits ClsPaginas
#Region "P R O P I E D A D E S"
Private Property DtDatos As DataTable
Get
Return CType(ViewState("DtDatos"), DataTable)
@@ -80,9 +80,9 @@ Partial Class Bancos_RepProgramarRecursos
Set(value As String)
ViewState("UsuarioProgramo") = value
End Set
End Property
End Property
#End Region
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
DdlUsuarioProgramo.Visible = False
@@ -501,7 +501,6 @@ Partial Class Bancos_RepProgramarRecursos
Protected Sub BtnProgramar_Click(sender As Object, e As EventArgs) Handles BtnProgramar.Click
Dim CveUsuario As Integer = UsuarioActual.CveUsuario
If UsuarioActual.Empresa.Funcionalidad(138) = "1" Then
'Validación del SAT - DF 21/01/17
Dim Validada As Boolean = False
@@ -596,18 +595,18 @@ Partial Class Bancos_RepProgramarRecursos
MsgError &= "No se pudo programar la factura </br>"
End If
End If
Next
TxtCodigoP.Text = ""
Next
Comp.Dispose()
TxtCodigoP.Text = ""
If MsgError <> "" Then
Alert(MsgError, TipoMensaje.MsgError)
Else
Alert("La programación se guardó correctamente", TipoMensaje.MsgInformacion)
Alert("La programación se guardó correctamente", TipoMensaje.MsgInformacion)
EnviaCorreoNotificacion()
End If
Comp.Dispose()
CargaDatos()
'Recarga DdlUsuarioProgramo
@@ -623,6 +622,105 @@ Partial Class Bancos_RepProgramarRecursos
End If
ObjUsuarios.Dispose()
End Sub
Private Sub EnviaCorreoNotificacion()
If UsuarioActual.CveEmpresa = 13 Then
Dim strBody As New StringBuilder
Try
strBody.Append("<html xmlns=""http://www.w3.org/1999/xhtml""> ")
strBody.Append("<head> ")
strBody.Append(" <style type=""text/css""> ")
strBody.Append(" body ")
strBody.Append(" { ")
strBody.Append(" margin:0px; ")
strBody.Append(" padding:0px 0px 0px 0px; ")
strBody.Append(" font-family: Verdana, Arial, Helvetica, sans-serif; ")
strBody.Append(" font-size: 10px; ")
strBody.Append(" background-color:#F0F0F0; ")
strBody.Append(" } ")
strBody.Append(" a.Texto ")
strBody.Append(" { ")
strBody.Append(" font-size:11px; ")
strBody.Append(" background-color:#F7F6F3; ")
strBody.Append(" text-decoration:none; ")
strBody.Append(" font-weight:bold; ")
strBody.Append(" } ")
strBody.Append(" .Texto ")
strBody.Append(" { ")
strBody.Append(" background-color:#F7F6F3; color:Black; font-family:Verdana; font-size:10px; text-align:center; vertical-align:middle; height:20px;")
strBody.Append(" } ")
strBody.Append(" .TextoAlterno ")
strBody.Append(" { ")
strBody.Append(" background-color:White; color:Black; font-family:Verdana; font-size:10px; text-align:center; ")
strBody.Append(" vertical-align:middle; height:20px;")
strBody.Append(" } ")
strBody.Append(" .BarraIdentidad ")
strBody.Append(" { ")
strBody.Append(" color:#FFFFFF; ")
strBody.Append(" background:#F0F0F0; ")
strBody.Append(" font-weight:bold; ")
strBody.Append(" font-size:19px; ")
strBody.Append(" font-style:oblique; ")
strBody.Append(" } ")
strBody.Append(" .Titulos ")
strBody.Append(" { ")
strBody.Append(" background-color: Gray;")
strBody.Append(" color:White; ")
strBody.Append(" font-family:Verdana; font-size:12px; text-align:center; ")
strBody.Append(" vertical-align:middle; font-weight:bold; height:30px; ")
strBody.Append(" text-decoration:none; ")
strBody.Append(" } ")
strBody.Append(" .Verde {color: #00CC00;} ")
strBody.Append(" .Negro {color: #000000;} ")
strBody.Append(" .Rojo {color: #FF0000;} ")
strBody.Append(" </style> ")
strBody.Append("</head> ")
strBody.Append("<body> ")
'Cargo el detalle
strBody.Append(" <div style='width: 550px'> ")
strBody.Append(" <fieldset> ")
strBody.Append(" <legend>Compras Programadas</legend> ")
strBody.Append(" <table width=""550px""><tr style='background-color:gray;color:White;font-family:Verdana;font-size:10px;text-align:center;vertical-align:middle;font-weight:bold;height:20px;text-decoration:none;'>")
strBody.Append(" <th scope='col' style='width: 100px'>Serie-Folio</th> <th scope='col' style='width: 100px'>Fecha</th><th scope='col' style='width: 120px'>Importe</th><th scope='col' style='width: 100px'>Importe Programado</th></tr>")
For Each gvr As GridViewRow In Gv.Rows
If gvr.FCCheckBox("Chk").Checked Then
Dim SerieFolio = gvr.DataKey("SerieFolio")
Dim Importe = gvr.DataKey("Original").ToDouble.FormatoNumero()
Dim ImporteProgramo = gvr.FCTextBox("TxtS").Text.ToDouble.FormatoNumero()
strBody.Append($"<tr class='Texto'><td>{SerieFolio}</td><td>{DateTime.Now}</td><td style='text-align: right;'><span >{Importe}</span></td><td style='text-align: right;'>{ImporteProgramo}</td></tr>")
End If
Next
strBody.Append(" </table> ")
strBody.Append(" </fieldset> ")
strBody.Append(" </div> ")
strBody.Append("</body></html>")
Try
Dim Correo As String = "" '"rpenunuriv@hotmail.com"
'Rafael Peñuñuri
Dim ObjUsuarios As New ClsSisUsuarios
If ObjUsuarios.GetUsuarios(293) Then
If ObjUsuarios.DtResultados.Rows.Count > 0 Then
Correo = ObjUsuarios.DtResultados.Rows(0)("Correo").ToString()
End If
End If
ObjUsuarios.Dispose()
Dim Asunto As String = "SIG - Se programaron las siguientes facturas"
Dim Mail As New ClsSisMail()
Mail.SendMail(ClsPaginas.EmpresaNotificaciones, Correo, Asunto, strBody.ToString())
Catch ex As Exception
OnError("Ocurrió error al mandar MAIL por cambio de Estatus", ex)
End Try
Catch ex As Exception
OnError("Ocurrio un error al general el correo.", ex)
End Try
End If
End Sub
Protected Sub BtnConsultar_Click(sender As Object, e As EventArgs) Handles BtnConsultar.Click
CargaDatos()
End Sub
@@ -795,8 +893,8 @@ Partial Class Bancos_RepProgramarRecursos
End If
ObjMovimientos.Dispose()
End If
End Sub
End Sub
#Region "C R E D I T O S - V E N C I M I E N T O"
Private Sub CargaCreditosVencimiento()
Dim ObjCreditos As New ClsBancos
@@ -826,9 +924,9 @@ Partial Class Bancos_RepProgramarRecursos
End If
GvV.DataBind()
UPDatos.Update()
End Sub
End Sub
#End Region
End Class

File diff suppressed because it is too large Load Diff

View File

@@ -1,336 +1,342 @@
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="InventarioFisicoDetalle.aspx.vb" Inherits="Inventarios_InventarioFisicoDetalle" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
<style>
#C_TxtHoraInicio_picker {
position: fixed !important;
}
.grides > tbody > tr > td:nth-child(3), .grides > tbody > tr > td:nth-child(3) {
width: 250px;
}
#C_myhidenbutton {
display: none;
}
.psagregar {
width: 450px;
}
.psagregar > div.comboxes {
display: inline-block;
width: 400px;
}
.table-scrollable {
margin-top: 0px !important;
margin-bottom: 0px !important;
}
.Widthall {
width: 100% !important;
}
.dataTables_scrollHeadInner {
width: 100% !important;
background-color: #dddddd;
padding-left: 0px !important;
}
.dataTables_scrollFoot {
display: none;
position: static;
}
.table-scrollable {
margin: 0px !important;
}
.dataTables_scroll {
margin-bottom: 0px;
}
.table.dataTable {
margin-top: 0px !important;
}
.dataTables_scrollBody table th {
padding: 0px !important;
padding-right: 4px !important;
padding-left: 4px !important;
}
.sinlink td a {
pointer-events: none;
cursor: default;
color: black;
font-size: small;
}
.white a {
color: white !important;
}
.Derecha {
text-align: right;
}
.Izquierda {
text-align: left;
}
.SinColor th {
background-color: white;
}
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
<li>
<asp:LinkButton ID="btnFin" runat="server" Text="Finalizar" data-toggle="confirmation" data-popout="true" data-original-title="Finalizar el inventario" data-btn-ok-label="si" />
</li>
<li>
<asp:LinkButton ID="LBAvance" OnClick="LBAvance_Click" runat="server" Text="Ver Avance" Visible="false" />
</li>
<li>
<asp:LinkButton ID="LnkPDF" runat="server"><i class="fa fa-ad-pdf"></i> Imprimir PDF</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkExcel" runat="server"><i class="fa fa-ad-excel"></i> Imprimir EXCEL</asp:LinkButton>
</li>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
Inventario Físico Detalle
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<div class="row" style="margin-left: 0px; margin-right: 0px;">
<div class="col-md-6" style="max-width: 545px;">
<div class="portlet smmallpadding light bordered infomov">
<div class="portlet-title">
<div class="tools">
<a href="javascript:;" class="expand"></a>
</div>
<div class="caption uppercase" style="position: relative;">
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="InventarioFisicoDetalle.aspx.vb" Inherits="Inventarios_InventarioFisicoDetalle" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
<style>
#C_TxtHoraInicio_picker {
position: fixed !important;
}
.grides > tbody > tr > td:nth-child(3), .grides > tbody > tr > td:nth-child(3) {
width: 250px;
}
#C_myhidenbutton {
display: none;
}
.psagregar {
width: 450px;
}
.psagregar > div.comboxes {
display: inline-block;
width: 400px;
}
.table-scrollable {
margin-top: 0px !important;
margin-bottom: 0px !important;
}
.Widthall {
width: 100% !important;
}
.dataTables_scrollHeadInner {
width: 100% !important;
background-color: #dddddd;
padding-left: 0px !important;
}
.dataTables_scrollFoot {
display: none;
position: static;
}
.table-scrollable {
margin: 0px !important;
}
.dataTables_scroll {
margin-bottom: 0px;
}
.table.dataTable {
margin-top: 0px !important;
}
.dataTables_scrollBody table th {
padding: 0px !important;
padding-right: 4px !important;
padding-left: 4px !important;
}
.sinlink td a {
pointer-events: none;
cursor: default;
color: black;
font-size: small;
}
.white a {
color: white !important;
}
.Derecha {
text-align: right;
}
.Izquierda {
text-align: left;
}
.SinColor th {
background-color: white;
}
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
<li>
<asp:LinkButton ID="btnFin" runat="server" Text="Finalizar" data-toggle="confirmation" data-popout="true" data-original-title="Finalizar el inventario" data-btn-ok-label="si" />
</li>
<li>
<asp:LinkButton ID="LBAvance" OnClick="LBAvance_Click" runat="server" Text="Ver Avance" Visible="false" />
</li>
<li>
<asp:LinkButton ID="LnkPDF" runat="server"><i class="fa fa-ad-pdf"></i> Imprimir PDF</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkPDFResumido" runat="server"><i class="fa fa-ad-pdf"></i> Imprimir PDF</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkExcel" runat="server"><i class="fa fa-ad-excel"></i> Imprimir EXCEL</asp:LinkButton>
</li>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
Inventario Físico Detalle
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<div class="row" style="margin-left: 0px; margin-right: 0px;">
<div class="col-md-6" style="max-width: 545px;">
<div class="portlet smmallpadding light bordered infomov">
<div class="portlet-title">
<div class="tools">
<a href="javascript:;" class="expand"></a>
</div>
<div class="caption uppercase" style="position: relative;">
<i class="fa fa-info-circle"></i>Información del movimiento
</div>
</div>
<div class="portlet-body">
<table>
<tr>
<td class="col-md-4">
<label><b>Título: </b></label>
<asp:Label ID="lbTitulo" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>SubProyecto: </b></label>
<asp:Label ID="lbSubProyecto" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Estatus: </b></label>
<asp:Label ID="lbEstatus" runat="server"></asp:Label>
</td>
</tr>
<tr>
<td class="col-md-4">
<label><b>Fecha Inicio: </b></label>
<asp:Label ID="lbFechaI" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Fecha Fin: </b></label>
<asp:Label ID="lbFechaF" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Usuario: </b></label>
<asp:DropDownList ID="ddlUsuario" AutoPostBack="true" runat="server" AppendDataBoundItems="true" Class="form-control input-sm select2me" Style="width: 141px !important;" DataTextField="Nombre" DataValueField="CveUsuario">
<asp:ListItem Text="Todos" Value="-1"></asp:ListItem>
</asp:DropDownList>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Almacenes:</b></label>&nbsp;<asp:Label ID="LblAlmacenes" runat="server" Text=""></asp:Label>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Clasificaciones:</b></label>&nbsp;<asp:Label ID="LblClasif" runat="server" Text="Todas"></asp:Label>
<br />
&nbsp;&nbsp;&nbsp;<label><b>Clasificaciones Excluidas:</b></label>&nbsp;<asp:Label ID="LblClasificacionesExcluidas" runat="server" Text=""></asp:Label>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Productos:</b></label>&nbsp;<asp:Label ID="LblProductos" runat="server" Text="Todos"></asp:Label>
<br />
&nbsp;&nbsp;&nbsp;<label><b>Productos Excluidos:</b></label>&nbsp;<asp:Label ID="LblProductosExcluidos" runat="server" Text=""></asp:Label>
</td>
</tr>
</table>
<table>
<tr>
<td class="col-md-12" style="width: 500px;">
<label><b>Observaciones: </b></label>
<asp:Label ID="lbObservaciones" runat="server" Style="width: 450px;"></asp:Label>
</td>
</tr>
</table>
</div>
</div>
</div>
<div class="col-md-3" id="PAgregar" runat="server">
<asp:UpdatePanel ID="UPAgregarPro" runat="server" RenderMode="Inline" ViewStateMode="Inherit" UpdateMode="Conditional">
<ContentTemplate>
<asp:Panel ID="PnlII" runat="server" DefaultButton="BtnGuardar">
<div class="portlet smmallpadding light bordered" id="DivCodigoBarras" runat="server">
<div class="portlet-title">
<div class="tools">
<a href="javascript:;" class="collapse"></a>
</div>
<div class="caption uppercase" style="position: relative;">
</div>
</div>
<div class="portlet-body">
<table>
<tr>
<td class="col-md-4">
<label><b>Título: </b></label>
<asp:Label ID="lbTitulo" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>SubProyecto: </b></label>
<asp:Label ID="lbSubProyecto" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Estatus: </b></label>
<asp:Label ID="lbEstatus" runat="server"></asp:Label>
</td>
</tr>
<tr>
<td class="col-md-4">
<label><b>Fecha Inicio: </b></label>
<asp:Label ID="lbFechaI" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Fecha Fin: </b></label>
<asp:Label ID="lbFechaF" runat="server"></asp:Label>
</td>
<td class="col-md-4">
<label><b>Usuario: </b></label>
<asp:DropDownList ID="ddlUsuario" AutoPostBack="true" runat="server" AppendDataBoundItems="true" Class="form-control input-sm select2me" Style="width: 141px !important;" DataTextField="Nombre" DataValueField="CveUsuario">
<asp:ListItem Text="Todos" Value="-1"></asp:ListItem>
</asp:DropDownList>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Almacenes:</b></label>&nbsp;<asp:Label ID="LblAlmacenes" runat="server" Text=""></asp:Label>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Clasificaciones:</b></label>&nbsp;<asp:Label ID="LblClasif" runat="server" Text="Todas"></asp:Label>
<br />
&nbsp;&nbsp;&nbsp;<label><b>Clasificaciones Excluidas:</b></label>&nbsp;<asp:Label ID="LblClasificacionesExcluidas" runat="server" Text=""></asp:Label>
</td>
</tr>
<tr>
<td colspan="3">&nbsp;&nbsp;&nbsp;<label><b>Productos:</b></label>&nbsp;<asp:Label ID="LblProductos" runat="server" Text="Todos"></asp:Label>
<br />
&nbsp;&nbsp;&nbsp;<label><b>Productos Excluidos:</b></label>&nbsp;<asp:Label ID="LblProductosExcluidos" runat="server" Text=""></asp:Label>
</td>
</tr>
</table>
<table>
<tr>
<td class="col-md-12" style="width: 500px;">
<label><b>Observaciones: </b></label>
<asp:Label ID="lbObservaciones" runat="server" Style="width: 450px;"></asp:Label>
</td>
</tr>
</table>
</div>
</div>
</div>
<asp:UpdatePanel ID="UPAgregarPro" runat="server" RenderMode="Inline" ViewStateMode="Inherit" UpdateMode="Conditional">
<ContentTemplate>
<div class="col-md-3" id="PAgregar" runat="server">
<asp:Panel ID="PnlII" runat="server" DefaultButton="BtnGuardar">
<div class="portlet smmallpadding light bordered" id="DivCodigoBarras" runat="server">
<div class="portlet-title">
<div class="tools">
<a href="javascript:;" class="collapse"></a>
</div>
<div class="caption uppercase" style="position: relative;">
<i class="fa fa-info-circle"></i>Agregar Producto
</div>
</div>
<div class="portlet-body">
<div class="row">
<label class="col-md-4">Cantidad</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCantidadProducto" Text="1" Width="50px"></asp:TextBox>
<asp:RequiredFieldValidator runat="server" ID="RFVCantidad" ControlToValidate="TxtCantidadProducto" ValidationGroup="GrpIngresar" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingrése una." Display="Dynamic" Text="*"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCOCantidad" runat="server" HighlightCssClass="vco" TargetControlID="RFVCantidad" Width="300px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Código/NoParte</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigo"></asp:TextBox>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Código.Barras</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigoBarras"></asp:TextBox>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Serie</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigoSerie"></asp:TextBox>
<asp:RequiredFieldValidator runat="server" ID="RFVSerie" ControlToValidate="TxtCodigoSerie" Enabled="false" ValidationGroup="GrpIngresar" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingrése una." Display="Dynamic" Text="*"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCESerie" runat="server" HighlightCssClass="vco" TargetControlID="RFVSerie" Width="300px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<div class="col-md-12" style="text-align: center;">
<asp:Button ID="BtnGuardar" runat="server" ValidationGroup="GrpIngresar" Text="Ingresar" class="btn btn-primary" Enabled="false" />
</div>
</div>
</div>
</div>
</asp:Panel>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
<asp:UpdatePanel ID="UPPInventario" runat="server" RenderMode="Inline" UpdateMode="Conditional">
<ContentTemplate>
<div class="row">
<label class="col-md-2"><b>Ultimo Registrado: </b></label>
<div class="col-md-8">
<asp:GridView ID="GvIFDUltimoRegistrado" ClientIDMode="Static" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False" GridLines="None" DataKeyNames="CveInventarioFisicoDetalle" ShowHeaderWhenEmpty="True" CssClass="table table-striped table-hover Widthall">
<Columns>
<asp:BoundField HeaderText="Fecha" DataField="FechaInvFisico" DataFormatString="{0:g}"></asp:BoundField>
<asp:BoundField HeaderText="Código Barras" DataField="CodigoBarras" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Serie/Lote" DataField="SerieLote" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Cantidad" DataField="Cantidad" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right"></asp:BoundField>
</Columns>
</asp:GridView>
</div>
<div class="col-md-2">
<asp:Button ID="BtnVerRegistrados" OnClick="BtnVerRegistrados_Click" runat="server" CssClass="btn btn-primary btn-sm" Text="Ver Registrados" />
</div>
</div>
<br />
<div class="row col-md-12" align="right" id="DivBuscador" runat="server">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="return Filtrar(event);" style="display: inline-block; margin-right: -20px; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvIFD.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
<div style="display: inline-block;" id="SumFiltra"></div>
</div>
<asp:GridView ID="GvIFD" ClientIDMode="Static" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False" GridLines="None" DataKeyNames="CveInventarioFisicoDetalle" ShowHeaderWhenEmpty="True" CssClass="table table-striped table-hover Widthall">
<Columns>
<asp:BoundField HeaderText="Fecha" DataField="FechaInvFisico" DataFormatString="{0:g}"></asp:BoundField>
<asp:BoundField HeaderText="Código Barras" DataField="CodigoBarras" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Serie/Lote" DataField="SerieLote" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Cantidad" DataField="Cantidad" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right"></asp:BoundField>
<asp:TemplateField HeaderText="Eliminar" ItemStyle-HorizontalAlign="Center">
<ItemTemplate>
<asp:LinkButton ID="imgD" runat="server" AlternateText="Eliminar" CausesValidation="False" CommandName="Delete" CssClass="btn btn-circle btn-xs red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Estas seguro que desea eliminar el registro?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger ControlID="ddlUsuario" EventName="SelectedIndexChanged" />
</Triggers>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="/Scripts/DataTables.js"></script>
</div>
</div>
<div class="portlet-body">
<div class="row">
<label class="col-md-4">Cantidad</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCantidadProducto" Text="1" Width="50px"></asp:TextBox>
<asp:RequiredFieldValidator runat="server" ID="RFVCantidad" ControlToValidate="TxtCantidadProducto" ValidationGroup="GrpIngresar" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cantidad''</b> es necesario, por favor ingrése una." Display="Dynamic" Text="*"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCOCantidad" runat="server" HighlightCssClass="vco" TargetControlID="RFVCantidad" Width="300px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Código/NoParte</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigo"></asp:TextBox>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Código.Barras</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigoBarras"></asp:TextBox>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<label class="col-md-4">Serie</label>
<div class="col-md-8">
<asp:TextBox runat="server" ID="TxtCodigoSerie"></asp:TextBox>
<asp:RequiredFieldValidator runat="server" ID="RFVSerie" ControlToValidate="TxtCodigoSerie" Enabled="false" ValidationGroup="GrpIngresar" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Serie''</b> es necesario, por favor ingrése una." Display="Dynamic" Text="*"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCESerie" runat="server" HighlightCssClass="vco" TargetControlID="RFVSerie" Width="300px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row" style="margin-top: 5px;">
<div class="col-md-12" style="text-align: center;">
<asp:Button ID="BtnGuardar" runat="server" ValidationGroup="GrpIngresar" Text="Ingresar" class="btn btn-primary" Enabled="false" />
</div>
</div>
</div>
</div>
</asp:Panel>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
<asp:UpdatePanel ID="UPPInventario" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="row">
<label class="col-md-2"><b>Ultimo Registrado: </b></label>
<div class="col-md-8">
<asp:GridView ID="GvIFDUltimoRegistrado" ClientIDMode="Static" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False" GridLines="None" DataKeyNames="CveInventarioFisicoDetalle" ShowHeaderWhenEmpty="True" CssClass="table table-striped table-hover Widthall">
<Columns>
<asp:BoundField HeaderText="Fecha" DataField="FechaInvFisico" DataFormatString="{0:g}"></asp:BoundField>
<asp:BoundField HeaderText="Código Barras" DataField="CodigoBarras" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Serie/Lote" DataField="SerieLote" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Cantidad" DataField="Cantidad" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right"></asp:BoundField>
</Columns>
</asp:GridView>
</div>
<div class="col-md-2">
<asp:Button ID="BtnVerRegistrados" OnClick="BtnVerRegistrados_Click" runat="server" CssClass="btn btn-primary btn-sm" Text="Ver Registrados" />
</div>
</div>
<br />
<div class="row col-md-12" align="right" id="DivBuscador" runat="server">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="return Filtrar(event);" style="display: inline-block; margin-right: -20px; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvIFD.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
<div style="display: inline-block;" id="SumFiltra"></div>
</div>
<asp:GridView ID="GvIFD" ClientIDMode="Static" runat="server" EmptyDataText="Aun no hay registros." AutoGenerateColumns="False" GridLines="None" DataKeyNames="CveInventarioFisicoDetalle" ShowHeaderWhenEmpty="True" CssClass="table table-striped table-hover Widthall">
<Columns>
<asp:BoundField HeaderText="Fecha" DataField="FechaInvFisico" DataFormatString="{0:g}"></asp:BoundField>
<asp:BoundField HeaderText="Código Barras" DataField="CodigoBarras" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Código" DataField="Codigo" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Producto" DataField="PS" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Serie/Lote" DataField="SerieLote" ItemStyle-HorizontalAlign="Left"></asp:BoundField>
<asp:BoundField HeaderText="Cantidad" DataField="Cantidad" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right"></asp:BoundField>
<asp:TemplateField HeaderText="Eliminar" ItemStyle-HorizontalAlign="Center">
<ItemTemplate>
<asp:LinkButton ID="imgD" runat="server" AlternateText="Eliminar" CausesValidation="False" CommandName="Delete" CssClass="btn btn-circle btn-xs red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Estas seguro que desea eliminar el registro?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
<Triggers>
<asp:AsyncPostBackTrigger ControlID="ddlUsuario" EventName="SelectedIndexChanged" />
</Triggers>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="/Scripts/DataTables.js"></script>
<script type="text/javascript">
function pageLoad(sender, e) {
$(document).ready(function () {
$('a[class="ajax__tab_tab"]').click(function () {
$.fn.dataTable.tables({ visible: true, api: true }).columns.adjust();
});
});
function pageLoad(sender, e) {
$(document).ready(function () {
$('a[class="ajax__tab_tab"]').click(function () {
$.fn.dataTable.tables({ visible: true, api: true }).columns.adjust();
});
});
}
function Filtrar(e) {
function Filtrar(e) {
debugger;
if (e.keyCode == 13 || e.which == 13) {
return false;
if (e.keyCode == 13 || e.which == 13) {
return false;
} else {
<%= String.Format("FiltrarTabla('TxtBusqueda','{0}','SumFiltra')", GvIFD.ClientID) %>;
}
<%= String.Format("FiltrarTabla('TxtBusqueda','{0}','SumFiltra')", GvIFD.ClientID) %>;
}
}
function playsonidito(NomArchivo) {
function playsonidito(NomArchivo) {
var URL = /Sonidos/ + NomArchivo
var snd = new Audio(URL);
snd.play();
snd.currentTime = 0;
snd.currentTime = 0;
}
function OrdenarGV() {
$('#<%=GvIFD.ClientID%>').DataTable({
function OrdenarGV() {
$('#<%=GvIFD.ClientID%>').DataTable({
retrieve: true,
scrollY: '300px',
scrollCollapse: true,
paging: false,
searching: false,
info: false,
ordering: false
ordering: false
});
$('#GvIFD').parent().parent().children().first().css("position", "static");
$('#GvIFD').parent().parent().children().first().css("position", "static");
}
</script>
</asp:Content>
</script>
</asp:Content>

View File

@@ -88,44 +88,42 @@ Partial Class Inventarios_InventarioFisicoDetalle
#Region " CARGA DATOS "
Private Sub CargaDatos(CveInventarioFisico As Integer, CveEmpresa As Integer, Optional CveUsuario As Integer = -1)
Dim Inventario As New ClsInventarios
Dim ObjInventario As New ClsInventarios
If ObjInventario.GetInventarioFisico(CveInventarioFisico, CveEmpresa, -1, -1) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
Dim CveEstatus = ObjInventario.DtResultados.FiltroPrimeroValor("CveEstatus")
Select Case CveEstatus
Case "0" 'NUEVO
CveSubProyecto = ObjInventario.CveSubProyectoInventario
lbTitulo.Text = ObjInventario.InventarioFisico
lbObservaciones.Text = ObjInventario.Observaciones
lbSubProyecto.Text = ObjInventario.SubProyectoInventario
lbEstatus.Text = ObjInventario.Estatus
If Inventario.GetInventarioFisico(CveInventarioFisico, CveEmpresa, -1, -1) Then
Select Case Inventario.Estatus
Case "Nuevo"
CveSubProyecto = Inventario.CveSubProyectoInventario
lbTitulo.Text = Inventario.InventarioFisico
lbObservaciones.Text = Inventario.Observaciones
lbSubProyecto.Text = Inventario.SubProyectoInventario
lbEstatus.Text = Inventario.Estatus
lbFechaF.Text = Inventario.FechaF
lbFechaF.Text = ObjInventario.FechaF
btnFin.Text = "Iniciar"
BtnGuardar.Enabled = False
btnFin.ToolTip = "Inicia el Inventario Físico"
Case "Finalizado"
Case "3" 'FINALIZADO
GvIFD.Columns(6).Visible = False
PAgregar.Visible = False
'BtnGuardar.Visible = False
PAgregar.Visible = False
BtnGuardar.Enabled = False
BtnGuardar.Visible = False
btnFin.Visible = False
'BtnGuardar.Enabled = False
'PAgregar.Visible = False
CveSubProyecto = Inventario.CveSubProyectoInventario
lbTitulo.Text = Inventario.InventarioFisico
lbObservaciones.Text = Inventario.Observaciones
lbSubProyecto.Text = Inventario.SubProyectoInventario
lbEstatus.Text = Inventario.Estatus
lbFechaI.Text = Inventario.FechaI
lbFechaF.Text = Inventario.FechaF
Case Else ' en proceso
CveSubProyecto = Inventario.CveSubProyectoInventario
lbTitulo.Text = Inventario.InventarioFisico
lbObservaciones.Text = Inventario.Observaciones
lbEstatus.Text = Inventario.Estatus
lbSubProyecto.Text = Inventario.SubProyectoInventario
lbFechaI.Text = Inventario.FechaI
lbFechaF.Text = Inventario.FechaF
CveSubProyecto = ObjInventario.CveSubProyectoInventario
lbTitulo.Text = ObjInventario.InventarioFisico
lbObservaciones.Text = ObjInventario.Observaciones
lbSubProyecto.Text = ObjInventario.SubProyectoInventario
lbEstatus.Text = ObjInventario.Estatus
lbFechaI.Text = ObjInventario.FechaI
lbFechaF.Text = ObjInventario.FechaF
Case "1", "2" ' EN PROCESO,EN ESPERA
CveSubProyecto = ObjInventario.CveSubProyectoInventario
lbTitulo.Text = ObjInventario.InventarioFisico
lbObservaciones.Text = ObjInventario.Observaciones
lbEstatus.Text = ObjInventario.Estatus
lbSubProyecto.Text = ObjInventario.SubProyectoInventario
lbFechaI.Text = ObjInventario.FechaI
lbFechaF.Text = ObjInventario.FechaF
BtnGuardar.Enabled = True
btnFin.Text = "Finalizar"
LBAvance.Visible = UsuarioActual.TienePermisoProceso(178) ' si tiene permiso de ver el avance, se activa
@@ -133,8 +131,8 @@ Partial Class Inventarios_InventarioFisicoDetalle
GvIFD.Visible = False
DivBuscador.Visible = False
If Inventario.GetInventarioFisicoDetallesAlmacen(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = Inventario.DtResultados
If ObjInventario.GetInventarioFisicoDetallesAlmacen(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = ObjInventario.DtResultados
Dim str As New StringBuilder
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
@@ -144,8 +142,9 @@ Partial Class Inventarios_InventarioFisicoDetalle
End If
LblAlmacenes.Text = str.ToString
End If
If Inventario.GetInventarioFisicoDetallesClasificacion(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = Inventario.DtResultados
If ObjInventario.GetInventarioFisicoDetallesClasificacion(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = ObjInventario.DtResultados
Dim str As New StringBuilder
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
@@ -161,8 +160,9 @@ Partial Class Inventarios_InventarioFisicoDetalle
End If
End If
If Inventario.GetInventarioFisicoDetallesProductosServicios(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = Inventario.DtResultados
If ObjInventario.GetInventarioFisicoDetallesProductosServicios(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
Dim dt As DataTable = ObjInventario.DtResultados
Dim str As New StringBuilder
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
@@ -179,18 +179,32 @@ Partial Class Inventarios_InventarioFisicoDetalle
End If
If Inventario.GetInventarioFisicoDetalle(CveInventarioFisico, CveUsuario) Then
If Inventario.DtResultados.Rows.Count > 0 Then
GvIFDUltimoRegistrado.DataSource = Inventario.DtResultados.AsEnumerable.OrderByDescending(Function(k) k!CveInventarioFisicoDetalle).Take(1).CopyToDataTable
If ObjInventario.GetInventarioFisicoDetalle(CveInventarioFisico, CveUsuario) Then
If ObjInventario.DtResultados.Rows.Count > 0 Then
GvIFDUltimoRegistrado.DataSource = ObjInventario.DtResultados.AsEnumerable.OrderByDescending(Function(k) k!CveInventarioFisicoDetalle).Take(1).CopyToDataTable
Else
GvIFDUltimoRegistrado.DataSource = Nothing
End If
DtDatos = Inventario.DtResultados
End If
DtDatos = ObjInventario.DtResultados
End If
Else
GvIFD.Columns(6).Visible = False
PAgregar.Visible = False
BtnGuardar.Enabled = False
BtnGuardar.Visible = False
btnFin.Visible = False
CveSubProyecto = ObjInventario.CveSubProyectoInventario
lbTitulo.Text = ObjInventario.InventarioFisico
lbObservaciones.Text = ObjInventario.Observaciones
lbSubProyecto.Text = ObjInventario.SubProyectoInventario
lbEstatus.Text = ObjInventario.Estatus
lbFechaI.Text = ObjInventario.FechaI
lbFechaF.Text = ObjInventario.FechaF
Alert("Ocurrió un error al obterner el inventario fisico")
End If
Inventario.Dispose()
ObjInventario.Dispose()
GvIFDUltimoRegistrado.DataBind()
'If (GvIFD.Rows.Count > 0) Then
@@ -397,20 +411,30 @@ Partial Class Inventarios_InventarioFisicoDetalle
#Region " VER AVANCE "
Protected Sub LBAvance_Click(sender As Object, e As EventArgs)
Response.Redirect($"~/Inventarios/RepAnomalias.aspx?CveInventarioFisico={CveInventarioFisico}&EsAvance=1")
End Sub
End Sub
#End Region
#Region "I M P R I M I R"
Private Sub LnkPDF_Click(sender As Object, e As EventArgs) Handles LnkPDF.Click
Impimir(Formato:="PDF")
End Sub
Private Sub LnkPDFResumido_Click(sender As Object, e As EventArgs) Handles LnkPDFResumido.Click
Impimir(Formato:="PDF", Agrupar:=True)
End Sub
Private Sub LnkExcel_Click(sender As Object, e As EventArgs) Handles LnkExcel.Click
Impimir(Formato:="EXCEL")
End Sub
Protected Sub Impimir(Optional Formato As String = "PDF")
Protected Sub Impimir(Optional Formato As String = "PDF", Optional Agrupar As Boolean = False)
Dim DtDatos As New DataTable
Dim ObjInventario As New ClsInventarios()
If ObjInventario.GetInventarioFisicoDetalle(CveInventarioFisico, UsuarioActual.CveUsuario, Agrupar:=Agrupar) Then
DtDatos = ObjInventario.DtResultados
End If
ObjInventario.Dispose()
If DtDatos IsNot Nothing Then
Dim Archivo As New System.IO.FileInfo(String.Format("{0}Formatos/RepAnomalias.rdlc", UsuarioActual.Empresa.Ruta))
Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", UsuarioActual.Empresa.Ruta))
@@ -441,8 +465,8 @@ Partial Class Inventarios_InventarioFisicoDetalle
Else
Alert("No se encontraron resultado", TipoMensaje.MsgAdvertencia)
End If
End Sub
End Sub
#End Region
End Class

View File

@@ -1,258 +1,278 @@
<%@ Page Title="REPORTE DE ALMACÉN" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepAlmacen.aspx.vb" Inherits="Inventarios_RepAlmacen" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
<style>
.GVAlmacen > tbody > tr:nth-child(2) {
background: #CCCCCC;
color: #67809F;
font-weight: bold;
}
.GVAlmacen > tbody > tr > td:nth-child(2) {
text-align: right;
}
.GVAlmacen > tbody > tr > td:nth-child(3) {
text-align: center;
}
.select2 .select2-selection__rendered {
line-height: 1;
color: #111;
}
.select2 .select2-selection--multiple {
box-sizing: border-box;
cursor: pointer;
display: block;
min-height: 20px;
user-select: none;
-webkit-user-select: none;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice {
margin-top: 10px;
}
.select2-selection__rendered {
margin-top: 0px;
height: 25px;
}
.select2-selection {
margin-top: 0px;
height: 31px;
}
.select2-container--default.select2-container--focus .select2-selection--multiple {
border: none;
outline: 0;
}
#chartdiv {
width: 100%;
height: 500px;
}
</style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
REPORTE DE ALMACÉN
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<li>
<asp:LinkButton ID="LnkPdf" runat="server"><i class="fa fa-file-pdf-o" style="font-weight:bold;"></i> PDF</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkExportar" runat="server"><i class="fa fa-file-excel-o" style="font-weight:bold;"></i> Excel</asp:LinkButton>
</li>
<asp:UpdatePanel ID="UpAcciones" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkVerGrafica" OnClick="LnkVerGrafica_Click" runat="server"><i class="fa fa-signal"></i> Ver Grafica</asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel ID="UPFiltros" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="portlet solid grey-cascade portlet-filter">
<div class="portlet-title portlet-filterT smalltitle">
<div class="tools">
<asp:Button ID="BtnConsultar" runat="server" Text="Consultar" class="btn btn-primary" />
<a href="javascript;" data-idchekbox="<%= chkexpand.ClientID%>" class=" <%= IIf(chkexpand.Checked = True, "collapse", "expand")%>"></a>
<asp:CheckBox ID="chkexpand" CssClass="hidden" runat="server" />
</div>
<div class="titlefiltros caption">
<div class="row">
<div class="col-md-1 truncate" style="text-align: right!important">Fecha Inicio:</div>
<div class="col-md-1 col-sm-1">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 95px !important; padding: 0px;">
<asp:TextBox Style="width: 80px !important;" ID="TxtFechaI" runat="server" CssClass="form-control" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="ImgFechaI" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="TxtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaI" TargetControlID="TxtFechaI" PopupButtonID="ImgFechaI" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
</div>
<div class="col-md-1 truncate" style="text-align: right!important">Fecha Fin:</div>
<div class="col-md-1 col-sm-1">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 95px !important; padding: 0px;">
<asp:TextBox Style="width: 80px !important;" ID="TxtFechaF" runat="server" CssClass="form-control" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="ImgFechaF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="TxtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaF" PopupButtonID="ImgFechaF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
</div>
<div class="col-md-1 truncate" style="text-align: right!important">Tipo Almacen:</div>
<div class="col-md-1">
<asp:ListBox ID="DdlTipoAlmacen" SelectionMode="Multiple" CssClass="form-control ddlFiltros input-sm select2me Widthall" DataTextField="TipoAlmacen" DataValueField="CveTipoAlmacen" Style="width: 100%;" runat="server"></asp:ListBox>
</div>
<div class="col-md-1 truncate" style="text-align: right!important">Modalidad:</div>
<div class="col-md-1">
<asp:DropDownList ID="DdlModalidadFiltro" runat="server" CssClass="input-small input-sm select2me" Width="100%">
<asp:ListItem Text="Todas" Value="-1" Selected="True"> </asp:ListItem>
<asp:ListItem Text="Contable" Value="1"></asp:ListItem>
<asp:ListItem Text="No Contable" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<asp:CheckBox ID="ChkInventariable" CssClass="md-checksd" runat="server" Text="Aplica Inventario" />
</div>
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GVAlmacen" runat="server" AutoGenerateColumns="False" data-sort="true" EmptyDataText="No se encontraron Almacenes" CssClass="table table-striped table-advance table-hover Widthall ScrollAD" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="Almacén">
<ItemTemplate>
<asp:HyperLink ID="HyperLink1" Target="_blank" NavigateUrl='<%# String.Format("/Inventarios/RepEntradasSalidas.aspx?CveAlmacen={0}&FechaInicio={1:d}&FechaCorte={2:d}", Eval("CveAlmacen").ToString, Eval("FechaInicio"), Eval("FechaFin"))%>' runat="server"><%# Eval("Almacen") %></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Existencia" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LtlExist" runat="server" Text='<%# Eval("Existencia", "{0:#,###.##}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LtlTotal" runat="server" Text='<%# Eval("Total", "{0:#,##0.00}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Tipo Almacén">
<ItemTemplate>
<asp:Label ID="LtlAlmacen" runat="server" Text='<%# Eval("TipoAlmacen")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>
<div id="DivModalGrafica" class="modal ADS fade" role="dialog">
<asp:UpdatePanel class="modal-dialog modal-lg" runat="server" ID="UPModalProd" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">
<asp:Label ID="LblTituloGrafica" runat="server" ClientIDMode="Static" Text="Almacenes"></asp:Label>
</h4>
</div>
<div class="modal-body">
<div class="row">
<div class="col-md-2"></div>
<label class="col-md-1 truncate">Grafica:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlGrafica" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlGrafica_SelectedIndexChanged" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Barras" Value="1"></asp:ListItem>
<asp:ListItem Text="Pastel" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
<label class="col-md-1 truncate">&nbsp;&nbsp;&nbsp;Ver:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlVer" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlVer_SelectedIndexChanged" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Existencias" Value="1"></asp:ListItem>
<asp:ListItem Text="Total" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
</div>
<br />
<div id="chartdiv"></div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Cerrar</button>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="https://www.amcharts.com/lib/3/amcharts.js"></script>
<script src="https://www.amcharts.com/lib/3/serial.js"></script>
<script src="https://www.amcharts.com/lib/3/pie.js"></script>
<script src="https://www.amcharts.com/lib/3/plugins/export/export.min.js"></script>
<link rel="stylesheet" href="https://www.amcharts.com/lib/3/plugins/export/export.css" type="text/css" media="all" />
<script src="https://www.amcharts.com/lib/3/themes/light.js"></script>
<%@ Page Title="REPORTE DE ALMACÉN" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepAlmacen.aspx.vb" Inherits="Inventarios_RepAlmacen" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
<style>
.GVAlmacen > tbody > tr:nth-child(2) {
background: #CCCCCC;
color: #67809F;
font-weight: bold;
}
.GVAlmacen > tbody > tr > td:nth-child(2) {
text-align: right;
}
.GVAlmacen > tbody > tr > td:nth-child(3) {
text-align: center;
}
.select2 .select2-selection__rendered {
line-height: 1;
color: #111;
}
.select2 .select2-selection--multiple {
box-sizing: border-box;
cursor: pointer;
display: block;
min-height: 20px;
user-select: none;
-webkit-user-select: none;
}
.select2-container--default .select2-selection--multiple .select2-selection__choice {
margin-top: 10px;
}
.select2-selection__rendered {
margin-top: 0px;
height: 25px;
}
.select2-selection {
margin-top: 0px;
height: 31px;
}
.select2-container--default.select2-container--focus .select2-selection--multiple {
border: none;
outline: 0;
}
#chartdiv {
width: 100%;
height: 500px;
}
.v-center {
display: flex;
align-items: center;
}
</style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
REPORTE DE ALMACÉN
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<li>
<asp:LinkButton ID="LnkPdf" runat="server"><i class="fa fa-file-pdf-o" style="font-weight:bold;"></i> PDF</asp:LinkButton>
</li>
<li>
<asp:LinkButton ID="LnkExportar" runat="server"><i class="fa fa-file-excel-o" style="font-weight:bold;"></i> Excel</asp:LinkButton>
</li>
<asp:UpdatePanel ID="UpAcciones" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkVerGrafica" OnClick="LnkVerGrafica_Click" runat="server"><i class="fa fa-signal"></i> Ver Grafica</asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel ID="UPFiltros" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="portlet solid grey-cascade portlet-filter">
<div class="portlet-title portlet-filterT smalltitle">
<div class="tools">
<asp:Button ID="BtnConsultar" runat="server" Text="Consultar" class="btn btn-primary" />
<a href="javascript;" data-idchekbox="<%= chkexpand.ClientID%>" class=" <%= IIf(chkexpand.Checked = True, "collapse", "expand")%>"></a>
<asp:CheckBox ID="chkexpand" CssClass="hidden" runat="server" />
</div>
<div class="titlefiltros caption">
<div class="row v-center">
<div class="col-md-1 truncate" style="text-align: right!important">Fecha Inicio:</div>
<div class="col-md-1 v-center">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 95px !important; padding: 0px;">
<asp:TextBox Style="width: 80px !important;" ID="TxtFechaI" runat="server" CssClass="form-control" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="ImgFechaI" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="TxtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaI" TargetControlID="TxtFechaI" PopupButtonID="ImgFechaI" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
</div>
<div class="col-md-1 truncate" style="text-align: right!important">Fecha Fin:</div>
<div class="col-md-1 v-center">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 95px !important; padding: 0px;">
<asp:TextBox Style="width: 80px !important;" ID="TxtFechaF" runat="server" CssClass="form-control" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="ImgFechaF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="TxtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaF" PopupButtonID="ImgFechaF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
</div>
<div class="col-md-1 truncate v-center" style="text-align: right!important">Almacen:</div>
<div class="col-md-2 v-center">
<asp:ListBox ID="DdlAlmacen" SelectionMode="Multiple" CssClass="form-control ddlFiltros input-sm select2me Widthall" DataTextField="Almacen" DataValueField="CveAlmacen" Style="width: 100%;" runat="server"></asp:ListBox>
</div>
<div class="col-md-1 truncate v-center" style="text-align: right!important">Tipo Almacen:</div>
<div class="col-md-2 v-center">
<asp:ListBox ID="DdlTipoAlmacen" SelectionMode="Multiple" CssClass="form-control ddlFiltros input-sm select2me Widthall" DataTextField="TipoAlmacen" DataValueField="CveTipoAlmacen" Style="width: 100%;" runat="server"></asp:ListBox>
</div>
</div>
</div>
</div>
<div class="portlet-body" style="display: none;">
<div class="row">
<div class="col-md-1 truncate" style="text-align: right!important">Modalidad:</div>
<div class="col-md-1">
<asp:DropDownList ID="DdlModalidadFiltro" runat="server" CssClass="input-small input-sm select2me" Width="100%">
<asp:ListItem Text="Todas" Value="-1" Selected="True"> </asp:ListItem>
<asp:ListItem Text="Contable" Value="1"></asp:ListItem>
<asp:ListItem Text="No Contable" Value="0"></asp:ListItem>
</asp:DropDownList>
</div>
<div class="col-md-1 truncate" style="text-align: right!important">Sucursal:</div>
<div class="col-md-1">
<asp:DropDownList ID="DdlSucursal" runat="server" CssClass="input-small input-sm select2me" Width="100%" DataTextField="SubProyecto" DataValueField="CveSubProyecto">
<asp:ListItem Text="Todas" Value="-1" Selected="True"> </asp:ListItem>
</asp:DropDownList>
</div>
<div class="col-md-2">
<asp:CheckBox ID="ChkInventariable" CssClass="md-checksd" runat="server" Text="Aplica Inventario" />
</div>
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GVAlmacen" runat="server" AutoGenerateColumns="False" data-sort="true" EmptyDataText="No se encontraron Almacenes" CssClass="table table-striped table-advance table-hover Widthall ScrollAD" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="Almacén">
<ItemTemplate>
<asp:HyperLink ID="HyperLink1" Target="_blank" NavigateUrl='<%# String.Format("/Inventarios/RepEntradasSalidas.aspx?CveAlmacen={0}&FechaInicio={1:d}&FechaCorte={2:d}", Eval("CveAlmacen").ToString, Eval("FechaInicio"), Eval("FechaFin"))%>' runat="server"><%# Eval("Almacen") %></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Existencia" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LtlExist" runat="server" Text='<%# Eval("Existencia", "{0:#,###.##}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Label ID="LtlTotal" runat="server" Text='<%# Eval("Total", "{0:#,##0.00}")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Tipo Almacén">
<ItemTemplate>
<asp:Label ID="LtlAlmacen" runat="server" Text='<%# Eval("TipoAlmacen")%>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</asp:UpdatePanel>
<div id="DivModalGrafica" class="modal ADS fade" role="dialog">
<asp:UpdatePanel class="modal-dialog modal-lg" runat="server" ID="UPModalProd" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">
<asp:Label ID="LblTituloGrafica" runat="server" ClientIDMode="Static" Text="Almacenes"></asp:Label>
</h4>
</div>
<div class="modal-body">
<div class="row">
<div class="col-md-2"></div>
<label class="col-md-1 truncate">Grafica:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlGrafica" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlGrafica_SelectedIndexChanged" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Barras" Value="1"></asp:ListItem>
<asp:ListItem Text="Pastel" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
<label class="col-md-1 truncate">&nbsp;&nbsp;&nbsp;Ver:</label>
<div class="col-md-2">
<asp:DropDownList ID="DdlVer" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DdlVer_SelectedIndexChanged" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
<asp:ListItem Selected="True" Text="Existencias" Value="1"></asp:ListItem>
<asp:ListItem Text="Total" Value="2"></asp:ListItem>
</asp:DropDownList>
</div>
</div>
<br />
<div id="chartdiv"></div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Cerrar</button>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="https://www.amcharts.com/lib/3/amcharts.js"></script>
<script src="https://www.amcharts.com/lib/3/serial.js"></script>
<script src="https://www.amcharts.com/lib/3/pie.js"></script>
<script src="https://www.amcharts.com/lib/3/plugins/export/export.min.js"></script>
<link rel="stylesheet" href="https://www.amcharts.com/lib/3/plugins/export/export.css" type="text/css" media="all" />
<script src="https://www.amcharts.com/lib/3/themes/light.js"></script>
<script>
function CargaGraficaBarras(data,title) {
function CargaGraficaBarras(data, title) {
var chart = AmCharts.makeChart("chartdiv", {
var chart = AmCharts.makeChart("chartdiv", {
"type": "serial",
"theme": "light",
"dataProvider": data,
"startDuration": 2,
"valueAxes": [{
"valueAxes": [{
"position": "left",
"title": title
"title": title
}],
"graphs": [{
"graphs": [{
"balloonText": "[[category]]: <b>[[value]]</b>",
"colorField": "Color",
"fillAlphas": 1,
"lineAlpha": 0.1,
"type": "column",
"valueField": "Valor"
"valueField": "Valor"
}],
"depth3D": 20,
"angle": 30,
"chartCursor": {
"chartCursor": {
"categoryBalloonEnabled": false,
"cursorAlpha": 0,
"zoomable": false
"zoomable": false
},
"categoryField": "Texto",
"categoryAxis": {
"categoryAxis": {
"gridPosition": "start",
"labelRotation": 90
"labelRotation": 90
},
"export": {
"enabled": true
}
});
"export": {
"enabled": true
}
});
}
function CargaGraficaPastel(data) {
function CargaGraficaPastel(data) {
var chart = AmCharts.makeChart("chartdiv", {
var chart = AmCharts.makeChart("chartdiv", {
"type": "pie",
"theme": "light",
"dataProvider":
@@ -263,12 +283,12 @@
"depth3D": 0,
"balloonText": "[[title]]<br><span style='font-size:14px'><b>[[value]]</b> ([[percents]]%)</span>",
"angle": 0,
"export": {
"enabled": true
}
});
"export": {
"enabled": true
}
});
}
</script>
</asp:Content>
</script>
</asp:Content>

View File

@@ -6,9 +6,9 @@ Imports System.Data
Imports Microsoft.Reporting.WebForms
Partial Class Inventarios_RepAlmacen
Inherits ClsPaginas
Inherits ClsPaginas
#Region "PROPIEDADES"
Private Property TmpDT As DataTable
Get
@@ -25,7 +25,7 @@ Partial Class Inventarios_RepAlmacen
Set(value As DataTable)
ViewState("DtColor") = value
End Set
End Property
End Property
#End Region
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
If Not IsPostBack Then
@@ -39,6 +39,15 @@ Partial Class Inventarios_RepAlmacen
DdlTipoAlmacen.DataSource = GlobalDTTipoAlmacen(1)
DdlTipoAlmacen.DataBind()
DdlTipoAlmacen.Items.Insert(0, New ListItem("Todos", "-1"))
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
DdlAlmacen.DataBind()
DdlAlmacen.Items.Insert(0, New ListItem("Todos", "-1"))
DdlSucursal.DataSource = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, CveEstatus:=1)
DdlSucursal.DataBind()
DdlSucursal.Items.Insert(0, New ListItem("Todas", "-1"))
End Sub
Private Sub CargaDatos()
@@ -48,8 +57,11 @@ Partial Class Inventarios_RepAlmacen
FechaI = If(IsDate(TxtFechaI.Text.Trim()), TxtFechaI.Text.Trim(), "-1")
FechaF = If(IsDate(TxtFechaF.Text.Trim()), TxtFechaF.Text.Trim(), "-1")
Dim TipoAlmacen As String = If(DdlTipoAlmacen.GetSelectedValuesM = "", "-1", DdlTipoAlmacen.GetSelectedValuesM)
Dim Almacenes As String = If(DdlAlmacen.GetSelectedValuesM = "", "-1", DdlAlmacen.GetSelectedValuesM)
Dim CveSubProyecto As Integer = DdlSucursal.SelectedValue.ToEntero()
If objInv.GetRepAlmacenes(FechaI, FechaF, UsuarioActual.CveEmpresa, TipoAlmacen, DdlModalidadFiltro.SelectedValue.ToEntero, ChkInventariable.Checked) Then
If objInv.GetRepAlmacenes(FechaI, FechaF, UsuarioActual.CveEmpresa, TipoAlmacen, DdlModalidadFiltro.SelectedValue.ToEntero, ChkInventariable.Checked,
Almacenes:=Almacenes, CveSubProyecto:=CveSubProyecto) Then
GVAlmacen.DataSource = objInv.DtResultados
TmpDT = objInv.DtResultados
End If
@@ -60,8 +72,8 @@ Partial Class Inventarios_RepAlmacen
Private Sub BtnConsultar_Click(sender As Object, e As EventArgs) Handles BtnConsultar.Click
CargaDatos()
UpDatos.Update()
End Sub
End Sub
#Region "I M P R I M I R <i class='fa fa-print'></i>"
Protected Sub LnkExportar_Click(sender As Object, e As EventArgs) Handles LnkExportar.Click
@@ -98,11 +110,11 @@ Partial Class Inventarios_RepAlmacen
e.Row.CssClass = "Totales"
End If
End If
End Sub
End Sub
#End Region
#Region "GRAFICA"
Protected Sub LnkVerGrafica_Click(sender As Object, e As EventArgs)
If Not TmpDT IsNot Nothing AndAlso TmpDT.Rows.Count > 0 Then
Alert("No hay datos disponibles", TipoMensaje.MsgAdvertencia)
@@ -227,8 +239,8 @@ Partial Class Inventarios_RepAlmacen
Protected Sub DdlVer_SelectedIndexChanged(sender As Object, e As EventArgs)
CambioGrafica()
End Sub
End Sub
#End Region
End Class

View File

@@ -4,4 +4,4 @@
28/08/2019:05:48 p. m. No se especifico a remitente - SIG - Se Genero una Recepción de Usados con el folio: 80
02/09/2019:11:00 a. m. From:'signotificaciones@adssistemas.mx' - Para:'x@x.com' - Asunto:'Entrega de Factura SUCURSAL NARANJO SN-22' - CCP: '' - Adjuntos: 1