Commit Graph
595 Commits
Author SHA1 Message Date
二丫讲梵 7748c13a1e feat(data-grid): show column comments in lookup 2026-07-08 23:44:33 +08:00
二丫讲梵 ddf6b3ed6b fix(sidebar): preserve Mongo collection children in search 2026-07-08 23:44:25 +08:00
二丫讲梵 843babf522 feat(connection): select new databases when visible 2026-07-08 22:51:45 +08:00
onenewcode 1b13d2176b fix(metadata): unify enum column metadata 2026-07-08 21:02:53 +08:00
auth0 07482557e6 fix(sidebar): locate active table reliably 2026-07-08 20:21:13 +08:00
lexmin0412 ac4b98c97c feat(ai): add general action mode 2026-07-08 19:31:19 +08:00
Abeautifulsnow 0901f176b0 fix(grid): preserve current page on data refresh instead of resetting to page 1
* @
fix(grid): preserve current page on data refresh instead of resetting to page 1

When refreshing table data (toolbar button, Ctrl+R, or auto-refresh), the
offset was hardcoded to 0, causing pagination to always jump back to the
first page. This was frustrating for users viewing later pages.

Use the current page offset (currentPage - 1) * pageSize so the user
stays on the same page after refresh. In infinite-scroll mode, the
offset still evaluates to 0 because resetInfiniteScrollState() sets
currentPage = 1, so behavior is unchanged.
@

* @
fix(grid): auto-redirect to last page when refreshed page no longer exists

Extends the refresh pagination fix with a safety net: when data is deleted
while viewing a later page (e.g. page 5 with only 2 pages remaining), the
grid auto-navigates to the last available page instead of showing an empty
page.

Uses a transient isRefreshingData flag to distinguish refresh/rollback
from normal pagination navigation, avoiding false triggers.
@

* Revert "@"

This reverts commit ff0bf0bb31.

* @
fix(grid): auto-redirect to last page when refreshed page no longer exists

When data is deleted while viewing a later page, the grid now auto-navigates
to the last available page instead of showing an empty page.

Uses a transient isRefreshingData flag to distinguish refresh/rollback
from normal pagination, and a loading-transition watcher (true->false)
placed after displayedTotalRowCount declaration to avoid TDZ errors.
@

* @
test(grid): add pagination offset-preservation and auto-redirect tests

Cover the two new behaviors added to DataGrid.vue:

1. dataGridPagination.test.ts — auto-redirect page calculation:
   - page beyond last page after data deletion → triggers redirect
   - page still valid → no redirect
   - fewer rows than one page → redirects to page 1
   - total=0 / total=undefined → guard prevents redirect

2. useDataGridActions.test.ts — offset preserved on reload:
   - onReloadData(offset=400) passes offset=400 to build-table-select-sql
   - resultPageOffset stored as 400 (not reset to 0)
