2016-08-30 11:33:32 -03:00
|
|
|
'use strict';
|
|
|
|
|
|
2016-11-08 12:37:05 -03:00
|
|
|
angular.module('copayApp.controllers').controller('welcomeController', function($scope, $state, $timeout, $ionicConfig, $log, profileService, startupService, storageService) {
|
2016-10-10 17:12:14 -03:00
|
|
|
|
2016-10-11 22:46:07 -04:00
|
|
|
$scope.$parent.$on("$ionicView.afterEnter", function() {
|
|
|
|
|
startupService.ready();
|
|
|
|
|
});
|
|
|
|
|
|
2017-02-23 14:26:05 -05:00
|
|
|
$scope.$on("$ionicView.beforeEnter", function() {
|
|
|
|
|
$ionicConfig.views.swipeBackEnabled(false);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
$scope.$on("$ionicView.beforeLeave", function() {
|
|
|
|
|
$ionicConfig.views.swipeBackEnabled(true);
|
|
|
|
|
});
|
|
|
|
|
|
2016-08-30 15:38:48 -03:00
|
|
|
$scope.createProfile = function() {
|
|
|
|
|
$log.debug('Creating profile');
|
|
|
|
|
profileService.createProfile(function(err) {
|
|
|
|
|
if (err) $log.warn(err);
|
|
|
|
|
});
|
|
|
|
|
};
|
2016-08-30 11:33:32 -03:00
|
|
|
|
|
|
|
|
});
|