mirror of
https://github.com/continew-org/continew-admin.git
synced 2025-09-14 10:57:19 +08:00
新增:个人中心新增查询操作日志功能,优化日志表结构,并支持关闭记录内网 IP 操作
This commit is contained in:
34
continew-admin-ui/src/api/monitor/operation-log.ts
Normal file
34
continew-admin-ui/src/api/monitor/operation-log.ts
Normal file
@@ -0,0 +1,34 @@
|
||||
import axios from 'axios';
|
||||
import qs from 'query-string';
|
||||
|
||||
export interface OperationLogRecord {
|
||||
logId: string;
|
||||
description: string;
|
||||
result: number,
|
||||
requestIp: string,
|
||||
location: string,
|
||||
browser: string,
|
||||
createUserString: string;
|
||||
createTime: string;
|
||||
}
|
||||
|
||||
export interface OperationLogParams extends Partial<OperationLogRecord> {
|
||||
page: number;
|
||||
size: number;
|
||||
sort: Array<string>;
|
||||
uid: string;
|
||||
}
|
||||
|
||||
export interface OperationLogListRes {
|
||||
list: OperationLogRecord[];
|
||||
total: number;
|
||||
}
|
||||
|
||||
export function queryOperationLogList(params: OperationLogParams) {
|
||||
return axios.get<OperationLogListRes>('/monitor/log/operation', {
|
||||
params,
|
||||
paramsSerializer: (obj) => {
|
||||
return qs.stringify(obj);
|
||||
},
|
||||
});
|
||||
}
|
Reference in New Issue
Block a user