update 调整代码格式

This commit is contained in:
疯狂的狮子Li
2023-04-03 00:05:09 +08:00
parent 8b01bfd2a0
commit 1595cb282a
194 changed files with 12184 additions and 12267 deletions

View File

@ -4,56 +4,56 @@ import { CacheVO } from './types';
// 查询缓存详细
export function getCache(): AxiosPromise<CacheVO> {
return request({
url: '/monitor/cache',
method: 'get'
});
return request({
url: '/monitor/cache',
method: 'get'
});
}
// 查询缓存名称列表
export function listCacheName() {
return request({
url: '/monitor/cache/getNames',
method: 'get'
});
return request({
url: '/monitor/cache/getNames',
method: 'get'
});
}
// 查询缓存键名列表
export function listCacheKey(cacheName: string) {
return request({
url: '/monitor/cache/getKeys/' + cacheName,
method: 'get'
});
return request({
url: '/monitor/cache/getKeys/' + cacheName,
method: 'get'
});
}
// 查询缓存内容
export function getCacheValue(cacheName: string, cacheKey: string) {
return request({
url: '/monitor/cache/getValue/' + cacheName + '/' + cacheKey,
method: 'get'
});
return request({
url: '/monitor/cache/getValue/' + cacheName + '/' + cacheKey,
method: 'get'
});
}
// 清理指定名称缓存
export function clearCacheName(cacheName: string) {
return request({
url: '/monitor/cache/clearCacheName/' + cacheName,
method: 'delete'
});
return request({
url: '/monitor/cache/clearCacheName/' + cacheName,
method: 'delete'
});
}
// 清理指定键名缓存
export function clearCacheKey(cacheName: string, cacheKey: string) {
return request({
url: '/monitor/cache/clearCacheKey/' + cacheName + '/' + cacheKey,
method: 'delete'
});
return request({
url: '/monitor/cache/clearCacheKey/' + cacheName + '/' + cacheKey,
method: 'delete'
});
}
// 清理全部缓存
export function clearCacheAll() {
return request({
url: '/monitor/cache/clearCacheAll',
method: 'delete'
});
return request({
url: '/monitor/cache/clearCacheAll',
method: 'delete'
});
}

View File

@ -1,7 +1,7 @@
export interface CacheVO {
commandStats: Array<{ name: string; value: string }>;
commandStats: Array<{ name: string; value: string }>;
dbSize: number;
dbSize: number;
info: { [key: string]: string };
info: { [key: string]: string };
}

View File

@ -4,33 +4,33 @@ import { AxiosPromise } from 'axios';
// 查询登录日志列表
export function list(query: LoginInfoQuery): AxiosPromise<LoginInfoVO[]> {
return request({
url: '/monitor/logininfor/list',
method: 'get',
params: query
});
return request({
url: '/monitor/logininfor/list',
method: 'get',
params: query
});
}
// 删除登录日志
export function delLoginInfo(infoId: string | number | Array<string | number>) {
return request({
url: '/monitor/logininfor/' + infoId,
method: 'delete'
});
return request({
url: '/monitor/logininfor/' + infoId,
method: 'delete'
});
}
// 解锁用户登录状态
export function unlockLoginInfo(userName: string | Array<string>) {
return request({
url: '/monitor/logininfor/unlock/' + userName,
method: 'get'
});
return request({
url: '/monitor/logininfor/unlock/' + userName,
method: 'get'
});
}
// 清空登录日志
export function cleanLoginInfo() {
return request({
url: '/monitor/logininfor/clean',
method: 'delete'
});
return request({
url: '/monitor/logininfor/clean',
method: 'delete'
});
}

View File

@ -1,20 +1,20 @@
export interface LoginInfoVO {
infoId: string | number;
tenantId: string | number;
userName: string;
status: string;
ipaddr: string;
loginLocation: string;
browser: string;
os: string;
msg: string;
loginTime: string;
infoId: string | number;
tenantId: string | number;
userName: string;
status: string;
ipaddr: string;
loginLocation: string;
browser: string;
os: string;
msg: string;
loginTime: string;
}
export interface LoginInfoQuery extends PageQuery {
ipaddr: string;
userName: string;
status: string;
orderByColumn: string;
isAsc: string;
ipaddr: string;
userName: string;
status: string;
orderByColumn: string;
isAsc: string;
}

