mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Retain tab when navigating back to server_details
This commit is contained in:
parent
ec4bcda31e
commit
ecb40ee2ec
@ -36,6 +36,7 @@ class ServersController(metaclass=Singleton):
|
||||
self.management_helper = management_helper
|
||||
self.servers_list = []
|
||||
self.stats = Stats(self.helper, self)
|
||||
self.server_subpage = {}
|
||||
|
||||
# **********************************************************************************
|
||||
# Generic Servers Methods
|
||||
|
@ -481,6 +481,12 @@ class PanelHandler(BaseHandler):
|
||||
subpage = nh3.clean(self.get_argument("subpage", ""))
|
||||
|
||||
server_id = self.check_server_id()
|
||||
# load page the user was on last
|
||||
server_subpage = self.controller.servers.server_subpage.get(server_id, "")
|
||||
if subpage == "" and server_subpage != "":
|
||||
subpage = self.controller.servers.server_subpage.get(server_id, "")
|
||||
else:
|
||||
self.controller.servers.server_subpage[server_id] = subpage
|
||||
if server_id is None:
|
||||
return
|
||||
if not self.failed_server:
|
||||
|
Loading…
Reference in New Issue
Block a user