🔨 数据清理时添加条数限制.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import type { DataGrid, Pagination } from '@/types/global';
|
||||
import type { ClearRequest, DataGrid, Pagination } from '@/types/global';
|
||||
import type { TableData } from '@arco-design/web-vue/es/table/interface';
|
||||
import axios from 'axios';
|
||||
import qs from 'query-string';
|
||||
@@ -15,7 +15,12 @@ export interface HostConnectLogQueryRequest extends Pagination {
|
||||
token?: string;
|
||||
status?: string;
|
||||
startTimeRange?: string[];
|
||||
clearLimit?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* 主机连接日志清理请求
|
||||
*/
|
||||
export interface HostConnectLogClearRequest extends HostConnectLogQueryRequest, ClearRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -89,13 +94,13 @@ export function deleteHostConnectLog(idList: Array<number>) {
|
||||
* 查询主机连接日志数量
|
||||
*/
|
||||
export function getHostConnectLogCount(request: HostConnectLogQueryRequest) {
|
||||
return axios.post<number>('/asset/host-connect-log/query-count', request);
|
||||
return axios.post<number>('/asset/host-connect-log/count', request);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清空主机连接日志
|
||||
*/
|
||||
export function clearHostConnectLog(request: HostConnectLogQueryRequest) {
|
||||
export function clearHostConnectLog(request: HostConnectLogClearRequest) {
|
||||
return axios.post<number>('/asset/host-connect-log/clear', request);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import type { SelectOptionData } from '@arco-design/web-vue';
|
||||
import type { DataGrid, Pagination } from '@/types/global';
|
||||
import type { TableData } from '@arco-design/web-vue/es/table/interface';
|
||||
import axios from 'axios';
|
||||
@@ -160,6 +161,13 @@ export function getHostPage(request: HostQueryRequest) {
|
||||
return axios.post<DataGrid<HostQueryResponse>>('/asset/host/query', request);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询主机数量
|
||||
*/
|
||||
export function getHostCount(request: HostQueryRequest) {
|
||||
return axios.post<number>('/asset/host/count', request);
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过 id 删除主机
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user