Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

fix(grid): sync WHERE filter input to tab store on every keystroke

t8y2e1a07aae4abd
diff --git a/src/components/grid/DataGrid.vue b/src/components/grid/DataGrid.vue
index 12c5a7e1a4..8de26282f8 100644
--- a/src/components/grid/DataGrid.vue
+++ b/src/components/grid/DataGrid.vue
@@ -112,6 +112,7 @@ const emit = defineEmits<{
reload: [sql?: string, searchText?: string, whereInput?: string, orderBy?: string, limit?: number, offset?: number];
paginate: [offset: number, limit: number, whereInput?: string, orderBy?: string];
sort: [column: string, columnIndex: number, direction: "asc" | "desc" | null, whereInput?: string];
+ "update:whereInput": [value: string];
}>();
const hasData = computed(() => props.result.columns.length > 0);
@@ -564,6 +565,7 @@ function navigateWhereSuggestion(delta: number) {
}
watch(whereFilterInput, (val) => {
+ emit("update:whereInput", val);
whereSuggestions.value = [];
if (!props.tableMeta?.columns?.length) return;
const trimmed = val.trim();
diff --git a/src/components/layout/ContentArea.vue b/src/components/layout/ContentArea.vue
index aac3ee4805..ecfbaff790 100644
--- a/src/components/layout/ContentArea.vue
+++ b/src/components/layout/ContentArea.vue
@@ -386,6 +386,7 @@ function onHandleCloseColumnPanel() {
:database="activeTab.database"
:table-meta="activeTab.tableMeta"
:on-execute-sql="async (sql: string) => emit('executeSql', sql)"
+ @update:where-input="(v: string) => (activeTab.whereInput = v)"
@reload="
(
sql?: string,