Merge pull request #2960 from matiu/bug/refreshtx
fix tx history refresh
This commit is contained in:
commit
d448cf4086
1 changed files with 15 additions and 9 deletions
|
|
@ -279,6 +279,12 @@ angular.module('copayApp.controllers').controller('indexController', function($r
|
||||||
return w.id != self.walletId;
|
return w.id != self.walletId;
|
||||||
});;
|
});;
|
||||||
$rootScope.$apply();
|
$rootScope.$apply();
|
||||||
|
|
||||||
|
if (opts.triggerTxUpdate) {
|
||||||
|
$timeout(function() {
|
||||||
|
self.updateTxHistory();
|
||||||
|
}, 1);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
@ -862,16 +868,18 @@ angular.module('copayApp.controllers').controller('indexController', function($r
|
||||||
});
|
});
|
||||||
|
|
||||||
$rootScope.$on('NewIncomingTx', function() {
|
$rootScope.$on('NewIncomingTx', function() {
|
||||||
self.updateBalance();
|
self.updateAll({
|
||||||
$timeout(function() {
|
walletStatus: null,
|
||||||
self.updateTxHistory();
|
untilItChanges: true,
|
||||||
}, 5000);
|
triggerTxUpdate: true,
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
$rootScope.$on('NewOutgoingTx', function() {
|
$rootScope.$on('NewOutgoingTx', function() {
|
||||||
self.updateAll({
|
self.updateAll({
|
||||||
walletStatus: null,
|
walletStatus: null,
|
||||||
untilItChanges: true
|
untilItChanges: true,
|
||||||
|
triggerTxUpdate: true,
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -881,11 +889,9 @@ angular.module('copayApp.controllers').controller('indexController', function($r
|
||||||
$rootScope.$on(eventName, function(event, untilItChanges) {
|
$rootScope.$on(eventName, function(event, untilItChanges) {
|
||||||
self.updateAll({
|
self.updateAll({
|
||||||
walletStatus: null,
|
walletStatus: null,
|
||||||
untilItChanges: untilItChanges
|
untilItChanges: untilItChanges,
|
||||||
|
triggerTxUpdate: true,
|
||||||
});
|
});
|
||||||
$timeout(function() {
|
|
||||||
self.updateTxHistory();
|
|
||||||
}, 3000);
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue