mirror of
https://github.com/ansible/awx.git
synced 2026-02-27 15:58:45 -03:30
Fixed socket status check to correctly update the tooltip.
This commit is contained in:
@@ -135,18 +135,16 @@ angular.module('SocketIO', ['AuthService', 'Utilities'])
|
||||
if (self.socket.socket.connected) {
|
||||
$log.debug('Socket connected');
|
||||
self.scope.socketStatus = 'ok';
|
||||
self.scope.socketTip = 'Connected. Click to close.';
|
||||
}
|
||||
else if (self.socket.socket.connecting || self.socket.socket.reconnecting) {
|
||||
$log.debug('Socket connecting...');
|
||||
self.scope.socketStatus = 'connecting';
|
||||
self.scope.socketTip = 'Connecting. Click to cancel.';
|
||||
}
|
||||
else {
|
||||
$log.debug('Socket error: connection refused');
|
||||
self.scope.socketStatus = 'error';
|
||||
self.scope.socketTip = 'Connection failed. Click to retry';
|
||||
}
|
||||
self.scope.$emit('socketStatusChange');
|
||||
return self.scope.socketStatus;
|
||||
},
|
||||
on: function (eventName, callback) {
|
||||
|
||||
Reference in New Issue
Block a user