mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2026-09-24 16:00:53 +00:00
35 lines
916 B
Go
35 lines
916 B
Go
import http from '@/api';
|
|
import { Setting } from '../interface/setting';
|
|
|
|
export const getSettingInfo = () => {
|
|
return http.post<Setting.SettingInfo>(`/settings/search`);
|
|
};
|
|
|
|
export const updateSetting = (param: Setting.SettingUpdate) => {
|
|
return http.put(`/settings`, param);
|
|
};
|
|
|
|
export const updatePassword = (param: Setting.PasswordUpdate) => {
|
|
return http.put(`/settings/password`, param);
|
|
};
|
|
|
|
export const handleExpired = (param: Setting.PasswordUpdate) => {
|
|
return http.put(`/settings/expired/handle`, param);
|
|
};
|
|
|
|
export const syncTime = () => {
|
|
return http.post(`/settings/time/sync`, {});
|
|
};
|
|
|
|
export const cleanMonitors = () => {
|
|
return http.post(`/settings/monitor/clean`, {});
|
|
};
|
|
|
|
export const getMFA = () => {
|
|
return http.get<Setting.MFAInfo>(`/settings/mfa`, {});
|
|
};
|
|
|
|
export const bindMFA = (param: Setting.MFABind) => {
|
|
return http.post(`/settings/mfa/bind`, param);
|
|
};
|