@
2026-07-08 13:28:36 +08:00
t8y2 2929b1c035 feat(hive): add Kerberos connection options 2026-07-08 13:23:21 +08:00
t8y2 15d4dc6e2e fix(sqlserver): omit display width for integer types 2026-07-08 11:05:45 +08:00
t8y2 d2874bf1bb fix(grid): smooth canvas column interactions 2026-07-08 09:45:28 +08:00
onenewcode ba81fa4497 feat(redis): support multiple value formats in viewer (#2766)
* feat(redis): improve value decoding and viewer formats

* fix(redis): preserve stream field/value blobs

* Revert "fix(redis): preserve stream field/value blobs"

This reverts commit 168af0619a.
2026-07-08 00:13:20 +08:00
二丫讲梵 7eff6e544b feat(sqlCompletion): 优化表别名建议功能,避免使用 SQL 关键字 (#2805) 2026-07-08 00:01:24 +08:00
一颗红心andCursor 184e235999 feat: synchronize tab titles with saved SQL file renaming (#2739)
- Bidirectional sync between SQL library and tab titles
- Case-insensitive .sql extension via shared ensureSqlExtension
- Revert tab title when rename persistence fails

Close #2648

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-07 18:09:01 +08:00
zipg d90847bbba feat(ai): support SQL library file references 2026-07-07 15:39:10 +08:00
LSD a7be9eed13 fix(gridfs): support bulk download and paged browsing (#2743) 2026-07-07 12:43:07 +08:00
t8y2 65af804099 feat(editor): allow disabling SQL snippets 2026-07-07 12:36:51 +08:00
t8y2 9cbe857a2a feat(update): 应用内更新提示支持英文 release notes 2026-07-07 00:26:56 +08:00
Guoyu Su d7e2eac307 fix(mongodb): honor current command execution mode (#2702) 2026-07-07 00:02:34 +08:00
二丫讲梵 ff8e53d47b feat(query): 优化多条查询语句结果展示与语句匹配问题 (#2697) 2026-07-06 18:39:36 +08:00
LSD 095cb867a5 fix(mongodb): remove duplicate refresh button in document browser (#2696) 2026-07-06 18:28:42 +08:00
Hiep LeandClaude Opus 4.8 78019c44e2 fix(mongo): support ISODate() and new Date() in MongoDB queries
* fix(mongo): hỗ trợ ISODate() và new Date() trong query MongoDB

Parser shell MongoDB ở frontend chỉ chuyển ObjectId(...) sang extended JSON,
nên filter chứa ISODate("...")/new Date("...") không parse được: câu lệnh rơi
xuống SQL executor và báo lỗi "Use MongoDB-specific commands".

Bổ sung rewrite ISODate(x)/new Date(x) -> {"$date":x} trong normalizeJsonArgument,
khớp với json_value_to_bson của backend (đã hiểu $date/$oid). Thêm test cho
filter dùng ISODate và new Date.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* fix(mongo): decode $date extended JSON trong filter query

json_filter_value_to_bson chỉ chuyển {"$oid":...} nên filter chứa {"$date":...}
bị gửi thẳng lên server: { field: {"$date":...} } lỗi "unknown operator: $date",
còn { field: {"$gte": {"$date":...}} } so sánh với sub-document nên không khớp gì
(trả về rỗng).

Thêm nhánh parse_extended_json_date vào json_filter_value_to_bson, đồng bộ với
json_value_to_bson (vốn đã hiểu $date/$oid). Thêm test cho cả equality và $gte.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-06 18:21:15 +08:00
二丫讲梵 6d0a59a913 feat(editor): SQL editor execution button config toggle & optimization
- 在 SQL 编辑器的左侧添加每条语句的执行按钮
- 支持通过快捷键和右键菜单执行语句
- 增加多语言支持的相关文本描述
2026-07-06 18:01:31 +08:00
二丫讲梵 35d5e90378 feat(settings): improve sidebar search
- 新增设置选项以启用/禁用数据库内的表搜索
- 更新相关组件以支持表搜索功能
- 添加多语言支持的描述信息
2026-07-06 17:24:56 +08:00
zipgandzipg 7ccc632ce8 fix(sql): improve completion triggers
Co-authored-by: zipg <4047349+zipg@users.noreply.github.com>
2026-07-06 17:22:24 +08:00
LSD fa5e55a376 feat(mongodb): improve GridFS manager filtering and sorting
* docs: add GridFS manager filter and sort design

* feat: improve GridFS manager filtering and sorting
2026-07-06 17:17:33 +08:00
Abeautifulsnow 8539011f25 feat(ai): split Ask/Agent action menus with task-oriented Agent actions
* feat(ai): add task-oriented Agent actions with per-action contract

Introduce three Agent-native actions — query, exploreSchema,
executeAndExplain — so Agent mode surfaces task-oriented operations
instead of reusing Ask's SQL-producing action set.

- ai.ts: extend AiAction with the new actions; add ASK_ACTIONS /
  AGENT_ACTIONS and defaultActionForMode / isValidActionForMode
  helpers; raise maxTokens for the explanatory task actions.
- aiSkills.ts: add skill definitions (zh/en) for the three actions.
- aiAgentPlan.ts: task actions no longer emit a misleading
  "unsupported_action" execute step; they execute via the
  execute_query tool events, not the legacy client-side path.
- agent_loop.rs: per-action task-contract rules in both the prompt
  augmentation and repair paths (query -> execute & answer from real
  data; exploreSchema -> list_tables/get_columns; executeAndExplain
  -> run current SQL & explain).
- i18n (en/zh-CN/zh-TW): new action labels, placeholders, a
  generateNoExec label for Agent mode, and a task-oriented agent
  modeHint.

es/it/ja/pt-BR have no `ai` section and fall back to `en`, matching
existing coverage.

* feat(ai): split Ask/Agent action menus with mode-aware defaults

Wire the new Agent task actions into the assistant UI so each mode
shows a distinct, intent-matching action set.

- actionButtons is now a computed returning Ask or Agent buttons
  based on assistantMode. Agent menu: query / exploreSchema /
  executeAndExplain / generate (labeled "生成但不执行" via
  generateNoExec). Ask menu is unchanged.
- Switching mode lands on that mode's default (Ask -> generate,
  Agent -> query); the shared `generate` is not carried across
  because its label/semantics differ per mode. Vector DBs stay on
  `generate` since their action menu is hidden and they lack SQL
  tools (no execute_query contract).
- External Ask-style triggers (Fix with AI, Explain history) switch
  to Ask mode when invoked from Agent mode so the action is valid
  and the menu reflects what runs.
- Reset the active action to the mode default after each send.

* test(ai): cover Agent task-action contract and mode/action mapping

Lock in the deterministic parts of the Ask/Agent split so only the
LLM-behavior criteria need manual verification.

Backend (agent_loop.rs):
- query contract instructs the LLM to call execute_query and is not
  treated as a SQL-producing action.
- exploreSchema contract points to list_tables/get_columns and says
  not to execute data queries.
- executeAndExplain contract tells the LLM to run the current SQL.
- task actions do not require a SQL deliverable (a conclusion without
  a fenced SQL block still satisfies the contract).
- query repair prompt also targets execute_query.

Frontend (aiActions.spec.ts):
- defaultActionForMode: Ask -> generate, Agent -> query (not generate).
- isValidActionForMode: generate valid in both; Ask-only actions
  rejected in Agent mode and vice versa.
- ASK_ACTIONS / AGENT_ACTIONS composition (Agent menu starts with
  query and still offers generate).

* fix(ai): correct action menu on mode-switched triggers and i18n gaps

Issues found during review of the Ask/Agent action split:

- [#I01] triggerAction (Fix with AI / Explain history) invoked from
  Agent mode switched to Ask and set the action, but the mode-switch
  watch then reset activeAction to the Ask default ("generate"),
  overwriting the action just set — so the menu showed "Generate SQL"
  during a fix. Add a suppressModeActionReset flag so programmatic
  mode switches don't clobber the explicitly-set action.
- [#C01] Remove dead `unsupported_action` reason: buildAiAgentPlan no
  longer produces it, so drop the type variant and the unreachable
  skippedTitleKey case.
- [#I02] es/it/ja/pt-BR were missing the new Agent action keys
  (query/exploreSchema/executeAndExplain/generateNoExec) and their
  placeholders, causing English fallback in the Agent menu. Add the
  translations to match each locale's existing style.

* test(ai): align app-tests with task-action split

- aiSkills: add query/exploreSchema/executeAndExplain to the expected
  action set; broaden the id check (new ids are not _sql-suffixed) and
  relax the userInstruction assertion (schema inspection need not mention SQL).
- aiAgentPlan: drop the unsupported_action skipped step for non-generate
  actions (#C01 removed it from the plan and the reason union); add coverage
  for task-oriented Agent actions not driving client-side execution.

* test(ai): pin locale in dialect prompt spec

buildSystemPrompt selects zh/en copy via currentLocale(), which reflects the
host navigator.language. The spec asserts English strings, so it failed on
zh-CN machines (e.g. Windows with a Chinese system locale) while passing on
CI's en-US runners. Pin the locale to en in beforeAll so the assertions are
deterministic regardless of the host OS locale.
2026-07-06 14:41:39 +08:00
t8y2 92ef1ac3cf feat(structure): open editor from field and index nodes 2026-07-06 14:16:43 +08:00
wuxiemian 987b0fd263 fix: improve SQL table and JOIN completion (#2629) 2026-07-06 13:19:37 +08:00
t8y2 764b479679 fix(sidebar): ignore repeated row clicks during double-click 2026-07-06 12:54:33 +08:00
wuxiemian 3fdcc2d454 feat(sqlCompletion): support insert all-column completion 2026-07-06 01:29:23 +08:00
onenewcode 77cd835cda [fix] fix Linux Alt+F4 exit handling (#2576) 2026-07-05 12:41:54 +08:00
t8y2 e74782f651 feat(metadata): optimize agent metadata loading 2026-07-05 12:09:24 +08:00
t8y2 91855de832 feat(data-generate): prefer column default values 2026-07-05 00:49:13 +08:00
二丫讲梵 fdaa949fb1 feat(sidebar): add local table search 2026-07-05 00:09:04 +08:00
t8y2 223ecbec20 fix(oracle): skip rowid for view data queries 2026-07-04 17:07:43 +08:00
t8y2 7e7c4944e9 refactor(desktop): organize lib modules by domain 2026-07-04 13:53:52 +08:00
t8y2 90f0594e93 feat(sql): add semantic SQL completion engine 2026-07-04 13:20:13 +08:00
二丫讲梵 90d2ede740 feat(sidebar): add connection copy paste shortcuts 2026-07-04 12:19:56 +08:00
Guoyu Su 3a2abf4a49 fix(desktop): scale multi-statement query timeout (#2544) 2026-07-04 02:19:10 +08:00
t8y2 614daa5b19 feat(sql-library): add move to folder action 2026-07-04 00:37:23 +08:00
onenewcode 91c77e53c4 feat(mongodb): support collection stats shell commands
Add db.coll.stats() / dataSize() / storageSize(scale) / totalIndexSize()
so these MongoDB shell commands return a result grid instead of the
"Use MongoDB shell-style commands" error (issue #2529).

- backend: collStats via mongo_driver.collection_stats, wired through
  mongo_ops, the dbx-web /mongo/collection-stats route, the tauri
  mongo_collection_stats command, and the MCP data bridge
- node-core: parseMongoCollectionStatsCommand + result formatter and
  executeQuery dispatch (web build + MCP path)
- desktop: mirror the parser/executor/autocomplete in mongoShellCommand.ts,
  queryStore.ts, api/tauri/http facade, and mongoCompletion.ts
- tests for the parser, result formatter, and completion entries

Close #2529
2026-07-03 21:32:29 +08:00
miracle a0e9acce95 fix(ui): kafka agent icon contrast in dark theme 2026-07-03 21:14:31 +08:00
gggdsg b60f8b2039 feat(mongodb): add TLS connection options in connection tab (#2515)
Add MongoDB TLS options (`tlsAllowInvalidCertificates`, `retryWrites`, `tlsCAFile`) to the connection form with backend URL normalization and DocumentDB/SSH tunnel guidance, while preserving legacy `tlsCAFile` in `url_params` for existing DocumentDB users, hardening auth failure hint matching, and clarifying TLS bypass security labels.
2026-07-03 19:25:01 +08:00
f826cb5d38 feat(mongo): add GridFS manager for MongoDB
* feat(mongo): browse GridFS buckets and files

Refs #2342

* feat(mongo): add GridFS manager for MongoDB

* chore(i18n): autofill new translations

---------

Co-authored-by: dbx-i18n-bot <github-actions[bot]@users.noreply.github.com>
Co-authored-by: t8y2 <1156263951@qq.com>
2026-07-03 18:34:00 +08:00
t8y2 55aa0f8624 fix(mongodb): preserve int64 document filters 2026-07-03 17:39:48 +08:00
t8y2 5c79c26954 fix(iotdb): load databases without duplicate schema 2026-07-03 17:33:57 +08:00
t8y2 d205f47a8f fix(grid): preserve high-precision numeric edits 2026-07-03 16:08:20 +08:00
LRcodingandzero 06231d512f fix(jdbc): decode URL credentials for multi-at usernames
* fix(jdbc): decode URL credentials for multi-at usernames

* fix(jdbc): preserve url credential parsing semantics

---------

Co-authored-by: zero <zero@zeroMacmini.local>
2026-07-03 15:41:34 +08:00
t8y2 47238b689c feat(editor): add vim mode 2026-07-03 15:38:07 +08:00
t8y2 1ff3676531 fix(data): use saved row limit for table opens 2026-07-03 14:00:39 +08:00