Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
feat: allow click slow query log item for PostgreSQL to display index advice (#5893)
rebelice199660fb3159
diff --git a/frontend/src/components/SlowQuery/Panel/DetailPanel.vue b/frontend/src/components/SlowQuery/Panel/DetailPanel.vueindex 767bf659a8..b855c744a6 100644--- a/frontend/src/components/SlowQuery/Panel/DetailPanel.vue+++ b/frontend/src/components/SlowQuery/Panel/DetailPanel.vue@@ -66,7 +66,10 @@v-if="isDev() && slowQueryLog":slow-query-log="slowQueryLog"/>- <div class="flex-1 overflow-auto border">+ <div+ v-if="instanceHasSlowQueryDetail(database.instance)"+ class="flex-1 overflow-auto border"+ ><BBGrid:column-list="columns":data-source="log.statistics?.samples"@@ -129,7 +132,7 @@ import { NButton, NDrawer, NDrawerContent } from "naive-ui";import { type BBGridColumn, type BBGridRow, BBGrid } from "@/bbkit";import type { ComposedSlowQueryLog } from "@/types";import type { SlowQueryDetails } from "@/types/proto/v1/database_service";-import { isDev } from "@/utils";+import { instanceHasSlowQueryDetail, isDev } from "@/utils";import {DatabaseName,InstanceName,diff --git a/frontend/src/components/SlowQuery/Panel/LogTable.vue b/frontend/src/components/SlowQuery/Panel/LogTable.vueindex ead37146ea..d850cadec9 100644--- a/frontend/src/components/SlowQuery/Panel/LogTable.vue+++ b/frontend/src/components/SlowQuery/Panel/LogTable.vue@@ -3,9 +3,7 @@:column-list="columns":data-source="slowQueryLogList":show-placeholder="showPlaceholder"- :is-row-clickable="- (row) => instanceHasSlowQueryDetail(row.database.instance)- "+ :is-row-clickable="(row) => true":is-row-expanded="isSelectedRow"class="border w-auto overflow-x-auto"header-class="capitalize"diff --git a/frontend/src/components/SlowQuery/Panel/SlowQueryPanel.vue b/frontend/src/components/SlowQuery/Panel/SlowQueryPanel.vueindex 38dc332352..3b2c48c8ee 100644--- a/frontend/src/components/SlowQuery/Panel/SlowQueryPanel.vue+++ b/frontend/src/components/SlowQuery/Panel/SlowQueryPanel.vue@@ -60,7 +60,6 @@ import {import LogFilter from "./LogFilter.vue";import LogTable from "./LogTable.vue";import DetailPanel from "./DetailPanel.vue";-import { instanceHasSlowQueryDetail } from "@/utils";const props = withDefaults(defineProps<{@@ -106,11 +105,7 @@ const fetchSlowQueryLogList = async () => {};const selectSlowQueryLog = (log: ComposedSlowQueryLog) => {- if (instanceHasSlowQueryDetail(log.database.instance)) {- selectedSlowQueryLog.value = log;- } else {- selectedSlowQueryLog.value = undefined;- }+ selectedSlowQueryLog.value = log;};const syncNow = async () => {