Fixed uptime in System-->Status and added time zone info.

pull/1877/head v1.0.5-beta.27
morpheus65535 2 years ago
parent 246c2f3004
commit f2eb8f1342

@ -5,6 +5,7 @@ import platform
from flask import jsonify
from flask_restful import Resource
from tzlocal import get_localzone_name
from radarr.info import get_radarr_info
from sonarr.info import get_sonarr_info
@ -34,5 +35,6 @@ class SystemStatus(Resource):
os.path.dirname(__file__))))})
system_status.update({'bazarr_config_directory': args.config_dir})
system_status.update({'start_time': startTime})
system_status.update({'timezone': get_localzone_name() or 'Undefined'})
return jsonify(data=system_status)

@ -89,7 +89,7 @@ const SystemStatusView: FunctionComponent = () => {
interval.start();
return interval.stop();
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
}, [interval]);
useDocumentTitle("Status - Bazarr (System)");
@ -115,6 +115,7 @@ const SystemStatusView: FunctionComponent = () => {
{status?.bazarr_config_directory}
</Row>
<Row title="Uptime">{uptime}</Row>
<Row title="Time Zone">{status?.timezone}</Row>
</InfoContainer>
<InfoContainer title="More Info">
<Row title="Home Page">

@ -18,6 +18,7 @@ declare namespace System {
radarr_version: string;
sonarr_version: string;
start_time: number;
timezone: string;
}
interface Backups {

Loading…
Cancel
Save