server,email,pw as url params
This commit is contained in:
@@ -1,5 +1,12 @@
|
|||||||
angular.module('app.frontend')
|
angular.module('app.frontend')
|
||||||
.controller('HomeCtrl', function ($scope, $rootScope, $timeout, modelManager, syncManager, authManager) {
|
.controller('HomeCtrl', function ($scope, $stateParams, $rootScope, $timeout, modelManager, syncManager, authManager) {
|
||||||
|
|
||||||
|
if($stateParams.server && $stateParams.email && authManager.offline()) {
|
||||||
|
authManager.login($stateParams.server, $stateParams.email, $stateParams.pw, function(response){
|
||||||
|
window.location.reload();
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
syncManager.loadLocalItems(function(items) {
|
syncManager.loadLocalItems(function(items) {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
|
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ angular.module('app.frontend')
|
|||||||
})
|
})
|
||||||
|
|
||||||
.state('home', {
|
.state('home', {
|
||||||
url: '/',
|
url: '/?server&email&pw',
|
||||||
parent: 'base',
|
parent: 'base',
|
||||||
views: {
|
views: {
|
||||||
'content@' : {
|
'content@' : {
|
||||||
|
|||||||
Reference in New Issue
Block a user