605 lines
40 KiB
Plaintext
605 lines
40 KiB
Plaintext
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="RepProductosServiciosPeriodo.aspx.cs" Inherits="Ventas_RepProductosServiciosPeriodo" %>
|
|
|
|
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
|
</asp:Content>
|
|
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
|
<style>
|
|
.btnopaco {
|
|
background-color: rgba(0,0,0,0.2);
|
|
color: #FFF;
|
|
}
|
|
|
|
.btnopaco:hover {
|
|
background-color: rgba(0,0,0,0.4);
|
|
color: #FFF;
|
|
font-weight: bold;
|
|
}
|
|
</style>
|
|
</asp:Content>
|
|
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
|
Reporte de Productos Servicios Periodo
|
|
</asp:Content>
|
|
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
|
<asp:UpdatePanel runat="server">
|
|
<ContentTemplate>
|
|
<li>
|
|
<asp:LinkButton ID="ImgImprimir" runat="server" OnClientClick="alertaImpresion()" OnClick="ImgImprimir_Click"> <i class="fa fa-file-pdf-o" style="font-weight:bold;"></i> PDF</asp:LinkButton>
|
|
</li>
|
|
<li>
|
|
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivPersonalizar" ID="ImgPersonalizar" runat="server"> <i class="fa fa-pencil"></i> Personalizar</asp:HyperLink>
|
|
</li>
|
|
</ContentTemplate>
|
|
<Triggers>
|
|
<asp:PostBackTrigger ControlID="ImgImprimir" />
|
|
</Triggers>
|
|
</asp:UpdatePanel>
|
|
<li>
|
|
<asp:LinkButton ID="ImgExcel" runat="server" OnClick="ImgExcel_Click"> <i class="fa fa-file-excel-o" style="font-weight:bold;"></i> Excel</asp:LinkButton>
|
|
</li>
|
|
<li runat="server" id="liRepHP" visible="false">
|
|
<asp:LinkButton ID="LnkRepHP" runat="server" OnClick="LnkRepHP_Click"> <i class="fa fa-file-excel-o" style="font-weight:bold;"></i> Reporte HP Excel</asp:LinkButton>
|
|
</li>
|
|
<li>
|
|
<asp:HyperLink NavigateUrl="javascript:;" data-toggle="modal" data-target="#DivTipoCambio" ID="ImgTipoCambio" runat="server"> <i class="fa fa-money"></i> Ver Dlls en pesos</asp:HyperLink>
|
|
</li>
|
|
</asp:Content>
|
|
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
|
</asp:Content>
|
|
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
|
</asp:Content>
|
|
<asp:Content ID="Content7" 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" OnClick="BtnConsultar_Click" Text="Consultar" class="btn btn-primary" />
|
|
<a href="javascript:;" class="expand"></a>
|
|
</div>
|
|
<div class="titlefiltros caption">
|
|
<div class="row">
|
|
<label class="col-md-1">Tipo: </label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" ID="DdlTipoComprobante" runat="server" OnSelectedIndexChanged="DdlTipoComprobante_SelectedIndexChanged" AutoPostBack="true">
|
|
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
|
<asp:ListItem Text="Ingresos" Value="Ing"></asp:ListItem>
|
|
<asp:ListItem Text="Egresos" Value="Egs"></asp:ListItem>
|
|
<asp:ListItem Text="Remisión" Value="Rem"></asp:ListItem>
|
|
<asp:ListItem Text="Cotización" Value="Cot"></asp:ListItem>
|
|
<asp:ListItem Text="Anticipos" Value="Ant"></asp:ListItem>
|
|
<asp:ListItem Text="Pedido" Value="Ped"></asp:ListItem>
|
|
<asp:ListItem Text="Devolucion" Value="Dev"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 ">Estatus:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlEstatus" runat="server" AppendDataBoundItems="true" DataTextField="EstatusFactura" DataValueField="CveEstatusFactura" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 ">Grupo:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlGrupo" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<%-- <asp:ListItem Text="Año" Value="1"></asp:ListItem>
|
|
<asp:ListItem Text="Mes" Value="2"></asp:ListItem>
|
|
<asp:ListItem Selected="True" Text="Año/Mes" Value="3"></asp:ListItem>
|
|
<asp:ListItem Text="Fecha" Value="4"></asp:ListItem>
|
|
<asp:ListItem Text="Cliente" Value="5"></asp:ListItem>
|
|
<asp:ListItem Text="Sucursal" Value="6"></asp:ListItem>
|
|
<asp:ListItem Text="Corte" Value="16"></asp:ListItem>
|
|
<asp:ListItem Text="Vendedor" Value="7"></asp:ListItem>
|
|
<asp:ListItem Text="Usuario" Value="8"></asp:ListItem>
|
|
<asp:ListItem Text="Estatus Fact." Value="9"></asp:ListItem>
|
|
<asp:ListItem Text="% IVA" Value="10"></asp:ListItem>
|
|
<asp:ListItem Text="Año Ejec" Value="11"></asp:ListItem>
|
|
<asp:ListItem Text="Mes Ejec" Value="12"></asp:ListItem>
|
|
<asp:ListItem Text="Año/Mes Ejec" Value="13"></asp:ListItem>
|
|
<asp:ListItem Text="Fecha Ejec" Value="14"></asp:ListItem>
|
|
<asp:ListItem Text="Sucursal Ejec" Value="15"></asp:ListItem>
|
|
<asp:ListItem Text="Año/Mes Sucursal" Value="17"></asp:ListItem>
|
|
<asp:ListItem Text="% IVA Sucursal" Value="18"></asp:ListItem>--%>
|
|
</asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="portlet-body">
|
|
<div class="row">
|
|
<asp:Label ID="LblProyecto" runat="server" class="col-md-1 truncate">Proyecto:</asp:Label>
|
|
<div runat="server" id="DivProyecto" class="col-md-2">
|
|
<asp:DropDownList ID="DdlProyecto" runat="server" AutoPostBack="true" AppendDataBoundItems="true" DataTextField="Proyecto" DataValueField="CveProyecto" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
|
</div>
|
|
<asp:Label ID="LblSubProyecto" runat="server" class="col-md-1 truncate">SubProyecto:</asp:Label>
|
|
<div runat="server" id="DivSubProyecto" class="col-md-2">
|
|
<asp:DropDownList ID="DdlSubProyecto" runat="server" AppendDataBoundItems="true" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 truncate">F.I.:</label>
|
|
<div class="col-md-2">
|
|
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 140px !important; padding: 0px;">
|
|
<asp:TextBox ID="txtFechaI" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton ID="imgCalendario" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
</span>
|
|
<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="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
<label class="col-md-1 truncate">F.F.:</label>
|
|
<div class="col-md-2">
|
|
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 140px !important; padding: 0px;">
|
|
<asp:TextBox ID="txtFechaF" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton ID="imgCalendarioF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
</span>
|
|
<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="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
<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 class="row">
|
|
<label runat="server" id="LblSubProyectoEjecucion" class="col-md-1 truncate">SubProyecto Ejecución:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlSubProyectoEjecucion" runat="server" AppendDataBoundItems="true" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 truncate">F.I. E.:</label>
|
|
<div class="col-md-2">
|
|
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 140px !important; padding: 0px;">
|
|
<asp:TextBox ID="TxtFechaIEjec" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton ID="ImgCalFechaIEjec" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
</span>
|
|
<ajax:MaskedEditExtender ID="MEEFechaIEjec" runat="server" TargetControlID="TxtFechaIEjec" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
|
<ajax:CalendarExtender ID="CalFechaIEjec" runat="server" TargetControlID="TxtFechaIEjec" PopupButtonID="ImgCalFechaIEjec" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="RFVFechaIEjec" runat="server" ControlToValidate="TxtFechaIEjec" Display="None" ErrorMessage="El campo <b>''Fecha Inicial Ejecución''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="CVFechaIEjec" runat="server" ControlToValidate="TxtFechaIEjec" Display="None" ErrorMessage="El campo <b>''Fecha Inicial Ejecución''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaIEjec1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaIEjec" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaIEjec2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaIEjec" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
<label class="col-md-1 truncate">F.F. E.:</label>
|
|
<div class="col-md-2">
|
|
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 140px !important; padding: 0px;">
|
|
<asp:TextBox ID="TxtFechaFEjec" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton ID="ImgCalFechaFEjec" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
|
</span>
|
|
<ajax:MaskedEditExtender ID="MEEFechaFEjec" runat="server" TargetControlID="TxtFechaFEjec" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
|
<ajax:CalendarExtender ID="CalFechaFEjec" runat="server" TargetControlID="TxtFechaFEjec" PopupButtonID="ImgCalFechaFEjec" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="RFVFechaFEjec" runat="server" ControlToValidate="TxtFechaFEjec" Display="None" ErrorMessage="El campo <b>''Fecha Final Ejecución''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="CVFechaFEjec" runat="server" ControlToValidate="TxtFechaFEjec" Display="None" ErrorMessage="El campo <b>''Fecha Final Ejecución''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaFEjec1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaFEjec" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaFEjec2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaFEjec" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
<label class="col-md-1 truncate">Vendedor:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlVendedor" runat="server" AppendDataBoundItems="true" DataTextField="Vendedor" DataValueField="CveVendedor" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-md-1 truncate">Usuario:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlUsuario" runat="server" AppendDataBoundItems="true" DataTextField="Usuario" DataValueField="CveUsuario" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 ">Cliente:</label>
|
|
<div class="col-md-2">
|
|
|
|
<ADS:Dropdownlost CssClassDdl="select2me" ID="DdlClientes" Width="100%" data-metodo="getcliente" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" CssStyle="width: 100%;"></ADS:Dropdownlost>
|
|
<%--<asp:DropDownList ID="DdlClientes" runat="server" AppendDataBoundItems="true" DataTextField="Nombre" DataValueField="CveCliente" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>--%>
|
|
</div>
|
|
<label class="col-md-1 truncate">Fecha Mostrada:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlTipoFecha" runat="server" AppendDataBoundItems="true" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Selected="True" Text="Fecha Factura" Value="1"></asp:ListItem>
|
|
<asp:ListItem Text="Fecha Ejecución" Value="2"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-md-1 truncate">Categoría:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlCategoria" CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="Categoria" DataValueField="CveCategoria">
|
|
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 truncate">Clasificación:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlClasificacion" Class="table-group-action-input form-control input-inline input-small input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="Clasificacion" DataValueField="CveClasificacion">
|
|
<asp:ListItem Selected="True" Text="Todas" Value="-1"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
<label class="col-md-1 truncate">Productos Servicios:</label>
|
|
<div class="col-md-2">
|
|
<ADS:Dropdownlost runat="server" ID="DdlPS" CssStyle="width:55%;" CssClass="DdlPS" CssClassDdl="select2me " DataTextField="PSCodigo" DataValueField="CvePS" />
|
|
</div>
|
|
<label title="Clasificación Cliente" data-toggle="tooltip" data-placement="top" class="col-md-1 ">Clasificacion Cli.:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList ID="DdlClienteClasificacion" AutoPostBack="true" OnSelectedIndexChanged="DdlClienteClasificacion_SelectedIndexChanged" runat="server" AppendDataBoundItems="true" CssClass="table-group-action-input form-control input-inline input-small input-sm select2me" DataTextField="ClienteClasificacion" DataValueField="CveClienteClasificacion"></asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
<div class="row" >
|
|
<label class="col-md-1 truncate">Lectura administrativa:</label>
|
|
<div class="col-md-2">
|
|
<asp:CheckBox ID="ChkLecturaAdmin" runat="server" Checked="false" CssClass="input-sm" />
|
|
</div>
|
|
|
|
<label class="col-md-1 truncate">Vista:</label>
|
|
<div class="col-md-2">
|
|
<asp:DropDownList runat="server" ID="DdlVista" CssClass="table-group-action-input form-control input-inline input-small input-sm select2me">
|
|
<asp:ListItem Value="1" >Importe</asp:ListItem>
|
|
<asp:ListItem Value="2">Cantidad</asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" OnRowDataBound="GvDatos_RowDataBound" Width="99%" EmptyDataText="No se encontraron Ventas con los filtros especificados" data-sort="true" ToolTip="Listado de Ventas" Style="text-align: center;" GridLines="None" CssClass="table table-striped table-advance table-hover Widthall ScrollAD">
|
|
<Columns>
|
|
<asp:BoundField DataField="GPO" HeaderText="Grupo" ItemStyle-HorizontalAlign="Left" />
|
|
<asp:BoundField DataField="Cantidad" HeaderText="Cantidad" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Enero" HeaderText="Ene" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Febrero" HeaderText="Feb" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Marzo" HeaderText="Mar" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Abril" HeaderText="Abr" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Mayo" HeaderText="May" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Junio" HeaderText="Jun" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Julio" HeaderText="Jul" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Agosto" HeaderText="Ago" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Septiembre" HeaderText="Sep" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Octubre" HeaderText="Oct" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Noviembre" HeaderText="Nov" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Diciembre" HeaderText="Dic" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
<asp:BoundField DataField="Total" HeaderText="Total" ItemStyle-HorizontalAlign="Right" DataFormatString="{0:N2}" />
|
|
</Columns>
|
|
</asp:GridView>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<asp:UpdatePanel runat="server" ID="UPPersonalizar" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<div id="DivPersonalizar" class="modal fade" role="dialog">
|
|
<div class="modal-dialog">
|
|
<!-- Modal content-->
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
|
<h4 class="modal-title">
|
|
<asp:Label ID="Label1" runat="server" ClientIDMode="Static" Text="Ver En:"></asp:Label></h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<table style="width: 335px;" class="table table-striped table-advance table-hover">
|
|
<tbody>
|
|
<tr>
|
|
<td style="text-align: left;">
|
|
<asp:RadioButton ID="RbSubTotal" Checked="true" GroupName="GnPersonalizar" Text="SubTotal" runat="server" /></td>
|
|
<td style="text-align: left;">
|
|
<asp:RadioButton ID="RbTotal" GroupName="GnPersonalizar" Text="Total" runat="server" /></td>
|
|
<td style="text-align: left;">
|
|
<asp:RadioButton ID="RbIVA" GroupName="GnPersonalizar" Text="IVA" runat="server" /></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-success" data-dismiss="modal" onclick="$('#BtnPersonalizar').click();">Personalizar</button>
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<asp:UpdatePanel runat="server">
|
|
<ContentTemplate>
|
|
<asp:Button ID="BtnPersonalizar" Style="display: none" ClientIDMode="Static" runat="server" Text="Personalizar" class="btn btn-success" OnClick="BtnPersonalizar_Click" />
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<asp:UpdatePanel runat="server" ID="UpTipoCambio" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<div id="DivTipoCambio" class="modal fade" role="dialog">
|
|
<div class="modal-dialog">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
|
<h4 class="modal-title">
|
|
<asp:Label ID="Label2" runat="server" ClientIDMode="Static" Text="Cambiar Tipo Cambio de Dólares"></asp:Label>
|
|
</h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<asp:UpdatePanel runat="server" ID="UpBodyTipoCambio" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<asp:RadioButtonList runat="server" ID="RblTipoCambio" OnSelectedIndexChanged="RblTipoCambio_SelectedIndexChanged" AutoPostBack="true">
|
|
<asp:ListItem Selected="true" Text="Moneda Original" Value="1"></asp:ListItem>
|
|
<asp:ListItem Text="Dólares en Tipo Cambio de la Fecha Venta" Value="2"></asp:ListItem>
|
|
<asp:ListItem Text="Tipo Cambio Especifico" Value="3"></asp:ListItem>
|
|
</asp:RadioButtonList>
|
|
<div class="row" style="margin-left: 10px;" runat="server" id="LiEspecifico" visible="false">
|
|
Especifico:
|
|
<asp:TextBox ID="TxtEspecifico" runat="server" Width="55px" />
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<asp:Button ID="BtnTipoCambio" OnClick="BtnTipoCambio_Click" runat="server" Text="Aceptar" class="btn btn-primary" />
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<div id="DivModalPrint" class="modal ADS fade" role="dialog">
|
|
<div class="modal-dialog">
|
|
<!-- Modal content-->
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
|
<h4 class="modal-title">Reporte</h4>
|
|
</div>
|
|
<div class="modal-body">
|
|
<p>El reporte requiere papel tipo oficio.</p>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
<div class="row" id="DvGraficas" visible="true" runat="server">
|
|
<div id="DvGraVentas" runat="server" class="col-md-6 col-sm-6" style="width: 100%">
|
|
<!-- BEGIN REGIONAL STATS PORTLET-->
|
|
<div class="portlet light ">
|
|
<div class="portlet-title">
|
|
<div class="caption">
|
|
<i class="icon-graph font-red-sunglo"></i>
|
|
<span class="caption-subject font-red-sunglo bold uppercase">Grafica</span>
|
|
</div>
|
|
<div class="tools">
|
|
<a href="javascript:;" class="collapse" data-original-title="" title=""></a>
|
|
<a href="javascript:;" class="reload" data-original-title="" title=""></a>
|
|
<a href="javascript:;" class="remove" data-original-title="" title=""></a>
|
|
</div>
|
|
</div>
|
|
<div class="portlet-body">
|
|
<div id="chartdiv" style="text-align: center;height:600px!important">
|
|
</div>
|
|
<div id="div_ventas" runat="server" style="text-align: center;">
|
|
<%--<img src="/Metronic/assets/admin/layout/img/loading.gif" alt="loading" />--%>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!-- END REGIONAL STATS PORTLET-->
|
|
</div>
|
|
</div>
|
|
|
|
|
|
</asp:Content>
|
|
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
|
|
<script>
|
|
|
|
function alertaImpresion() {
|
|
$('#DivModalPrint').modal() // initialized with defaults
|
|
// $('#DeleteModal').modal({ keyboard: false }) // initialized with no keyboard
|
|
// $('#DeleteModal').modal('show')
|
|
return true;
|
|
}
|
|
</script>
|
|
|
|
<script type="text/javascript">
|
|
//function CargaGrafica() { }
|
|
//function CargaGrafica3() { }
|
|
//function filldata() {
|
|
|
|
// CargaGrafica();
|
|
// CargaGrafica3();
|
|
// if ($('#C_DivIndicadores')) {
|
|
// $('#C_DivIndicadores').slick({
|
|
// lazyLoad: 'ondemand',
|
|
// slidesToShow: 3,
|
|
// slidesToScroll: 1,
|
|
// dots: true,
|
|
// infinite: true,
|
|
// autoplay: true,
|
|
// autoplaySpeed: 5000,
|
|
// responsive: [
|
|
// {
|
|
// breakpoint: 1024,
|
|
// settings: {
|
|
// slidesToShow: 2,
|
|
// slidesToScroll: 1,
|
|
// infinite: true,
|
|
// dots: true
|
|
// }
|
|
// }, {
|
|
// breakpoint: 600,
|
|
// settings: {
|
|
// slidesToShow: 1,
|
|
// slidesToScroll: 1,
|
|
// infinite: true,
|
|
// dots: true
|
|
// }
|
|
// }]
|
|
// });
|
|
// $('#C_DivIndicadores').show();
|
|
// $('#C_chartcheckboxes').hide();
|
|
// }
|
|
//}
|
|
|
|
$(document).ready(function () {
|
|
|
|
//filldata();
|
|
//Sys.Application.add_load(function (s, e) {
|
|
// filldata()
|
|
//});
|
|
});
|
|
function CargaDia(pFecha) {
|
|
__doPostBack('txtFecha', pFecha);
|
|
}
|
|
function MueveScroll(pPos) {
|
|
var div = document.getElementById('divDias');
|
|
// div.scrollTop = pPos;
|
|
}
|
|
function AsignaScroll() {
|
|
try {
|
|
document.getElementById("topScroll").value = document.getElementById('divDias').scrollTop;
|
|
}
|
|
catch (e)
|
|
{ }
|
|
}
|
|
|
|
$('.Consultar').click(function () {
|
|
var chart = $('#DvGraVentas').highcharts();
|
|
var seriesLength = chart.series.length;
|
|
for (var i = seriesLength - 1; i > -1; i--) {
|
|
chart.series[i].remove();
|
|
}
|
|
});
|
|
|
|
</script>
|
|
|
|
<!-- Librería principal de amCharts 4 -->
|
|
<script src="https://cdn.amcharts.com/lib/4/core.js"></script>
|
|
|
|
<!-- Módulo de gráficos de XYChart -->
|
|
<script src="https://cdn.amcharts.com/lib/4/charts.js"></script>
|
|
|
|
<!-- Tema animado de amCharts 4 -->
|
|
<script src="https://cdn.amcharts.com/lib/4/themes/animated.js"></script>
|
|
|
|
<!-- Paquete de idioma español -->
|
|
<script src="https://cdn.amcharts.com/lib/4/lang/es_ES.js"></script>
|
|
|
|
<script >
|
|
|
|
// Función para crear series dinámicamente
|
|
function createSeries(field, name) {
|
|
var series = chart.series.push(new am4charts.LineSeries());
|
|
series.dataFields.valueY = field;
|
|
series.dataFields.categoryX = "mes";
|
|
series.name = name;
|
|
series.strokeWidth = 2;
|
|
|
|
// Añadir bullets a la serie
|
|
var bullet = series.bullets.push(new am4charts.CircleBullet());
|
|
bullet.circle.radius = 4;
|
|
bullet.circle.fill = am4core.color("#fff");
|
|
bullet.circle.strokeWidth = 2;
|
|
|
|
// Configurar el tooltip para cada serie
|
|
series.tooltipText = "{name}: [bold]{valueY}[/]";
|
|
series.tooltip.pointerOrientation = "vertical";
|
|
series.tooltip.background.cornerRadius = 5;
|
|
series.tooltip.background.fillOpacity = 0.8;
|
|
series.tooltip.label.padding(10, 10, 10, 10);
|
|
|
|
// Asegurar que el label del tooltip sea visible
|
|
series.tooltip.label.fill = am4core.color("#000"); // Texto en negro
|
|
|
|
// Mostrar el tooltip solo al pasar el cursor sobre la serie
|
|
series.tooltip.showInViewport = false;
|
|
|
|
// Habilitar interacciones en la serie
|
|
series.interactionsEnabled = true;
|
|
}
|
|
|
|
|
|
function generaGrafico(dtGrafico,dtseries) {
|
|
|
|
// Importar las librerías de amCharts
|
|
am4core.useTheme(am4themes_animated);
|
|
|
|
// Crear el gráfico
|
|
var chart = am4core.create("chartdiv", am4charts.XYChart);
|
|
|
|
// Ejemplo de datos dinámicos
|
|
chart.data = dtGrafico; //[
|
|
|
|
var categoryAxis = chart.xAxes.push(new am4charts.CategoryAxis());
|
|
categoryAxis.dataFields.category = "mes";
|
|
categoryAxis.renderer.grid.template.location = 0;
|
|
categoryAxis.renderer.minGridDistance = 30;
|
|
|
|
// Configuración del eje Y (Importe)
|
|
var valueAxis = chart.yAxes.push(new am4charts.ValueAxis());
|
|
valueAxis.title.text = "Importe";
|
|
|
|
for (var i = 0; i < dtseries.length; i++) {
|
|
var item = dtseries[i];
|
|
var key = Object.keys(item)[0];
|
|
var value = item[key];
|
|
|
|
var series = chart.series.push(new am4charts.LineSeries());
|
|
series.dataFields.valueY = key;
|
|
series.dataFields.categoryX = "mes";
|
|
series.name = value;
|
|
series.strokeWidth = 2;
|
|
|
|
// Añadir bullets a la serie
|
|
var bullet = series.bullets.push(new am4charts.CircleBullet());
|
|
bullet.circle.radius = 4;
|
|
bullet.circle.fill = am4core.color("#fff");
|
|
bullet.circle.strokeWidth = 2;
|
|
|
|
// Configurar el tooltip para cada serie
|
|
series.tooltipText = "{name}: [bold]{valueY}[/]";// "{" + value + "}: [bold]{" + key +"}[/]";
|
|
series.tooltip.pointerOrientation = "vertical";
|
|
series.tooltip.background.cornerRadius = 5;
|
|
series.tooltip.background.fillOpacity = 0.8;
|
|
series.tooltip.label.padding(10, 10, 10, 10);
|
|
|
|
// Asegurar que el label del tooltip sea visible
|
|
series.tooltip.label.fill = am4core.color("#000"); // Texto en negro
|
|
|
|
// Mostrar el tooltip solo al pasar el cursor sobre la serie
|
|
series.tooltip.showInViewport = false;
|
|
|
|
// Habilitar interacciones en la serie
|
|
series.interactionsEnabled = true;
|
|
|
|
|
|
}
|
|
|
|
// Habilitar el cursor pero deshabilitar su tooltip
|
|
chart.cursor = new am4charts.XYCursor();
|
|
chart.cursor.behavior = "none"; // Deshabilitar pan o zoom
|
|
chart.cursor.lineX.disabled = true;
|
|
chart.cursor.lineY.disabled = true;
|
|
chart.cursor.tooltipEnabled = false; // Deshabilitar el tooltip del cursor
|
|
|
|
// Leyenda
|
|
chart.legend = new am4charts.Legend();
|
|
|
|
// Exportar el gráfico
|
|
chart.exporting.menu = new am4core.ExportMenu();
|
|
}
|
|
|
|
|
|
|
|
|
|
</script>
|
|
|
|
</asp:Content>
|
|
|