Clear status page on return
This commit is contained in:
parent
ecafb1db80
commit
310d23006b
2 changed files with 11 additions and 0 deletions
|
@ -355,6 +355,7 @@ class CentralManagement():
|
|||
self.plotter.park()
|
||||
scan = threading.Thread(target=self.cleanDrawing, name='reset')
|
||||
scan.start()
|
||||
self.server.statusPage.clearAssignment()
|
||||
|
||||
def scanImage(self) -> str:
|
||||
"""
|
||||
|
|
|
@ -378,6 +378,16 @@ class StatusPage():
|
|||
self.hit_opened = None
|
||||
self.hit_submitted = None
|
||||
|
||||
def clearAssignment(self):
|
||||
logger.info("Resetting hit assignment")
|
||||
self.worker_id = None
|
||||
self.ip = None
|
||||
self.location = None
|
||||
self.browser = None
|
||||
self.os = None
|
||||
self.resolution = None
|
||||
self.hit_created = None
|
||||
|
||||
def __setattr__(self, name, value):
|
||||
if name in self.__dict__ and self.__dict__[name] == value:
|
||||
logger.debug(f"Ignore setting status of {name}: it already is set to {value}")
|
||||
|
|
Loading…
Reference in a new issue