fix event handler

This commit is contained in:
Matias Alejo Garcia 2015-11-12 17:19:18 -03:00
parent aeb7766b93
commit 50dc93926b
1 changed files with 6 additions and 3 deletions

View File

@ -1248,7 +1248,7 @@ angular.module('copayApp.controllers').controller('indexController', function($r
}); });
lodash.each(['NewTxProposal', 'TxProposalFinallyRejected', 'TxProposalRemoved', 'NewOutgoingTxByThirdParty', lodash.each(['NewTxProposal', 'TxProposalFinallyRejected', 'TxProposalRemoved', 'NewOutgoingTxByThirdParty',
'Local/NewTxProposal', 'Local/TxProposalAction', 'ScanFinished', 'Local/GlideraTx' 'Local/NewTxProposal', 'Local/TxProposalAction', 'Local/GlideraTx'
], function(eventName) { ], function(eventName) {
$rootScope.$on(eventName, function(event, untilItChanges) { $rootScope.$on(eventName, function(event, untilItChanges) {
self.updateAll({ self.updateAll({
@ -1260,9 +1260,12 @@ angular.module('copayApp.controllers').controller('indexController', function($r
}); });
$rootScope.$on('ScanFinished', function() { $rootScope.$on('ScanFinished', function() {
console.log('Scan Finished. Updating history'); $log.debug('Scan Finished. Updating history');
storageService.removeTxHistory(self.walletId, function() { storageService.removeTxHistory(self.walletId, function() {
self.updateHistory(); self.updateAll({
walletStatus: null,
triggerTxUpdate: true,
});
}); });
}); });