View File

@ -4,17 +4,17 @@ import { AxiosPromise } from 'axios';
// 查询在线用户列表
export function list(query: OnlineQuery): AxiosPromise<OnlineVO[]> {
return request({
url: '/monitor/online/list',
method: 'get',
params: query
});
return request({
url: '/monitor/online/list',
method: 'get',
params: query
});
}
// 强退用户
export function forceLogout(tokenId: string) {
return request({
url: '/monitor/online/' + tokenId,
method: 'delete'
});
return request({
url: '/monitor/online/' + tokenId,
method: 'delete'
});
}

View File

@ -1,15 +1,15 @@
export interface OnlineQuery extends PageQuery {
ipaddr: string;
userName: string;
ipaddr: string;
userName: string;
}
export interface OnlineVO extends BaseEntity {
tokenId: string;
deptName: string;
userName: string;
ipaddr: string;
loginLocation: string;
browser: string;
os: string;
loginTime: number;
tokenId: string;
deptName: string;
userName: string;
ipaddr: string;
loginLocation: string;
browser: string;
os: string;
loginTime: number;
}

View File

@ -4,25 +4,25 @@ import { AxiosPromise } from 'axios';
// 查询操作日志列表
export function list(query: OperLogQuery): AxiosPromise<OperLogVO[]> {
return request({
url: '/monitor/operlog/list',
method: 'get',
params: query
});
return request({
url: '/monitor/operlog/list',
method: 'get',
params: query
});
}
// 删除操作日志
export function delOperlog(operId: string | number | Array<string | number>) {
return request({
url: '/monitor/operlog/' + operId,
method: 'delete'
});
return request({
url: '/monitor/operlog/' + operId,
method: 'delete'
});
}
// 清空操作日志
export function cleanOperlog() {
return request({
url: '/monitor/operlog/clean',
method: 'delete'
});
return request({
url: '/monitor/operlog/clean',
method: 'delete'
});
}

View File

@ -1,52 +1,52 @@
export interface OperLogQuery extends PageQuery {
title: string;
operName: string;
businessType: string;
status: string;
orderByColumn: string;
isAsc: string;
title: string;
operName: string;
businessType: string;
status: string;
orderByColumn: string;
isAsc: string;
}
export interface OperLogVO extends BaseEntity {
operId: string | number;
tenantId: string;
title: string;
businessType: number;
businessTypes: number[] | undefined;
method: string;
requestMethod: string;
operatorType: number;
operName: string;
deptName: string;
operUrl: string;
operIp: string;
operLocation: string;
operParam: string;
jsonResult: string;
status: number;
errorMsg: string;
operTime: string;
costTime: number;
operId: string | number;
tenantId: string;
title: string;
businessType: number;
businessTypes: number[] | undefined;
method: string;
requestMethod: string;
operatorType: number;
operName: string;
deptName: string;
operUrl: string;
operIp: string;
operLocation: string;
operParam: string;
jsonResult: string;
status: number;
errorMsg: string;
operTime: string;
costTime: number;
}
export interface OperLogForm {
operId: number | string | undefined;
tenantId: string | number | undefined;
title: string;
businessType: number;
businessTypes: number[] | undefined;
method: string;
requestMethod: string;
operatorType: number;
operName: string;
deptName: string;
operUrl: string;
operIp: string;
operLocation: string;
operParam: string;
jsonResult: string;
status: number;
errorMsg: string;
operTime: string;
costTime: number;
operId: number | string | undefined;
tenantId: string | number | undefined;
title: string;
businessType: number;
businessTypes: number[] | undefined;
method: string;
requestMethod: string;
operatorType: number;
operName: string;
deptName: string;
operUrl: string;
operIp: string;
operLocation: string;
operParam: string;
jsonResult: string;
status: number;
errorMsg: string;
operTime: string;
costTime: number;
}