Fix for chromeapp and mobile with a simple timeout
This commit is contained in:
parent
6dd8b98dfc
commit
5c42f54e96
1 changed files with 22 additions and 16 deletions
|
|
@ -180,26 +180,32 @@ angular.module('copayApp.controllers').controller('walletHomeController', functi
|
||||||
|
|
||||||
$scope.add = function(addressbook) {
|
$scope.add = function(addressbook) {
|
||||||
$scope.error = null;
|
$scope.error = null;
|
||||||
addressbookService.add(addressbook, function(err, ab) {
|
$timeout(function() {
|
||||||
if (err) {
|
addressbookService.add(addressbook, function(err, ab) {
|
||||||
$scope.error = err;
|
if (err) {
|
||||||
return;
|
$scope.error = err;
|
||||||
}
|
return;
|
||||||
$scope.list = ab;
|
}
|
||||||
$scope.editAddressbook = true;
|
$scope.list = ab;
|
||||||
$scope.toggleEditAddressbook();
|
$scope.editAddressbook = true;
|
||||||
});
|
$scope.toggleEditAddressbook();
|
||||||
|
$scope.$digest();
|
||||||
|
});
|
||||||
|
}, 100);
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.remove = function(addr) {
|
$scope.remove = function(addr) {
|
||||||
$scope.error = null;
|
$scope.error = null;
|
||||||
addressbookService.remove(addr, function(err, ab) {
|
$timeout(function() {
|
||||||
if (err) {
|
addressbookService.remove(addr, function(err, ab) {
|
||||||
$scope.error = err;
|
if (err) {
|
||||||
return;
|
$scope.error = err;
|
||||||
}
|
return;
|
||||||
$scope.list = ab;
|
}
|
||||||
});
|
$scope.list = ab;
|
||||||
|
$scope.$digest();
|
||||||
|
});
|
||||||
|
}, 100);
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.cancel = function() {
|
$scope.cancel = function() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue