1
0
mirror of https://github.com/dkmstr/openuds.git synced 2025-01-03 01:17:56 +03:00

Improvement on ready setting logged in counter to 0

This commit is contained in:
Adolfo Gómez García 2016-10-03 14:23:19 +02:00
parent 0dc461c30b
commit 17044d38bd
3 changed files with 7 additions and 0 deletions

View File

@ -177,6 +177,11 @@ class OSManager(Module):
def logKnownIp(self, userService, ip):
userService.logIP(ip)
def toReady(self, userService):
userService.setProperty('loginsCounter', '0')
def loggedIn(self, userService, userName=None, save=True):
'''
This method:

View File

@ -171,6 +171,7 @@ class LinuxOsManager(osmanagers.OSManager):
state = State.USABLE
self.notifyIp(userService.unique_id, userService, data)
elif msg == "ready":
self.toReady(userService)
state = State.USABLE
notifyReady = True
self.notifyIp(userService.unique_id, userService, data)

View File

@ -181,6 +181,7 @@ class WindowsOsManager(osmanagers.OSManager):
state = State.USABLE
self.notifyIp(userService.unique_id, userService, data)
elif msg == "ready":
self.toReady(userService)
state = State.USABLE
notifyReady = True
self.notifyIp(userService.unique_id, userService, data)