replace href to ng-click in sidebars. add hack to close sidebars

This commit is contained in:
Matias Alejo Garcia 2014-12-07 12:40:59 -03:00
commit eeab451bbc
9 changed files with 38 additions and 32 deletions

View file

@ -1,14 +1,13 @@
'use strict';
angular.module('copayApp.services')
.factory('applicationService', function($rootScope, $location, $timeout) {
.factory('applicationService', function($rootScope, $location, $timeout, go) {
var root = {};
var isChromeApp = window.chrome && chrome.runtime && chrome.runtime.id;
root.restart = function() {
if (1 || window.cordova !== undefined) {
$rootScope.iden = $rootScope.wallet = undefined;
// NOP. no need to restart on cordova apps.
$location.path('/');
go.go('/');
$timeout(function(){
$rootScope.$digest();
},1);

View file

@ -1,6 +1,6 @@
'use strict';
angular.module('copayApp.services')
.factory('identityService', function($rootScope, $location, $timeout, $filter, pluginManager, notification, pendingTxsService, balanceService, applicationService) {
.factory('identityService', function($rootScope, $location, $timeout, $filter, pluginManager, notification, pendingTxsService, balanceService, applicationService, go) {
notification.enableHtml5Mode(); // for chrome: if support, enable it
// TODO:
@ -334,7 +334,7 @@ angular.module('copayApp.services')
noWallets: true
}, function() {
$rootScope.signingOut = false;
$rootScope.iden.close();
$rootScope.iden.close(); // Will trigger 'closed'
});
}
};

View file

@ -5,7 +5,7 @@ angular.module('copayApp.services')
var KEY = 'pinDATA';
var SALT = '4gllotIKguqi0EkIslC0';
var ITER = 2000;
var ITER = 5000;
var ls = localstorageService;
var root = {};