better fee service

This commit is contained in:
Matias Alejo Garcia 2017-06-21 17:09:33 -03:00
commit 5745340400
No known key found for this signature in database
GPG key ID: 02470DB551277AB3
6 changed files with 76 additions and 81 deletions

View file

@ -7,7 +7,7 @@
</ion-nav-back-button>
</ion-nav-bar>
<ion-content ng-class="{'add-bottom-for-cta': !insufficientFunds && !noMatchingWallet}">
<ion-content ng-class="{'add-bottom-for-cta': !wallet}">
<div class="list">
<div class="item head">
<div class="sending-label">
@ -61,7 +61,7 @@
<span ng-if="tx.toName && showAddress">{{tx.toAddress}}</span>
</div>
</div>
<a class="item item-icon-right" ng-hide="!tx.sendMax && (insufficientFunds || noMatchingWallet)" ng-click="showWalletSelector()">
<a class="item item-icon-right" ng-hide="!tx.sendMax ||!wallet" ng-click="showWalletSelector()">
<span class="label" translate>From</span>
<div class="wallet" ng-if="wallet">
<i class="icon big-icon-svg">
@ -77,26 +77,23 @@
</div>
<i class="icon bp-arrow-right"></i>
</a>
<div class="item item-icon-right" ng-if="!insufficientFunds && !noMatchingWallet" ng-click="chooseFeeLevel(tx, wallet)">
<div class="item item-icon-right" ng-if="wallet" ng-click="chooseFeeLevel(tx, wallet)">
<span class="label">{{'Fee:' | translate}} {{tx.feeLevelName | translate}}</span>
<span class="m10l">{{tx.txp[wallet.id].feeStr || '...'}}</span>
<span class="item-note m10l">
<span>{{tx.txp[wallet.id].alternativeFeeStr || '...'}}&nbsp;<span class="fee-rate" ng-if="tx.feeRatePerStr" translate>- {{tx.txp[wallet.id].feeRatePerStr}} of the transaction</span></span>
<span>{{tx.txp[wallet.id].alternativeFeeStr || '...'}}&nbsp;<span class="fee-rate" ng-if="tx.txp[wallet.id].feeRatePerStr" translate>- {{tx.txp[wallet.id].feeRatePerStr}} of the transaction</span></span>
</span>
<i class="icon bp-arrow-right"></i>
</div>
<a class="item item-icon-right" ng-if="!insufficientFunds && !noMatchingWallet" ng-click="showDescriptionPopup(tx)">
<a class="item item-icon-right" ng-if="wallet" ng-click="showDescriptionPopup(tx)">
<span class="label" translate>Add Memo</span>
<span class="item-note m10l">
{{tx.description}}
</span>
<i class="icon bp-arrow-right"></i>
</a>
<div class="text-center" ng-show="noMatchingWallet">
<span class="badge badge-energized" translate>No wallets available</span>
</div>
<div class="text-center" ng-show="insufficientFunds">
<span class="badge badge-energized" translate>Insufficient funds</span>
<div class="text-center" ng-show="!wallet">
<span class="badge badge-energized">{{noWalletMessage}}</span>
</div>
</div>
</div>
@ -105,18 +102,14 @@
ng-click="approve(tx, wallet, statusChangeHandler)"
ng-if="!isCordova"
click-send-status="sendStatus"
has-wallet-chosen="wallet"
insufficient-funds="insufficientFunds"
no-matching-wallet="noMatchingWallet">
is-disabled="!wallet">
{{buttonText}}
</click-to-accept>
<slide-to-accept
ng-if="isCordova && (wallet && !insufficientFunds && !noMatchingWallet)"
ng-if="isCordova && wallet"
slide-on-confirm="onConfirm()"
slide-send-status="sendStatus"
has-wallet-chosen="wallet"
insufficient-funds="insufficientFunds"
no-matching-wallet="noMatchingWallet">
is-disabled="!wallet">
{{buttonText}}
</slide-to-accept>
<slide-to-accept-success