diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 873ce834..18deb21a 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -3,6 +3,8 @@ import logging import tornado.web import tornado.escape import bleach +import time +import datetime from app.classes.shared.console import console from app.classes.shared.models import Users, installer @@ -23,6 +25,9 @@ class PanelHandler(BaseHandler): template = "panel/denied.html" + now = time.time() + formatted_time = str(datetime.datetime.fromtimestamp(now).strftime('%Y-%m-%d %H:%M:%S')) + defined_servers = controller.list_defined_servers() page_data = { @@ -38,7 +43,8 @@ class PanelHandler(BaseHandler): 'menu_servers': defined_servers, 'hosts_data': db_helper.get_latest_hosts_stats(), 'show_contribute': helper.get_setting("show_contribute_link", True), - 'error': error + 'error': error, + 'time': formatted_time } # if no servers defined, let's go to the build server area @@ -130,7 +136,9 @@ class PanelHandler(BaseHandler): self.render( template, - data=page_data + data=page_data, + time=time, + utc_offset=(time.timezone * -1 / 60 / 60), ) @tornado.web.authenticated diff --git a/app/frontend/templates/panel/parts/details_stats.html b/app/frontend/templates/panel/parts/details_stats.html index d7074cca..4d44c117 100644 --- a/app/frontend/templates/panel/parts/details_stats.html +++ b/app/frontend/templates/panel/parts/details_stats.html @@ -4,13 +4,14 @@