mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-18 14:45:25 +00:00
change selectors
This commit is contained in:
parent
e78b1df999
commit
8d26b38ff0
@ -366,7 +366,10 @@ async function changeService(service: any) {
|
|||||||
if (service[0]) {
|
if (service[0]) {
|
||||||
states.currentService = service[0].value;
|
states.currentService = service[0].value;
|
||||||
selectorStore.setCurrentService(service[0]);
|
selectorStore.setCurrentService(service[0]);
|
||||||
fetchPods(dashboardStore.entity, selectorStore.currentService.id, true);
|
const e = dashboardStore.entity.split("Relation")[0];
|
||||||
|
selectorStore.setCurrentPod(null);
|
||||||
|
states.currentPod = "";
|
||||||
|
fetchPods(e, selectorStore.currentService.id, true);
|
||||||
} else {
|
} else {
|
||||||
selectorStore.setCurrentService(null);
|
selectorStore.setCurrentService(null);
|
||||||
}
|
}
|
||||||
@ -376,6 +379,9 @@ function changeDestService(service: any) {
|
|||||||
if (service[0]) {
|
if (service[0]) {
|
||||||
states.currentDestService = service[0].value;
|
states.currentDestService = service[0].value;
|
||||||
selectorStore.setCurrentDestService(service[0]);
|
selectorStore.setCurrentDestService(service[0]);
|
||||||
|
selectorStore.setCurrentDestPod(null);
|
||||||
|
states.currentDestPod = "";
|
||||||
|
fetchPods(dashboardStore.entity, selectorStore.currentDestService.id, true);
|
||||||
} else {
|
} else {
|
||||||
selectorStore.setCurrentDestService(null);
|
selectorStore.setCurrentDestService(null);
|
||||||
}
|
}
|
||||||
@ -537,11 +543,11 @@ async function fetchPods(
|
|||||||
if (setPod) {
|
if (setPod) {
|
||||||
let p;
|
let p;
|
||||||
if (states.currentDestPod) {
|
if (states.currentDestPod) {
|
||||||
p = selectorStore.pods.find(
|
p = selectorStore.destPods.find(
|
||||||
(d: { label: string }) => d.label === states.currentDestPod
|
(d: { label: string }) => d.label === states.currentDestPod
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
p = selectorStore.pods.find(
|
p = selectorStore.destPods.find(
|
||||||
(d: { label: string }, index: number) => index === 0
|
(d: { label: string }, index: number) => index === 0
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user