mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-05-13 08:17:33 +00:00
fix: trace associate with log
This commit is contained in:
parent
1768a1641c
commit
dfb1874454
@ -1,3 +1,4 @@
|
||||
import { dashboardStore } from "./../store/modules/dashboard";
|
||||
/**
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
* contributor license agreements. See the NOTICE file distributed with
|
||||
@ -15,9 +16,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
import { useAppStoreWithOut } from "@/store/modules/app";
|
||||
import { useDashboardStore } from "@/store/modules/dashboard";
|
||||
import dateFormatStep from "@/utils/dateFormat";
|
||||
import getLocalTime from "@/utils/localtime";
|
||||
import type { EventParams } from "@/types/app";
|
||||
import type { LayoutConfig } from "@/types/dashboard";
|
||||
|
||||
export default function associateProcessor(props: any) {
|
||||
function eventAssociate() {
|
||||
@ -115,5 +118,13 @@ export default function associateProcessor(props: any) {
|
||||
item.metricValue = value;
|
||||
return item;
|
||||
}
|
||||
return { eventAssociate, traceFilters };
|
||||
function removeAssociationFilters(config: LayoutConfig) {
|
||||
const dashboardStore = useDashboardStore();
|
||||
if (!config.filters) {
|
||||
return;
|
||||
}
|
||||
delete config.filters;
|
||||
dashboardStore.setWidget(config);
|
||||
}
|
||||
return { eventAssociate, traceFilters, removeAssociationFilters };
|
||||
}
|
||||
|
@ -129,6 +129,7 @@ limitations under the License. -->
|
||||
import { ErrorCategory } from "./data";
|
||||
import type { LayoutConfig } from "@/types/dashboard";
|
||||
import type { DurationTime } from "@/types/app";
|
||||
import removeAssociationFilters from "@/hooks/useAssociateProcessor";
|
||||
|
||||
/*global defineProps, Recordable */
|
||||
const props = defineProps({
|
||||
@ -319,6 +320,7 @@ limitations under the License. -->
|
||||
}
|
||||
onUnmounted(() => {
|
||||
logStore.resetState();
|
||||
removeAssociationFilters(props.data);
|
||||
});
|
||||
watch(
|
||||
() => selectorStore.currentService,
|
||||
|
@ -89,6 +89,7 @@ limitations under the License. -->
|
||||
import { ElMessage } from "element-plus";
|
||||
import { EntityType, QueryOrders, Status } from "../../data";
|
||||
import type { LayoutConfig } from "@/types/dashboard";
|
||||
import removeAssociationFilters from "@/hooks/useAssociateProcessor";
|
||||
|
||||
/*global defineProps, Recordable */
|
||||
const props = defineProps({
|
||||
@ -245,6 +246,7 @@ limitations under the License. -->
|
||||
}
|
||||
onUnmounted(() => {
|
||||
traceStore.resetState();
|
||||
removeAssociationFilters(props.data);
|
||||
});
|
||||
watch(
|
||||
() => [selectorStore.currentPod],
|
||||
|
@ -86,6 +86,7 @@ limitations under the License. -->
|
||||
import { ElMessage } from "element-plus";
|
||||
import { EntityType, QueryOrders, Status } from "../../data";
|
||||
import type { LayoutConfig } from "@/types/dashboard";
|
||||
import removeAssociationFilters from "@/hooks/useAssociateProcessor";
|
||||
|
||||
const FiltersKeys: { [key: string]: string } = {
|
||||
status: "traceState",
|
||||
@ -229,6 +230,7 @@ limitations under the License. -->
|
||||
}
|
||||
onUnmounted(() => {
|
||||
traceStore.resetState();
|
||||
removeAssociationFilters(props.data);
|
||||
});
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
|
Loading…
Reference in New Issue
Block a user