🔨 修改标签查询逻辑.
This commit is contained in:
@@ -28,7 +28,7 @@ export interface MonitorHostSwitchUpdateRequest {
|
||||
* 监控主机查询请求
|
||||
*/
|
||||
export interface MonitorHostQueryRequest extends Pagination {
|
||||
agentKeyList?: Array<string>;
|
||||
agentKeys?: Array<string>;
|
||||
searchValue?: string;
|
||||
alarmSwitch?: number;
|
||||
policyId?: number;
|
||||
@@ -43,6 +43,15 @@ export interface MonitorHostQueryRequest extends Pagination {
|
||||
tags?: Array<number>;
|
||||
}
|
||||
|
||||
/**
|
||||
* 监控主机标签查询请求
|
||||
*/
|
||||
export interface MonitorHostQueryTagRequest {
|
||||
measurement?: string;
|
||||
policyId?: number;
|
||||
agentKeys?: Array<string>;
|
||||
}
|
||||
|
||||
/**
|
||||
* 监控主机图表查询请求
|
||||
*/
|
||||
@@ -147,12 +156,12 @@ export interface MonitorHostMetricsData {
|
||||
/**
|
||||
* 查询监控主机指标
|
||||
*/
|
||||
export function getMonitorHostMetrics(agentKeyList: Array<string>) {
|
||||
export function getMonitorHostMetrics(agentKeys: Array<string>) {
|
||||
return axios.post<Array<MonitorHostMetricsData>>('/monitor/monitor-host/metrics', {
|
||||
agentKeyList
|
||||
agentKeys
|
||||
}, {
|
||||
promptBizErrorMessage: false,
|
||||
promptRequestErrorMessage: false,
|
||||
promptRequestErrorMessage: false
|
||||
});
|
||||
}
|
||||
|
||||
@@ -178,10 +187,10 @@ export function getMonitorHostPage(request: MonitorHostQueryRequest) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询监控告警标签
|
||||
* 查询监控主机标签
|
||||
*/
|
||||
export function getMonitorHostPolicyRuleTags(policyId: number, measurement: string = '') {
|
||||
return axios.get<Array<string>>('/monitor/monitor-host/host-tags', { params: { policyId, measurement } });
|
||||
export function getMonitorHostTags(request: MonitorHostQueryTagRequest) {
|
||||
return axios.post<Array<string>>('/monitor/monitor-host/host-tags', request);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user