mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-09 01:13:55 +00:00
4e2baf1fa1
Display server health metrics from the unused /session endpoint: - Connected clients count (live from useClientStore) - Server uptime since last restart - Last client connection time (relative) - Last integration request time (relative) - Server timezone - Cloud latency (Docker only) with warning threshold Adds useSessionStats hook with 60s refetch interval, new NetworkStatus component as first card in Network panel, and navigation menu entries for Server status and Network interfaces sections. Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NrhcEgY8mqaxZi8veMPrrx
34 lines
1.3 KiB
TypeScript
34 lines
1.3 KiB
TypeScript
import { serverURL } from '../../externals';
|
|
|
|
// keys in tanstack store
|
|
export const APP_INFO = ['appinfo'];
|
|
export const APP_SETTINGS = ['appSettings'];
|
|
export const APP_SERVER_PORT = ['appServerPort'];
|
|
export const APP_VERSION = ['appVersion'];
|
|
export const AUTOMATION = ['automation'];
|
|
export const CUSTOM_FIELDS = ['customFields'];
|
|
export const CUSTOM_VIEWS = ['customViews'];
|
|
export const PROJECT_DATA = ['project'];
|
|
export const PROJECT_LIST = ['projectList'];
|
|
export const PROJECT_RUNDOWNS = ['projectRundowns'];
|
|
export const RUNDOWN = ['rundown'];
|
|
export const CURRENT_RUNDOWN_QUERY_KEY = ['rundown', 'current'];
|
|
export const getRundownQueryKey = (rundownId: string) => ['rundown', rundownId];
|
|
export const RUNTIME = ['runtimeStore'];
|
|
export const SESSION_STATS = ['sessionStats'];
|
|
export const URL_PRESETS = ['urlpresets'];
|
|
export const VIEW_SETTINGS = ['viewSettings'];
|
|
export const CSS_OVERRIDE = ['cssOverride'];
|
|
export const CLIENT_LIST = ['clientList'];
|
|
export const REPORT = ['report'];
|
|
export const TRANSLATION = ['translation'];
|
|
|
|
// API URLs
|
|
export const apiEntryUrl = `${serverURL}/data`;
|
|
|
|
const userAssetsPath = 'user';
|
|
const customTranslationsPath = 'translations/translations.json';
|
|
|
|
export const projectLogoPath = `${serverURL}/${userAssetsPath}/logo`;
|
|
export const customTranslationsURL = `${serverURL}/${userAssetsPath}/${customTranslationsPath}`;
|