forked from github/dataease
fix(X-Pack): 阈值告警-混合类型图表禁用
This commit is contained in:
parent
b6c1c7ca75
commit
5d948d6bea
@ -199,6 +199,9 @@ public class ChartViewThresholdManage {
|
||||
thresholdTemplate = convertStyle(thresholdTemplate.replace("[触发告警]", s));
|
||||
List<Map<String, Object>> tableRow = (List<Map<String, Object>>) data.get("tableRow");
|
||||
List<DatasetTableFieldDTO> fields = (List<DatasetTableFieldDTO>) data.get("fields");
|
||||
if (CollectionUtils.isEmpty(fields)) {
|
||||
return new ThresholdCheckVO(false, null, String.format("当前图表类型[%s]暂不支持阈值告警!", chart.getType()), null);
|
||||
}
|
||||
Map<Long, DatasetTableFieldDTO> fieldMap = fields.stream().collect(Collectors.toMap(DatasetTableFieldDTO::getId, item -> item));
|
||||
FilterTreeObj filterTreeObj = JsonUtil.parseObject(thresholdRules, FilterTreeObj.class);
|
||||
List<Map<String, Object>> rows = filterRows(tableRow, filterTreeObj, fieldMap);
|
||||
|
2
de-xpack
2
de-xpack
@ -1 +1 @@
|
||||
Subproject commit f13cef680d79dcc02bd6ef7aa08d65765a749eb9
|
||||
Subproject commit 321bac2953ac01b12ae69a4e9beb050e0895f965
|
Loading…
Reference in New Issue
Block a user