mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-18 13:25:25 +00:00
fix: add conditions
This commit is contained in:
parent
69a148b599
commit
a1001a1285
@ -236,6 +236,11 @@ async function getMetricList() {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
async function setLegend() {
|
async function setLegend() {
|
||||||
|
if (
|
||||||
|
!(legend.metric.name && legend.metric.value && legend.metric.condidtion)
|
||||||
|
) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
updateSettings();
|
updateSettings();
|
||||||
const ids = topologyStore.nodes.map((d: Node) => d.id);
|
const ids = topologyStore.nodes.map((d: Node) => d.id);
|
||||||
const param = await useQueryTopologyMetrics([legend.metric.name], ids);
|
const param = await useQueryTopologyMetrics([legend.metric.name], ids);
|
||||||
@ -249,12 +254,12 @@ async function setLegend() {
|
|||||||
function changeLegend(type: string, opt: any) {
|
function changeLegend(type: string, opt: any) {
|
||||||
legend.metric[type] = opt[0].value || opt;
|
legend.metric[type] = opt[0].value || opt;
|
||||||
}
|
}
|
||||||
function changeCondition(opt: Option[]) {
|
// function changeCondition(opt: Option[]) {
|
||||||
legend.condition = opt[0].value;
|
// legend.condition = opt[0].value;
|
||||||
}
|
// }
|
||||||
function changeLegendMetric(type: string, opt: any) {
|
// function changeLegendMetric(type: string, opt: any) {
|
||||||
legend.secondMetric[type] = opt[0].value || opt;
|
// legend.secondMetric[type] = opt[0].value || opt;
|
||||||
}
|
// }
|
||||||
function changeScope(index: number, opt: Option[]) {
|
function changeScope(index: number, opt: Option[]) {
|
||||||
items[index].scope = opt[0].value;
|
items[index].scope = opt[0].value;
|
||||||
items[index].dashboard = "";
|
items[index].dashboard = "";
|
||||||
|
Loading…
Reference in New Issue
Block a user