From d5a9a916dbbffa0fd2cf2e4166e53b55439cf60c Mon Sep 17 00:00:00 2001 From: Gustavo Maximiliano Cortez Date: Thu, 29 Jan 2015 03:14:32 -0300 Subject: [PATCH] askForPin scope --- js/controllers/createProfile.js | 8 ++++---- js/controllers/home.js | 6 +++--- js/services/pinService.js | 6 +++--- views/createProfile.html | 8 ++++---- views/home.html | 10 +++++----- 5 files changed, 19 insertions(+), 19 deletions(-) diff --git a/js/controllers/createProfile.js b/js/controllers/createProfile.js index 2f6e66da3..1c54a2d08 100644 --- a/js/controllers/createProfile.js +++ b/js/controllers/createProfile.js @@ -14,7 +14,7 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun $scope.hideForWP = 0; $scope.digits = []; $scope.defined = []; - $rootScope.askForPin = 0; + $scope.askForPin = 0; $scope.createStep = 'storage'; $scope.useLocalstorage = false; @@ -53,7 +53,7 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun pinService.save(pin, _credentials.email, _credentials.password, function(err) { _credentials.password = ''; _credentials = null; - $rootScope.askForPin = 0; + $scope.askForPin = 0; $rootScope.hasPin = true; $scope.createDefaultWallet(); }); @@ -100,7 +100,7 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun $rootScope.hideNavigation = false; $rootScope.starting = true; identityService.createDefaultWallet(function(err) { - $rootScope.askForPin = 0; + $scope.askForPin = 0; $rootScope.starting = null; if (err) { @@ -140,7 +140,7 @@ angular.module('copayApp.controllers').controller('CreateProfileController', fun email: emailOrUsername, password: password, }; - $rootScope.askForPin = 1; + $scope.askForPin = 1; $scope.hideForWP = 0; $rootScope.hideNavigation = true; diff --git a/js/controllers/home.js b/js/controllers/home.js index 563a040af..35fe74d76 100644 --- a/js/controllers/home.js +++ b/js/controllers/home.js @@ -13,7 +13,7 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc $scope.attempt = 0; $scope.digits = []; $scope.defined = []; - $rootScope.askForPin = 0; + $scope.askForPin = 0; // This is only for backwards compat, insight api should link to #!/confirmed directly if (getParam('confirmed')) { @@ -113,7 +113,7 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc pinService.save(pin, _credentials.email, _credentials.password, function(err) { _credentials.password = ''; _credentials = null; - $rootScope.askForPin = 0; + $scope.askForPin = 0; $rootScope.hasPin = true; $rootScope.starting = null; $scope.openWallets(); @@ -183,7 +183,7 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc email: email, password: password, }; - $rootScope.askForPin = 1; + $scope.askForPin = 1; $rootScope.starting = false; $rootScope.hideNavigation = true; $timeout(function() { diff --git a/js/services/pinService.js b/js/services/pinService.js index 11f66469d..3ffed58dd 100644 --- a/js/services/pinService.js +++ b/js/services/pinService.js @@ -64,7 +64,7 @@ angular.module('copayApp.services') if (!$rootScope.hasPin) { if (!_firstpin) { _firstpin = pin; - $rootScope.askForPin = 2; + scope.askForPin = 2; $timeout(function() { scope.clear(); }, 100); @@ -73,12 +73,12 @@ angular.module('copayApp.services') else { if (pin === _firstpin) { _firstpin = null; - $rootScope.askForPin = null; + scope.askForPin = null; scope.createPin(pin); } else { _firstpin = null; - $rootScope.askForPin = 1; + scope.askForPin = 1; $timeout(function() { scope.clear(); scope.error = 'Entered PINs were not equal. Try again'; diff --git a/views/createProfile.html b/views/createProfile.html index 0b1b05d23..9a9ac84ca 100644 --- a/views/createProfile.html +++ b/views/createProfile.html @@ -1,6 +1,6 @@
-
+
@@ -8,7 +8,7 @@
-
+
Copay @@ -207,13 +207,13 @@
-
+
clipo
-
Repeat PIN
+
Repeat PIN
diff --git a/views/home.html b/views/home.html index fc4c6bb71..4f747818d 100644 --- a/views/home.html +++ b/views/home.html @@ -1,7 +1,7 @@
-
+
@@ -58,12 +58,12 @@
-
+
clipo - clipo + clipo
-
Repeat PIN
+
Repeat PIN
@@ -75,7 +75,7 @@
-
+
clipo