do not low fee for certain fees

This commit is contained in:
Matias Alejo Garcia 2017-04-21 08:48:25 -03:00
commit 20fdeb9633
No known key found for this signature in database
GPG key ID: 02470DB551277AB3
4 changed files with 29 additions and 4 deletions

View file

@ -0,0 +1,25 @@
'use strict';
angular.module('copayApp.directives')
/**
* Replaces img tag with its svg content to allow for CSS styling of the svg.
*/
.directive('noLowFee', function($log, $ionicHistory, configService, popupService) {
return {
restrict: 'A',
link: function(scope, elem, attrs, ctrl) {
elem.bind('click', function() {
configService.whenAvailable(function(config) {
if (config.wallet.settings.feeLevel.match(/conomy/)) {
$log.debug('Economy Fee setting... disabling link:' + elem.text());
popupService.showAlert('Low Fee Error', 'Please change your Bitcoin Network Fee Policy setting to Normal or higher to use this service', function() {
$ionicHistory.goBack();
});
}
});
});
}
}
});