Centralize rights management

This commit is contained in:
2024-11-30 10:26:14 +01:00
parent 74ab902180
commit 184a106542
11 changed files with 209 additions and 235 deletions

@ -1,9 +1,5 @@
import { APIClient } from "./ApiClient";
export interface SysInfoConfig {
allowed: boolean;
}
export interface LoadAverage {
one: number;
five: number;
@ -24,14 +20,6 @@ export interface SysInfoStatus {
}
export class SysInfoApi {
/**
* Get system info configuration (ie. check if it allowed)
*/
static async GetConfig(): Promise<SysInfoConfig> {
return (await APIClient.exec({ method: "GET", uri: "/sysinfo/config" }))
.data;
}
/**
* Get system status
*/