794 lines
52 KiB
Plaintext
794 lines
52 KiB
Plaintext
<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="ClientesAbonar.aspx.vb" Inherits="Ventas_ClientesAbonar" %>
|
|
|
|
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
|
</asp:Content>
|
|
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
|
<style>
|
|
.dashboard-stat2 {
|
|
padding: 1px 2px 15px 10px;
|
|
}
|
|
</style>
|
|
</asp:Content>
|
|
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
|
<asp:UpdatePanel ID="UpnTools" runat="server" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<li>
|
|
<asp:HyperLink ID="HlSaldarCuentasIncobrables" data-toggle="modal" data-target="#ModalSaldarCuentaIncobrable" title="Saldar Cuentas!" runat="server" Visible="false"><i class="fa fa-money"></i> Saldar Cuentas Incobrables</asp:HyperLink>
|
|
</li>
|
|
<li>
|
|
<asp:HyperLink ID="HplVincularIntermediario" data-toggle="modal" data-target="#ModalVincularIntermediario" title="Vincular Intermediario" runat="server"><i class="fa fa-money"></i> Vincular Intermediario</asp:HyperLink>
|
|
</li>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</asp:Content>
|
|
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
|
|
Abonar Cliente:
|
|
<asp:Label ID="LbEncabezado" runat="server" Text=""></asp:Label>
|
|
</asp:Content>
|
|
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
|
</asp:Content>
|
|
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
|
|
|
|
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<asp:HiddenField ID="HdnTipoTransaccionAbreviatura" runat="server" Value="" />
|
|
<div class="row">
|
|
|
|
<div class="col-lg-8 col-md-10">
|
|
<div class="chequesie">
|
|
<div class="chequesie1">
|
|
<div class="row" id="divTipoPago" runat="server" >
|
|
<div class="col-md-7">
|
|
<asp:RadioButtonList ID="RblTipoPago" AutoPostBack="true" runat="server" RepeatDirection="Horizontal">
|
|
<asp:ListItem Value="1" Selected="true">Banco </asp:ListItem>
|
|
<asp:ListItem Value="3">Ingresos x Comprobar</asp:ListItem>
|
|
<asp:ListItem Value="2">Pago Intermediario</asp:ListItem>
|
|
</asp:RadioButtonList>
|
|
</div>
|
|
<div class="col-md-5">
|
|
<asp:Label CssClass="col-md-2" Text="" ID="LbTipoMoneda" runat="server" />
|
|
<div class="col-md-5">
|
|
<asp:CheckBox Text="Pagar con pesos" TextAlign="Right" Visible="false" AutoPostBack="true" ID="ChkPagarPesos" OnCheckedChanged="ChkPagarPesos_CheckedChanged" runat="server" ClientIDMode="Static" />
|
|
<asp:CheckBox Text="Pagar con dólares" TextAlign="Right" Visible="false" AutoPostBack="true" ID="ChkPagarDolares" runat="server" OnCheckedChanged="ChkPagarDolares_CheckedChanged" ClientIDMode="Static" />
|
|
</div>
|
|
<div class="col-md-5" runat="server" id="DivTCDolares" visible="false">
|
|
T.C:
|
|
<asp:TextBox ID="TxtTCDolares" runat="server" placeholder="Tipo de Cambio" CssClass="form-control input-sm" MaxLength="12" Width="70px" ClientIDMode="Static" Style="text-align: right; display: inline-block;" />
|
|
<asp:RequiredFieldValidator ID="RFVTCDolares" Enabled="false" runat="server" ControlToValidate="TxtTCDolares" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo de Cambio''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="RFVTCDolares" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<asp:Label ID="LbImporteMN" Text="" ClientIDMode="Static" runat="server" />
|
|
</div>
|
|
<div class="col-md-5" id="DivTC" style="display: none;">
|
|
T.C.:
|
|
<asp:TextBox ID="TxtTC" runat="server" placeholder="Tipo de Cambio" CssClass="form-control input-sm" MaxLength="12" Width="70px" ClientIDMode="Static" Style="text-align: right; display: inline-block;" />
|
|
<asp:RequiredFieldValidator ID="RFVTC" Enabled="false" runat="server" ControlToValidate="TxtTC" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo de Cambio''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RFVTC" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<asp:Label ID="LbImporteME" Text="" ClientIDMode="Static" runat="server" />
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
<asp:Panel ID="PanelIngresos" runat="server" Visible="false">
|
|
<div class="row">
|
|
<label class="col-xs-2 control-label">Ingreso:</label>
|
|
<div class="col-xs-10">
|
|
<asp:DropDownList ID="DdlIngreso" runat="server" CssClass="form-control input-sm select2me" AutoPostBack="true" DataTextField="RazonSocial" DataValueField="CveIE" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>
|
|
<asp:RequiredFieldValidator ID="RFVDeudor" runat="server" ControlToValidate="DdlIngreso" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Ingresos''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCEDeudor" runat="server" HighlightCssClass="vco" TargetControlID="RFVDeudor" Width="300px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
</asp:Panel>
|
|
<div class="row" id="divIntermediario" runat="server" visible="false">
|
|
<label class="col-md-2">Intermediario:</label>
|
|
<div class="col-md-4">
|
|
<asp:DropDownList ID="DdlProveedorPagoInt" CssClass="form-control input-sm select2me" runat="server" AutoPostBack="true" DataTextField="Proveedor" DataValueField="CveProveedor" ValidationGroup="GrpGuardar" />
|
|
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="DdlProveedorPagoInt" InitialValue="" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />Es necesario seleccionar un <b>''Intermediario''</b>, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender3" runat="server" HighlightCssClass="vco" TargetControlID="RequiredFieldValidator1" Width="300px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div id="DivDatosBancarios" runat="server" class="chequesie1">
|
|
<div class="row">
|
|
<label class="col-md-2">Movimiento:</label>
|
|
<div class="col-md-4">
|
|
<asp:DropDownList ID="DdlTipoTransaccion" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="TipoTransaccion" DataValueField="CveTipoTransaccion" ValidationGroup="GrpGuardar">
|
|
</asp:DropDownList>
|
|
<asp:RequiredFieldValidator ID="RFVTipoTransaccion" runat="server" ControlToValidate="DdlTipoTransaccion" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo Movimiento''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCETipoTransaccion" runat="server" HighlightCssClass="vco" TargetControlID="RFVTipoTransaccion" Width="300px"></ajax:ValidatorCalloutExtender>
|
|
<asp:HiddenField ID="HdnTipoTransaccion" runat="server" Value="" />
|
|
</div>
|
|
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-md-2 control-label">Cuenta:</label>
|
|
<div class="col-md-5">
|
|
<asp:DropDownList ID="DdlCuenta" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" AutoPostBack="true" DataTextField="NumCuentaMoneda" DataValueField="CveCuenta" ValidationGroup="GrpGuardar">
|
|
</asp:DropDownList>
|
|
<asp:RequiredFieldValidator ID="RFVCuenta" runat="server" ControlToValidate="DdlCuenta" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCOCuenta" runat="server" HighlightCssClass="vco" TargetControlID="RFVCuenta" Width="300px"></ajax:ValidatorCalloutExtender>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="col-md-5" runat="server" id="DivTCDolaresDolares" visible="false">
|
|
T.C:
|
|
<asp:TextBox ID="TxtTCDolaresDolares" runat="server" placeholder="Tipo de Cambio" CssClass="form-control input-sm" MaxLength="12" Width="70px" ClientIDMode="Static" Style="text-align: right; display: inline-block;" />
|
|
<asp:RequiredFieldValidator ID="RFVTCDolaresDolares" Enabled="false" runat="server" ControlToValidate="TxtTCDolaresDolares" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo de Cambio''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender7" runat="server" HighlightCssClass="vco" TargetControlID="RFVTCDolaresDolares" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
|
|
<asp:Button ID="BtnCambiaTipoMoneda" Text="" OnClick="BtnCambiaTipoMoneda_Click" ClientIDMode="Static" Style="display: none;" runat="server" />
|
|
</div>
|
|
</div>
|
|
<div class="chequesie2">
|
|
<div class="row">
|
|
<div class="col-md-8"></div>
|
|
<label class="col-md-1 control-label text-right">Fecha:</label>
|
|
<div class="col-md-3">
|
|
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
|
|
<asp:TextBox ID="TxtFechaDocumento" runat="server" CssClass="form-control"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton runat="server" ID="ImgCalendario" class="btn default"><i class="fa fa-calendar"></i></asp:LinkButton>
|
|
</span>
|
|
</div>
|
|
|
|
<ajax:MaskedEditExtender ID="MEEFecha" runat="server" TargetControlID="TxtFechaDocumento" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
|
<ajax:CalendarExtender ID="Calendario" runat="server" TargetControlID="TxtFechaDocumento" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="RFVFechaDocumento" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''Fecha''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="CVFechaDocumento" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''Fecha''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
|
<asp:RangeValidator ID="RVTxtFechaDocumento" runat="server" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha del documento no puede ser superior a la fecha actual" ControlToValidate="TxtFechaDocumento" MinimumValue="01/01/1900" Type="Date" ValidationGroup="GrpGuardar"></asp:RangeValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaDocumento1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaDocumento" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaDocumento2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaDocumento" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="VCOFechaDocumento3" runat="server" HighlightCssClass="vco" TargetControlID="RVTxtFechaDocumento" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-md-2 control-label">
|
|
<asp:Label ID="LblFolio" runat="server" Text="Folio"> </asp:Label>:</label>
|
|
<div class="col-md-2">
|
|
<asp:TextBox ID="TxtFolio" CssClass="form-control input-sm" runat="server" MaxLength="12" Width="100px"></asp:TextBox>
|
|
<asp:RequiredFieldValidator ID="RFVFolio" runat="server" ControlToValidate="TxtFolio" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Folio''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="RFVFolio" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
<div class="col-md-4"></div>
|
|
<label class="col-md-1 control-label text-right">Importe:</label>
|
|
<div class="col-md-2 input-icon">
|
|
<i style="margin: 0px;">$</i>
|
|
<asp:TextBox ID="TxtImporte" runat="server" CssClass="form-control input-sm" MaxLength="12" Width="140px" ClientIDMode="Static" Style="text-align: right;"></asp:TextBox>
|
|
<ajax:FilteredTextBoxExtender ID="ftbe" runat="server" TargetControlID="TxtImporte" FilterType="Custom, Numbers" ValidChars="+-.," />
|
|
<asp:RangeValidator ID="RVImporte" runat="server" Enabled="false" Type="Currency" MinimumValue="0" MaximumValue="0" ErrorMessage="Importe Excedido" ControlToValidate="TxtImporte" Display="Dynamic" ValidationGroup="GrpGuardar"></asp:RangeValidator>
|
|
</div>
|
|
</div>
|
|
<div class="row" id="divAbonese" runat="server">
|
|
<label class="col-md-2">
|
|
<asp:Label ID="LblPagueseA" runat="server" Text="Abónese a"></asp:Label>:</label>
|
|
<div class="col-md-7">
|
|
<asp:HiddenField ID="HdnCveProveedor" runat="server" ClientIDMode="Static" Value="-1" />
|
|
<asp:Button ID="BtnBuscarProveedor" runat="server" ClientIDMode="Static" Text="Buscar Proveedor" Style="display: none;" class="btn btn-primary" />
|
|
<asp:TextBox ID="TxtAboneA" CssClass="form-control input-sm" runat="server" MaxLength="70" Width="394px"></asp:TextBox>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<label class="col-md-2">Observaciones</label>
|
|
<div class="col-md-7">
|
|
<asp:TextBox ID="TxtObservaciones" CssClass="form-control input-sm" runat="server" MaxLength="500" Width="400px" Rows="3" TextMode="MultiLine" ClientIDMode="Static"></asp:TextBox>
|
|
<asp:HiddenField ID="HdnObs" runat="server" ClientIDMode="Static" />
|
|
</div>
|
|
<div class="col-md-2 input-icon">
|
|
<i style="margin: 0px;">$</i>
|
|
<asp:TextBox ID="TxtOtrosImportes" runat="server" ReadOnly="true" CssClass="form-control input-sm" Visible="false" MaxLength="12" Width="140px" placeholder="Otros Importes" ClientIDMode="Static" Style="text-align: right;"></asp:TextBox>
|
|
<ajax:FilteredTextBoxExtender ID="FTEOtrosImportes" runat="server" TargetControlID="TxtOtrosImportes" FilterType="Custom, Numbers" ValidChars="+-.," />
|
|
<asp:RangeValidator ID="RangeValidator1" runat="server" Enabled="false" Type="Currency" MinimumValue="0" MaximumValue="0" ErrorMessage="Importe Excedido" ControlToValidate="TxtOtrosImportes" Display="Dynamic" ValidationGroup="GrpGuardar"></asp:RangeValidator>
|
|
<asp:TextBox ID="TxtTotal" runat="server" CssClass="form-control input-sm" Visible="false" MaxLength="12" Width="140px" placeholder="Total" Enabled="false" ClientIDMode="Static" Style="text-align: right;"></asp:TextBox>
|
|
</div>
|
|
</div>
|
|
<div class="row" runat="server" id="rowComisiones">
|
|
<label class="col-md-2" runat="server" id="lblpagocomisiones">Otros Ingresos:</label>
|
|
<div class="col-md-3">
|
|
<asp:CheckBox ID="ChkAjusteOI" runat="server" AutoPostBack="true" />
|
|
</div>
|
|
</div>
|
|
|
|
<asp:UpdatePanel ID="UpCuentaDeposito" UpdateMode="Conditional" runat="server">
|
|
<ContentTemplate>
|
|
<div class="row" id="trCuentaDeposito" runat="server" visible="False">
|
|
<label class="col-md-2 control-label">Cuenta Depósito</label>
|
|
<div class="col-md-10">
|
|
<asp:DropDownList ID="DdlCuentaDeposito" CssClass="form-control input-sm select2me" AutoPostBack="true" OnSelectedIndexChanged="DdlCuentaDeposito_SelectedIndexChanged" runat="server" DataTextField="CuentaDeposito" DataValueField="CveCuentaDeposito" AppendDataBoundItems="True" Width="400px"></asp:DropDownList>
|
|
<%--<asp:RequiredFieldValidator ID="RFVCuentaDeposito" runat="server" ControlToValidate="DdlCuentaDeposito" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuenta de Depósito''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCECuentaDeposito" runat="server" HighlightCssClass="vco" TargetControlID="RFVCuentaDeposito" Width="300px"></ajax:ValidatorCalloutExtender>--%>
|
|
</div>
|
|
</div>
|
|
<div class="row" id="TrReferenciaCIE" runat="server" visible="False">
|
|
<label class="col-md-2 control-label">Referencia:</label>
|
|
<div class="col-md-10">
|
|
<asp:TextBox ID="TxtReferenciaCIE" Text="" runat="server" CssClass="form-control input-sm" Width="400px" />
|
|
<%-- <asp:RequiredFieldValidator ID="RFVReferenciaCIE" runat="server" ControlToValidate="TxtReferenciaCIE" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Referencia''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
|
<ajax:ValidatorCalloutExtender ID="VCEReferenciaCIE" runat="server" HighlightCssClass="vco" TargetControlID="RFVReferenciaCIE" Width="300px"></ajax:ValidatorCalloutExtender>--%>
|
|
</div>
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-lg-4 col-md-2">
|
|
<div>
|
|
<asp:TextBox ID="Anexo" CssClass="ADSdropzone hidden" data-maxFile="1" Text="" runat="server"></asp:TextBox>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
|
|
<br />
|
|
<asp:UpdatePanel ID="UpGuardar" runat="server" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<table class="Widthall">
|
|
<tr>
|
|
<td style="text-align: right; width: 25%">
|
|
<asp:CheckBox Text=" Seguir Registrando Pagos" ID="ChkSeguirRegistrando" CssClass="md-checksd" runat="server" />
|
|
</td>
|
|
<td style="text-align: left; width: 9%">
|
|
<asp:CheckBox Text=" Emitir complemento de pago" ID="ChkComplementoPago" Visible="true" CssClass="md-checksd" runat="server" />
|
|
<br />
|
|
<asp:Label ID="LblValidaCeuntaTipoTransaccion" runat="server" Visible="false" ForeColor="Red"></asp:Label>
|
|
</td>
|
|
<td style="text-align: left; width: 30%">
|
|
<asp:Button ID="BtnIEGuardar" runat="server" Text="Guardar" ValidationGroup="GrpGuardar" class="btn btn-primary" />
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
<br />
|
|
|
|
<div class="row">
|
|
<div class="Widthall" style="text-align: right!important; margin-top: 20px!important; margin-bottom: 2px!important">
|
|
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvCxC.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
|
|
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvCxC.ClientID) %>" style="margin-top: -3px; margin-right: 20px" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
|
</div>
|
|
</div>
|
|
|
|
<asp:UpdatePanel ID="UPVentas" runat="server" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<asp:GridView ID="GvCxC" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontraron Cuentas por Cobrar Pendientes"
|
|
DataKeyNames="TipoDocto,CveVenta,CveCliente,SerieFolio,Original,SubTotal,IVA,IEPS,RetIVA,RetISR,Num3,CveSubProyecto,CveMoneda,Saldo,TipoCambio, RFC,UUID,Fecha,PorcentajeIVA,DescuentoProntoPago,CveTipoRetencion,Descuento,ClaveMetodoPagoSAT"
|
|
CssClass="table table-striped table-advance table-hover Widthall" Style="text-align: center;" GridLines="None">
|
|
<Columns>
|
|
<asp:TemplateField>
|
|
<HeaderTemplate>
|
|
<input type="checkbox" id="ChkAll" onclick="CheckAll();" />
|
|
</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:CheckBox ID="Chk" CssClass="chkgv" runat="server"></asp:CheckBox>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Left">
|
|
<HeaderTemplate>Venta</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:HyperLink ID="HplF" CssClass="Texto" NavigateUrl='<%# Eval("CveVenta", "/Ventas/Ventas.aspx?CveVenta={0}")%>' Text='<%# Eval("SerieFolio")%>' runat="server"></asp:HyperLink>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:BoundField HeaderText="Tipo Docto" DataField="TipoDocto" ItemStyle-HorizontalAlign="Center" />
|
|
<%--<asp:HyperLinkField DataNavigateUrlFields="CveCompra" DataNavigateUrlFormatString="/Compras/Compras.aspx?CveCompra={0}" DataTextField="SerieFolio" HeaderText="Factura" ControlStyle-CssClass="Texto" />--%>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate>Fecha Venta</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlFecha" runat="server" Text='<%# Eval("Fecha", "{0:d}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate>Fecha Vencimiento</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlFechaVenci" runat="server" Text='<%# Eval("FechaVencimiento", "{0:d}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate>Días Vencidos</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlDiasVencido" runat="server" Text='<%# Eval("DiasVencidos", "{0}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:BoundField HeaderText="Método de Pago" DataField="ClaveMetodoPagoSAT" ItemStyle-HorizontalAlign="Left" />
|
|
<asp:BoundField HeaderText="Forma de Pago" DataField="FormaPago" ItemStyle-HorizontalAlign="Left" />
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Right">
|
|
<HeaderTemplate>Monto Compra</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlSaldoOriginal" runat="server" Text='<%# Eval("Original", "{0:N2}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate></HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:HyperLink ID="LtlMoneda" runat="server" Text='<%# Eval("TMoneda", "{0}") %>' Style="text-decoration: none" Enabled="false" ForeColor="#333333"></asp:HyperLink>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField>
|
|
<HeaderTemplate>Abonado</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlAbonado" runat="server" Text='<%# Eval("Abonado", "{0:N2}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField>
|
|
<HeaderTemplate>Saldo</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlSaldo" runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate>Abonar</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:TextBox ID="TxtAbonar" Width="80px" runat="server" Style="text-align: right;" onkeyup="FormatoMoneda(this)"></asp:TextBox>
|
|
<asp:RangeValidator ID="RVAbonar" runat="server" Enabled="false" Type="Currency" MinimumValue="0" MaximumValue='<%# Eval("Saldo", "{0:N2}") %>' ErrorMessage="*" ControlToValidate="TxtAbonar" Display="Dynamic"></asp:RangeValidator>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField Visible="false">
|
|
<HeaderTemplate>Ot. Ing.</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:TextBox ID="TxtComision" Width="50px" runat="server" Style="text-align: right;"></asp:TextBox>
|
|
<asp:RangeValidator ID="RVComision" runat="server" Enabled="false" ErrorMessage="*" ControlToValidate="TxtComision" Display="Dynamic" Type="Double"></asp:RangeValidator>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField Visible="false" ItemStyle-HorizontalAlign="Center">
|
|
<HeaderTemplate>Descuento Pronto Pago</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlDescuentoProntoPago" runat="server" Text='<%# Eval("DescuentoProntoPago", "{0:N2}") %>'></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField HeaderText="Generar NC" Visible="false" >
|
|
<ItemTemplate>
|
|
<asp:CheckBox ID="ChkGenerarNC" CssClass="chkgv" runat="server" Visible="false" Enabled="false"></asp:CheckBox>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField ItemStyle-Width="300px">
|
|
<HeaderTemplate>Auxiliar</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal ID="LtlAux" runat="server"></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
<asp:TemplateField Visible="False">
|
|
<HeaderTemplate>CveVenta</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:HyperLink ID="HplF2" CssClass="btn-success" Text='<%# Eval("CveVenta")%>' runat="server"></asp:HyperLink>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
|
|
|
|
<asp:TemplateField >
|
|
<HeaderTemplate>Complemento Pago</HeaderTemplate>
|
|
<ItemTemplate>
|
|
<asp:Literal runat="server" ID="LtlComplemento" Text="<i class='fa fa-check text-success ' aria-hidden='true'></i>" ></asp:Literal>
|
|
</ItemTemplate>
|
|
</asp:TemplateField>
|
|
|
|
</Columns>
|
|
</asp:GridView>
|
|
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
|
|
|
|
<%-- MODAL SALDAR INCOBRABLE--%>
|
|
<div id="ModalSaldarCuentaIncobrable" 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">Saldar Cuentas</h4>
|
|
</div>
|
|
|
|
<div class="modal-body">
|
|
<asp:UpdatePanel runat="server" ID="UpBodyIncobrable" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<div class="alert alert-warning">Las facturas seleccionadas serán saldadas</div>
|
|
|
|
|
|
<div class="dashboard-stat2 " style="border-style: solid; border-color: whitesmoke;">
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<div class="progress-info">
|
|
<div class="status" style="font-size: 12px">
|
|
$:
|
|
<asp:Label Text="text" ID="LtlTotalMXN" runat="server" ClientIDMode="Static" />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-md-6">
|
|
<label class="col-md-2 control-label text-right">Fecha:</label>
|
|
<div class="col-md-3">
|
|
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
|
|
<asp:TextBox ID="TxtFechaIncobrable" runat="server" CssClass="form-control"></asp:TextBox>
|
|
<span class="input-group-btn ">
|
|
<asp:LinkButton runat="server" ID="ImgFechaIncobrable" class="btn default"><i class="fa fa-calendar"></i></asp:LinkButton>
|
|
</span>
|
|
</div>
|
|
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaIncobrable" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
|
<ajax:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="TxtFechaIncobrable" PopupButtonID="ImgFechaIncobrable" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
|
<asp:RequiredFieldValidator ID="RFVIncobrable" runat="server" ControlToValidate="TxtFechaIncobrable" Display="None" ErrorMessage="El campo <b>''Fecha''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpIncobrable"></asp:RequiredFieldValidator>
|
|
<asp:CompareValidator ID="CVIncobrable" runat="server" ControlToValidate="TxtFechaIncobrable" Display="None" ErrorMessage="El campo <b>''Fecha''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpIncobrable"></asp:CompareValidator>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender5" runat="server" HighlightCssClass="vco" TargetControlID="RFVIncobrable" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender6" runat="server" HighlightCssClass="vco" TargetControlID="CVIncobrable" Width="350px"></ajax:ValidatorCalloutExtender>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
<div class="row">
|
|
|
|
<label class="col-md-2 control-label text-right">Observación:</label>
|
|
|
|
<asp:TextBox ID="TxtObsSaldarIncobrable" Text="Saldar Cuenta" runat="server" TextMode="MultiLine" Rows="2" Width="300px"></asp:TextBox>
|
|
</div>
|
|
<div class="row">
|
|
|
|
<label class="col-md-2 control-label text-right">Cta Deducción:</label>
|
|
|
|
<asp:DropDownList ID="DdlTipoDeduccion" runat="server" Width="300px">
|
|
<asp:ListItem Text="Gasto No Deducible" Value="255" Selected="True"></asp:ListItem>
|
|
<asp:ListItem Text="Incobrable No Deducible" Value="211"></asp:ListItem>
|
|
<asp:ListItem Text="Incobrable Deducible" Value="263"></asp:ListItem>
|
|
<asp:ListItem Text="Reservas" Value="252"></asp:ListItem>
|
|
<asp:ListItem Text="Otros Ingresos" Value="78"></asp:ListItem>
|
|
</asp:DropDownList>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<asp:UpdatePanel runat="server">
|
|
<ContentTemplate>
|
|
<asp:Button ID="BtnSaldarCuentasIncobrables" runat="server" CssClass="btn btn-primary" Text="Saldar cuentas" ValidationGroup="GrpIncobrable" />
|
|
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<%-- FIN MODAL SALDAR INCOBRABLE--%>
|
|
|
|
<div id="ModalVincularIntermediario" 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="modalChkProveedorIntermediario">×</button>
|
|
<h4 class="modal-title">Vincular Intermediario</h4>
|
|
</div>
|
|
|
|
<div class="modal-body">
|
|
<asp:UpdatePanel runat="server" ID="UpdatePanel1" UpdateMode="Conditional">
|
|
<ContentTemplate>
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<asp:CheckBox ID="ChkProveedorIntermediario" runat="server" />
|
|
Intermediario:
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-md-12">
|
|
<ADS:Dropdownlost ID="DdlProveedorIntermediario" CssClassDdl="select2me" CssStyle="100%" DataTextField="RazonSocial" DataValueField="CveProveedor" runat="server"></ADS:Dropdownlost>
|
|
</div>
|
|
</div>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
<div class="modal-footer">
|
|
<asp:UpdatePanel runat="server">
|
|
<ContentTemplate>
|
|
<asp:Button ID="BtnVincularIntermediario" runat="server" CssClass="btn btn-primary" Text="Vincular Intermediario" />
|
|
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
|
</ContentTemplate>
|
|
</asp:UpdatePanel>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<script src="/Metronic/assets/global/plugins/dropzone/dropzone.js"></script>
|
|
</asp:Content>
|
|
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
|
|
<script type="text/javascript">
|
|
var Ventas = '';
|
|
|
|
function FnSuma(t, txt, importe) {
|
|
|
|
var chkPesosBancos = $get("ChkPagarPesos");
|
|
var chkDolaresBancos = $get("ChkPagarDolares");
|
|
|
|
|
|
if (t.checked) {
|
|
txt.value = FormatoNumero(importe, 2);
|
|
} else {
|
|
txt.value = "";
|
|
}
|
|
//if (typeof t2 === "undefined") {
|
|
|
|
//} else {
|
|
|
|
//}
|
|
|
|
|
|
if (chkPesosBancos) {
|
|
CambiaPesosDolares()
|
|
} else if (chkDolaresBancos) {
|
|
CambiaDolaresPesos()
|
|
}
|
|
}
|
|
|
|
function SumaValores(pagoMultiple, monedaPago) {
|
|
|
|
var Importe = 0;
|
|
var Comision = 0.00;
|
|
var topLevelElem = document.getElementById("form1");
|
|
var textBoxes = topLevelElem.getElementsByTagName("input");
|
|
var idd = '';
|
|
Ventas = '';
|
|
var abono = 0;
|
|
var abonoComision = 0;
|
|
var moneda = '';
|
|
var tc = 0;
|
|
var facDolares = false;
|
|
var div = document.getElementById("DivTC")
|
|
|
|
if ($get('TxtTC') != null) {
|
|
tc = ToDouble($get('TxtTC').value);
|
|
}
|
|
if ($get('TxtTCDolares') != null) {
|
|
tc = ToDouble($get('TxtTCDolares').value);
|
|
}
|
|
|
|
for (var i = 0; i < textBoxes.length; i++) {
|
|
if (textBoxes[i].type == "text") {
|
|
if (textBoxes[i].id.indexOf('C_GvCxC_TxtAbonar') >= 0) {
|
|
if (textBoxes[i].value != '') {
|
|
idd = textBoxes[i].id.replace('C_GvCxC_TxtAbonar_', '');
|
|
Ventas = Ventas + (Importe == 0 ? '' : ', ') + $get("C_GvCxC_HplF_" + idd).innerText;
|
|
abono = parseFloat(textBoxes[i].value.split(',').join(''));
|
|
moneda = $get("C_GvCxC_LtlMoneda_" + idd).innerText;
|
|
|
|
if (monedaPago == 1 && moneda == 'USD') {
|
|
facDolares = true;
|
|
abono = abono * tc;
|
|
}
|
|
if (monedaPago == 2 && moneda == 'MXN' && tc != 0) {
|
|
abono = abono / tc;
|
|
}
|
|
Importe = Importe + abono
|
|
}
|
|
}
|
|
if (textBoxes[i].id.indexOf('C_GvCxC_TxtComision') >= 0) {
|
|
if (textBoxes[i].value != '') {
|
|
abonoComision = parseFloat(textBoxes[i].value.split(',').join(''));
|
|
moneda = $get("C_GvCxC_LtlMoneda_" + idd).innerText;
|
|
if (monedaPago == 1 && moneda == 'USD') {
|
|
facDolares = true
|
|
abonoComision = abonoComision * tc;
|
|
}
|
|
if (monedaPago == 2 && moneda == 'MXN' && tc != 0) {
|
|
abonoComision = abonoComision / tc;
|
|
}
|
|
Comision = parseFloat(Comision) + abonoComision;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (pagoMultiple == -1 && tc == 0 && facDolares) {
|
|
Importe = 0
|
|
Comision = 0
|
|
}
|
|
if (facDolares && pagoMultiple == -1) {
|
|
div.style.display = 'block';
|
|
}
|
|
if (!facDolares && div != null && pagoMultiple == -1) {
|
|
div.style.display = 'none';
|
|
}
|
|
$get('TxtObservaciones').value = $get('HdnObs').value + ' Ventas: ' + Ventas;
|
|
|
|
if ($get('TxtOtrosImportes') != null) {
|
|
if (pagoMultiple != 0) {
|
|
$get('TxtOtrosImportes').value = FormatoNumero(Comision, 2);
|
|
}
|
|
|
|
if ($get('TxtOtrosImportes').value == '') {
|
|
$get('TxtOtrosImportes').value = 0.00
|
|
|
|
}
|
|
else {
|
|
return Importe + parseFloat(Comision);
|
|
}
|
|
|
|
}
|
|
else {
|
|
return Importe
|
|
}
|
|
}
|
|
|
|
function FnCambia(chk, txt, saldo, op, pagoMultiple, monedaPago) {
|
|
if (op == 1) {
|
|
if (txt.value != '') {
|
|
chk.checked = true;
|
|
} else {
|
|
chk.checked = false;
|
|
}
|
|
}
|
|
if (op == 1 || op == 2) {
|
|
if (ToDouble(txt.value) > saldo) {
|
|
txt.value = saldo;
|
|
alert("El Importe no debe de exceder a el saldo");
|
|
}
|
|
}
|
|
var Suma = SumaValores(pagoMultiple, monedaPago);
|
|
$get('TxtImporte').value = FormatoNumero(Suma, 2);
|
|
$('#LtlTotalMXN').text(FormatoNumero(Suma, 2))
|
|
|
|
if ($get('TxtTotal') != null) {
|
|
$get('TxtTotal').value = FormatoNumero(Suma + (ToDouble($get('TxtOtrosImportes').value * -1)), 2);
|
|
}
|
|
|
|
pagoMultiple = 0;
|
|
if (monedaPago == 1) monedaPago = 2; else monedaPago = 1;
|
|
|
|
var SumaConversion = SumaValores(pagoMultiple, monedaPago)
|
|
if (Suma == 0) SumaConversion = 0;
|
|
|
|
if ($("#LbImporteME").length) {
|
|
$get('LbImporteME').innerHTML = '$ ' + FormatoNumero(SumaConversion, 2) + ' USD';
|
|
}
|
|
if ($("#LbImporteMN").length) {
|
|
$get('LbImporteMN').innerHTML = '$ ' + FormatoNumero(SumaConversion, 2) + ' MXN';
|
|
}
|
|
}
|
|
|
|
function FnSeleccionaNC(chk, chkNC,txtImporte)
|
|
{
|
|
if (chk.checked) {
|
|
chkNC.disabled = false;
|
|
chkNC.click();
|
|
} else {
|
|
chkNC.disabled = true;
|
|
if (chkNC.checked) {
|
|
chkNC.click();
|
|
}
|
|
}
|
|
txtImporte.disabled = chkNC.checked;
|
|
}
|
|
|
|
function FnEditarImporte(chkNC, txtImporte) {
|
|
txtImporte.disabled = chkNC.checked;
|
|
}
|
|
|
|
function FnLimites(chk, txt, limiteInferior, limiteSuperior) {
|
|
if (ToDouble(txt.value) < limiteInferior) {
|
|
txt.value = limiteInferior;
|
|
alert("El Importe no debe de exceder a el saldo");
|
|
} else if (ToDouble(txt.value) > limiteSuperior) {
|
|
txt.value = limiteSuperior;
|
|
alert("El Importe no debe de exceder a el saldo");
|
|
}
|
|
|
|
var Suma = SumaValores();
|
|
$get('TxtImporte').value = FormatoNumero(Suma, 2);
|
|
|
|
if ($get('TxtTotal') != null) {
|
|
$get('TxtTotal').value = FormatoNumero(Suma + (ToDouble($get('TxtOtrosImportes').value * -1)), 2);
|
|
}
|
|
|
|
CambiaPesosDolares()
|
|
CambiaDolaresPesos()
|
|
|
|
}
|
|
|
|
function CambiaPesosDolares() {
|
|
$get('TxtImporte').value = FormatoNumero(SumaValores(), 2);
|
|
$('#LtlTotalMXN').text(FormatoNumero(SumaValores(), 2))
|
|
if ($("#LbImporteME").length) {
|
|
$get('LbImporteME').innerHTML = '$ ' + FormatoNumero(SumaValores(), 2) + ' USD';
|
|
$get('TxtImporte').value = FormatoNumero(ToDouble($get('TxtImporte').value) * ToDouble($get('TxtTC').value), 2);
|
|
$get('LtlTotalMXN').value = FormatoNumero(ToDouble($get('TxtImporte').value) * ToDouble($get('TxtTC').value), 2);
|
|
}
|
|
|
|
if ($get('TxtTotal') != null) {
|
|
$get('TxtTotal').value = FormatoNumero(ToDouble($get('TxtImporte').value) + (ToDouble($get('TxtOtrosImportes').value * -1)), 2);
|
|
}
|
|
}
|
|
|
|
function CambiaDolaresPesos() {
|
|
|
|
$get('TxtImporte').value = FormatoNumero(SumaValores(), 2);
|
|
$('#LtlTotalMXN').text(FormatoNumero(SumaValores(), 2))
|
|
|
|
|
|
|
|
if ($("#LbImporteMN").length) {
|
|
$get('LbImporteMN').innerHTML = '$ ' + FormatoNumero(SumaValores(), 2) + ' MXN';
|
|
$get('TxtImporte').value = FormatoNumero(ToDouble($get('TxtImporte').value) / ToDouble($get('TxtTCDolares').value), 2);
|
|
$get('LtlTotalMXN').value = FormatoNumero(ToDouble($get('TxtImporte').value) / ToDouble($get('TxtTCDolares').value), 2);
|
|
|
|
}
|
|
|
|
if ($get('TxtTotal') != null) {
|
|
$get('TxtTotal').value = FormatoNumero(ToDouble($get('TxtImporte').value) + (ToDouble($get('TxtOtrosImportes').value * -1)), 2);
|
|
}
|
|
|
|
}
|
|
|
|
function waitforpastedata(elem, savedcontent) {
|
|
if (elem.childNodes && elem.childNodes.length > 0) {
|
|
processpaste(elem, savedcontent);
|
|
}
|
|
else {
|
|
that = {
|
|
e: elem,
|
|
s: savedcontent
|
|
}
|
|
that.callself = function () {
|
|
waitforpastedata(that.e, that.s)
|
|
}
|
|
setTimeout(that.callself, 20);
|
|
}
|
|
}
|
|
|
|
function processpaste(elem, savedcontent) {
|
|
pasteddata = elem.innerHTML;
|
|
//^^Alternatively loop through dom (elem.childNodes or elem.getElementsByTagName) here
|
|
|
|
elem.innerHTML = savedcontent;
|
|
|
|
// Do whatever with gathered data;
|
|
alert(pasteddata);
|
|
}
|
|
|
|
function CheckAll() {
|
|
var topLevelElem = document.getElementById("C_UPVentas");
|
|
var textBoxes = topLevelElem.getElementsByTagName("input");
|
|
var check = false;
|
|
|
|
for (var i = 0; i < textBoxes.length; i++) {
|
|
if (textBoxes[i].type == "checkbox") {
|
|
|
|
|
|
if (textBoxes[i].id == "ChkAll") {
|
|
check = !textBoxes[i].checked;
|
|
continue;
|
|
}
|
|
|
|
|
|
if (textBoxes[i].checked && check) {
|
|
textBoxes[i].click();
|
|
} else if (!textBoxes[i].checked && !check) {
|
|
textBoxes[i].click();
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
var TipoCambioActual = 0.0;
|
|
function CambiaTC(txt) {
|
|
let TipoCambioTxt = ToDouble(txt.value)
|
|
if (TipoCambioActual != TipoCambioTxt) {
|
|
$get("BtnCambiaTipoMoneda").click();
|
|
TipoCambioActual = TipoCambioTxt;
|
|
}
|
|
}
|
|
</script>
|
|
</asp:Content>
|