Socket.io

Downgraded library to 0.9.16. Version 1 and above requires CORS to be enabled on the server side socket port. If it's not enabled, the OPTIONS request fails.
This commit is contained in:
Chris Houseknecht
2014-08-28 15:08:26 -04:00
parent 264ad62db0
commit 0c336728f4
189 changed files with 44760 additions and 627 deletions

View File

@@ -532,8 +532,8 @@ angular.module('Tower', [
activateTab();
});
if (!Authorization.getToken()) {
// When the app first loads, redirect to login page
if (!Authorization.getToken() || !Authorization.isUserLoggedIn()) {
// User not authenticated, redirect to login page
$rootScope.sessionExpired = false;
$cookieStore.put('sessionExpired', false);
$location.path('/login');

View File

@@ -7,11 +7,19 @@
* Controller functions for user authentication.
*
*/
/**
* @ngdoc function
* @name controllers.function:Authentication
* @description This controller's for authenticating users
*/
* @description
* Controller for handling /#/login and /#/logout routes.
*
* Tower (app.js) checks if the user is authenticated and whether the user session is in an unexpired state. If either condition is not true,
* the user is redirected to /#/login.
*
* Functions for checking the session state are found in [lib/ansible/AuthService.js](/static/docs/api/lib.ansible.function:AuthService)
*
*/
'use strict';
function Authenticate($log, $cookieStore, $compile, $window, $scope, $rootScope, $location, Authorization, ToggleClass, Alert, Wait,