Fix loading
This commit is contained in:
parent
5666a66e1d
commit
b5f3648aee
3 changed files with 9 additions and 5 deletions
|
|
@ -12,7 +12,9 @@ angular.module('copayApp.controllers').controller('coinbaseController', function
|
||||||
$scope.accessToken = at;
|
$scope.accessToken = at;
|
||||||
|
|
||||||
// Update Access Token if necessary
|
// Update Access Token if necessary
|
||||||
|
$scope.loading = true;
|
||||||
coinbaseService.init(function(err, data) {
|
coinbaseService.init(function(err, data) {
|
||||||
|
$scope.loading = false;
|
||||||
if (err || lodash.isEmpty(data)) {
|
if (err || lodash.isEmpty(data)) {
|
||||||
if (err) {
|
if (err) {
|
||||||
popupService.showAlert(gettextCatalog.getString('Error'), err);
|
popupService.showAlert(gettextCatalog.getString('Error'), err);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.controllers').controller('tabSettingsController', function($scope, appConfigService, $window, $log, lodash, uxLanguage, platformInfo, profileService, feeService, configService, externalLinkService, bitpayCardService, storageService, glideraService, coinbaseService, gettextCatalog) {
|
angular.module('copayApp.controllers').controller('tabSettingsController', function($scope, appConfigService, $log, lodash, uxLanguage, platformInfo, profileService, feeService, configService, externalLinkService, bitpayCardService, storageService, glideraService, coinbaseService, gettextCatalog) {
|
||||||
|
|
||||||
var updateConfig = function() {
|
var updateConfig = function() {
|
||||||
var isCordova = platformInfo.isCordova;
|
var isCordova = platformInfo.isCordova;
|
||||||
|
|
@ -44,9 +44,8 @@ angular.module('copayApp.controllers').controller('tabSettingsController', funct
|
||||||
|
|
||||||
if ($scope.coinbaseEnabled) {
|
if ($scope.coinbaseEnabled) {
|
||||||
coinbaseService.setCredentials();
|
coinbaseService.setCredentials();
|
||||||
storageService.getCoinbaseToken(coinbaseService.getNetwork(), function(err, token) {
|
coinbaseService.getStoredToken(function(at) {
|
||||||
if (err) $log.error(err);
|
$scope.coinbaseToken = at;
|
||||||
$scope.coinbaseToken = token;
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -121,6 +121,9 @@
|
||||||
</p>
|
</p>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="m10t text-center" ng-if="loading">
|
||||||
|
<ion-spinner class="spinner-dark" icon="lines"></ion-spinner>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</ion-content>
|
</ion-content>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue