Fixes names

This commit is contained in:
Gustavo Maximiliano Cortez 2015-07-24 12:23:30 -03:00
commit 2cc9554df4
4 changed files with 13 additions and 30 deletions

View file

@ -977,7 +977,7 @@ angular.module('copayApp.controllers').controller('walletHomeController', functi
}
};
this.openFeeModal = function(feeLevels, currentFeeLevel) {
this.openFeeLevelsModal = function(feeLevels, currentFeeLevel) {
var fc = profileService.focusedClient;
var ModalInstanceCtrl = function($scope, $modalInstance) {

View file

@ -3,23 +3,6 @@
angular.module('copayApp.services').factory('feeService', function($log, lodash, profileService, configService, gettext) {
var root = {};
root.feeStaticOpts = [{
name: gettext('Priority'),
level: 'priority',
feePerKB: 10000,
nbBlocks: 1
}, {
name: gettext('Normal'),
level: 'normal',
feePerKB: 5000,
nbBlocks: 4
}, {
name: gettext('Economy'),
level: 'economy',
feePerKB: 1000,
nbBlocks: 12
}];
root.getCurrentFeeValue = function(cb) {
var fc = profileService.focusedClient;
var config = configService.getSync().wallet.settings;
@ -69,17 +52,17 @@ angular.module('copayApp.services').factory('feeService', function($log, lodash,
fc.getFeeLevels('livenet', function(errLivenet, levelsLivenet) {
fc.getFeeLevels('testnet', function(errTestnet, levelsTestnet) {
if (errLivenet || errTestnet) $log.error('Error getting dynamic fee');
if (errLivenet || errTestnet) $log.error('Error getting dynamic fee');
for (var i = 0; i < 3; i++) {
levelsLivenet[i]['feePerKBUnit'] = profileService.formatAmount(levelsLivenet[i].feePerKB) + ' ' + unitName;
levelsTestnet[i]['feePerKBUnit'] = profileService.formatAmount(levelsTestnet[i].feePerKB) + ' ' + unitName;
}
for (var i = 0; i < 3; i++) {
levelsLivenet[i]['feePerKBUnit'] = profileService.formatAmount(levelsLivenet[i].feePerKB) + ' ' + unitName;
levelsTestnet[i]['feePerKBUnit'] = profileService.formatAmount(levelsTestnet[i].feePerKB) + ' ' + unitName;
}
return cb({
'livenet': levelsLivenet,
'testnet': levelsTestnet
});
return cb({
'livenet': levelsLivenet,
'testnet': levelsTestnet
});
});
});
};