Reset variables. Added text: repeat pin

This commit is contained in:
Gustavo Maximiliano Cortez 2015-01-29 02:21:59 -03:00
parent 36bd87f729
commit e2bc1eb86a
3 changed files with 6 additions and 0 deletions

View File

@ -64,6 +64,7 @@ angular.module('copayApp.services')
if (!$rootScope.hasPin) {
if (!_firstpin) {
_firstpin = pin;
$rootScope.askForPin = 2;
$timeout(function() {
scope.clear();
}, 100);
@ -71,10 +72,13 @@ angular.module('copayApp.services')
}
else {
if (pin === _firstpin) {
_firstpin = null;
$rootScope.askForPin = null;
scope.createPin(pin);
}
else {
_firstpin = null;
$rootScope.askForPin = 1;
$timeout(function() {
scope.clear();
scope.error = 'Entered PINs were not equal. Try again';

View File

@ -213,6 +213,7 @@
<img src="img/clipo-pin.png" alt="clipo" width="380">
</div>
<div class="text-white text-center" ng-show="$root.askForPin == 2">Repeat PIN</div>
<div class="box-notification" ng-show="error">
<div class="box-icon error">
<i class="fi-x size-24"></i>

View File

@ -63,6 +63,7 @@
<img src="img/clipo-pin-enter.png" alt="clipo" width="300" ng-show="$root.hasPin && !$root.iden">
<img src="img/clipo-pin.png" alt="clipo" width="380" ng-show="$root.askForPin">
</div>
<div class="text-white text-center" ng-show="$root.askForPin == 2">Repeat PIN</div>
<div class="box-notification" ng-show="error">
<div class="box-icon error">
<i class="fi-x size-24"></i>