new onGoingProcess

This commit is contained in:
Matias Alejo Garcia 2016-06-13 15:25:40 -03:00
commit 90dad5b2a8
No known key found for this signature in database
GPG key ID: 02470DB551277AB3
33 changed files with 200 additions and 267 deletions

View file

@ -1,7 +1,7 @@
'use strict';
angular.module('copayApp.controllers').controller('glideraController',
function($rootScope, $scope, $timeout, $modal, $ionicModal, profileService, configService, storageService, glideraService, lodash) {
function($rootScope, $scope, $timeout, $modal, $ionicModal, profileService, configService, storageService, glideraService, lodash, ongoingProcess) {
this.getAuthenticateUrl = function() {
return glideraService.getOauthCodeUrl();
@ -11,11 +11,11 @@ angular.module('copayApp.controllers').controller('glideraController',
var self = this;
var glideraTestnet = configService.getSync().glidera.testnet;
var network = glideraTestnet ? 'testnet' : 'livenet';
this.loading = true;
ongoingProcess.set('connectingGlidera', true);
this.error = null;
$timeout(function() {
glideraService.getToken(code, function(err, data) {
self.loading = null;
ongoingProcess.set('connectingGlidera', false);
if (err) {
self.error = err;
$timeout(function() {