mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-05-02 20:23:15 +00:00
fix: update multiple metrics
This commit is contained in:
parent
37fad917fb
commit
65cd6eb437
@ -63,6 +63,7 @@ import { useAppStoreWithOut } from "@/store/modules/app";
|
|||||||
import graphs from "../graphs";
|
import graphs from "../graphs";
|
||||||
import { ElMessage } from "element-plus";
|
import { ElMessage } from "element-plus";
|
||||||
import { useI18n } from "vue-i18n";
|
import { useI18n } from "vue-i18n";
|
||||||
|
import { AudioAnalyser } from "three";
|
||||||
|
|
||||||
const props = {
|
const props = {
|
||||||
data: {
|
data: {
|
||||||
@ -78,7 +79,7 @@ export default defineComponent({
|
|||||||
setup(props) {
|
setup(props) {
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const loading = ref<boolean>(false);
|
const loading = ref<boolean>(false);
|
||||||
const state = reactive({
|
const state = reactive<{ source: any }>({
|
||||||
source: {},
|
source: {},
|
||||||
});
|
});
|
||||||
const { data } = toRefs(props);
|
const { data } = toRefs(props);
|
||||||
@ -99,9 +100,7 @@ export default defineComponent({
|
|||||||
const keys = Object.keys(json.data);
|
const keys = Object.keys(json.data);
|
||||||
keys.map((key: string, index) => {
|
keys.map((key: string, index) => {
|
||||||
const m = props.data.metrics[index];
|
const m = props.data.metrics[index];
|
||||||
state.source = {
|
state.source[m] = json.data[key].values.values.map((d: any) => d.value);
|
||||||
[m]: json.data[key].values.values.map((d: any) => d.value),
|
|
||||||
};
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user