-- unificar a un solo campo de Tipo de cambio
This commit is contained in:
@@ -70,16 +70,10 @@
|
||||
<asp:TextBox ID="TxtTC" runat="server" Text="1" placeholder="Tipo de Cambio" CssClass="form-control input-sm" MaxLength="12" onblur="CambiaPesosDolares();" 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="VCETC" runat="server" HighlightCssClass="vco" TargetControlID="RFVTC" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<asp:Label ID="LbImporteME" Text="" ClientIDMode="Static" runat="server" />
|
||||
</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" onkeyup="CambiaDolaresPesos();" 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" />
|
||||
<asp:Label ID="LbImporteME" Text="" ClientIDMode="Static" runat="server" />
|
||||
<asp:Label ID="LbImporteMN" Text="" ClientIDMode="Static" runat="server" />
|
||||
</div>
|
||||
<asp:Button ID="BtnCambiaTipoMoneda" Text="" OnClick="BtnCambiaTipoMoneda_Click" ClientIDMode="Static" Style="display: none;" runat="server" />
|
||||
</div>
|
||||
<div class="row" runat="server" id="DivTarjeta" visible="false">
|
||||
<label class="col-xs-2 control-label">Tarjeta:</label>
|
||||
@@ -701,9 +695,8 @@
|
||||
debugger;
|
||||
if ($("#LbImporteMN").length) {
|
||||
$get('LbImporteMN').innerHTML = '$ ' + FormatoNumero(SumaValores(), 2) + ' MXN';
|
||||
$get('TxtImporte').value = FormatoNumero(ToDouble($get('TxtImporte').value.replace(',', '')) / ToDouble($get('TxtTCDolares').value), 2);
|
||||
$get('LtlTotalMXN').value = FormatoNumero(ToDouble($get('TxtImporte').value) / ToDouble($get('TxtTCDolares').value), 2);
|
||||
|
||||
$get('TxtImporte').value = FormatoNumero(ToDouble($get('TxtImporte').value.replace(',', '')) / ToDouble($get('TxtTC').value), 2);
|
||||
$get('LtlTotalMXN').value = FormatoNumero(ToDouble($get('TxtImporte').value) / ToDouble($get('TxtTC').value), 2);
|
||||
}
|
||||
|
||||
if ($get('TxtTotal') != null) {
|
||||
@@ -718,11 +711,12 @@
|
||||
|
||||
var TipoCambioActual = 0.0;
|
||||
function CambiaTC(txt) {
|
||||
let TipoCambioTxt = ToDouble(txt.value)
|
||||
if (TipoCambioActual != TipoCambioTxt) {
|
||||
debugger;
|
||||
//let TipoCambioTxt = ToDouble(txt.value)
|
||||
//if (TipoCambioActual != TipoCambioTxt) {
|
||||
$get("BtnCambiaTipoMoneda").click();
|
||||
TipoCambioActual = TipoCambioTxt;
|
||||
}
|
||||
// TipoCambioActual = TipoCambioTxt;
|
||||
//}
|
||||
}
|
||||
|
||||
function calculaDescuentoEscalonado(saldo, TxtDescuento, TxtAbonar, chk,Text,Tipo) {
|
||||
|
||||
Reference in New Issue
Block a user