mirror of
https://github.com/ansible/awx.git
synced 2026-05-07 17:37:37 -02:30
Fix for session limit per user
This commit is contained in:
@@ -754,7 +754,7 @@ var tower = angular.module('Tower', [
|
|||||||
control_socket.on("limit_reached", function(data) {
|
control_socket.on("limit_reached", function(data) {
|
||||||
$log.debug(data.reason);
|
$log.debug(data.reason);
|
||||||
$rootScope.sessionTimer.expireSession('session_limit');
|
$rootScope.sessionTimer.expireSession('session_limit');
|
||||||
$location.url('/login');
|
$state.go('signOut');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
openSocket();
|
openSocket();
|
||||||
|
|||||||
@@ -40,7 +40,6 @@ export default
|
|||||||
// attached to the $rootScope.
|
// attached to the $rootScope.
|
||||||
var features = FeaturesService.get();
|
var features = FeaturesService.get();
|
||||||
if(features){
|
if(features){
|
||||||
|
|
||||||
scope.loadingLicense = false;
|
scope.loadingLicense = false;
|
||||||
scope.activityStreamActive = (toState.name === 'activityStream') ? true : false;
|
scope.activityStreamActive = (toState.name === 'activityStream') ? true : false;
|
||||||
scope.showActivityStreamButton = (FeaturesService.featureEnabled('activity_streams') || toState.name ==='activityStream') ? true : false;
|
scope.showActivityStreamButton = (FeaturesService.featureEnabled('activity_streams') || toState.name ==='activityStream') ? true : false;
|
||||||
|
|||||||
@@ -25,8 +25,8 @@
|
|||||||
responseError: function(rejection){
|
responseError: function(rejection){
|
||||||
if(rejection && rejection.data && rejection.data.detail && rejection.data.detail === "Maximum per-user sessions reached"){
|
if(rejection && rejection.data && rejection.data.detail && rejection.data.detail === "Maximum per-user sessions reached"){
|
||||||
$rootScope.sessionTimer.expireSession('session_limit');
|
$rootScope.sessionTimer.expireSession('session_limit');
|
||||||
var location = $injector.get('$location');
|
var state = $injector.get('$state');
|
||||||
location.url('/login');
|
state.go('signOut');
|
||||||
return $q.reject(rejection);
|
return $q.reject(rejection);
|
||||||
}
|
}
|
||||||
return $q.reject(rejection);
|
return $q.reject(rejection);
|
||||||
|
|||||||
Reference in New Issue
Block a user