mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-06-14 11:42:02 +08:00
feat: 实现 Redfish API 标准接口;支持通过前端开关控制 Redfish 服务
This commit is contained in:
@@ -392,6 +392,24 @@ export const webConfigApi = {
|
||||
}),
|
||||
}
|
||||
|
||||
export interface RedfishConfigResponse {
|
||||
enabled: boolean
|
||||
}
|
||||
|
||||
export interface RedfishConfigUpdate {
|
||||
enabled?: boolean
|
||||
}
|
||||
|
||||
export const redfishConfigApi = {
|
||||
get: () => request<RedfishConfigResponse>('/config/redfish'),
|
||||
|
||||
update: (config: RedfishConfigUpdate) =>
|
||||
request<RedfishConfigResponse>('/config/redfish', {
|
||||
method: 'PATCH',
|
||||
body: JSON.stringify(config),
|
||||
}),
|
||||
}
|
||||
|
||||
export const systemApi = {
|
||||
/**
|
||||
* 重启系统
|
||||
|
||||
Reference in New Issue
Block a user