Repository navigation
fix(ux): bulk Delete on expenses, accounts and opportunities says the records go to the recycle bin (#2796) - #2799
Merged
objectstack-fleet[bot] merged 2 commits intoNov 26, 2026
Conversation
… records go to the recycle bin (#2796) The confirmText said "Permanently delete ... This cannot be undone." On the pinned 18.6.0, measured on the booted app, the console's bulk Delete on My Expenses, All Accounts and All Opportunities lands every selected record in the recycle bin (per-id DELETE answers recycleBinEntryId; a two-row deleteMany on crm_opportunity leaves one bin entry per row; on crm_expense and crm_account deleteMany answers 405 and the console falls back to per-id DELETE), and an administrator restores from there. All four UI languages, including the es-ES expense row the card's grep missed ("definitivamente"). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Author
|
repo:hotcrm#2 · sunhaolin · session_017xRBcV3h25dAMNWki8e1ns 席位核对 — ACCEPT · repo:hotcrm#2 · head
|
Contributor
Author
|
repo:hotcrm#2 · sunhaolin · session_017xRBcV3h25dAMNWki8e1ns Landing. This is a reviewer-class PR. The seat record 7168023312 accepted head
The seat flips it ready and arms auto-merge, and the merge queue squashes it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2796
Clause-②: no
Metadata-protocol: none
Metadata-impact: reviewer
维护者速读
What changes
The bulk Delete confirmation on three list views (My Expenses, All Accounts, every opportunity grid list) said "Permanently delete {{count}} ... This cannot be undone." It now says the records go to the recycle bin and an administrator can restore them:
Delete {{count}} account(s)? They go to the recycle bin, where an administrator can restore them.(expense(s), opportunity(ies) alike)确定要删除 {{count}} 个客户吗?删除的记录会进入回收站,管理员可以在那里恢复。{{count}} 件の取引先を削除しますか?削除したレコードはごみ箱に移り、管理者がそこから復元できます。¿Eliminar {{count}} cuenta(s)? Irán a la papelera, donde un administrador puede restaurarlas.The recycle-bin noun in each language is the platform's own Setup navigation label (Recycle Bin / 回收站 / ごみ箱 / Papelera). 13 strings in 13 files: the card's grep found 12; the 13th is the es-ES expense row, which said
definitivamenteand so escaped the grep pattern. No locale row was missing. The English for accounts and opportunities lives in the view source (the sales packs carry noenbulkActions entry), as before.Who can restore: the sentence names the administrator only, because that is true on all three objects. Per the FAQ on #2793, a Sales Manager can also restore accounts and opportunities, but nobody but an administrator can restore an expense; the sentence does not claim exclusivity, and listing roles per object would not fit a confirmation dialog. The retention (30 days) is left out of the dialog because it is a host setting (
retentionDaysper bin entry, configurable by an environment variable on the platform); the FAQ states it as the default.Agrees with the FAQ answer Where do deleted records go? on #2793 head
46fd23cb(records go to the recycle bin; an administrator restores them from Setup, Recycle Bin).Tests
No hotcrm test pins these confirmation strings (
grep -rn "Permanently\|confirmText" test/finds only generic translation-parity and bulk-dispatch shape pins), so none is added: the wording is free prose, and a prose pin is not a business fact.Acceptance notes
Measured on the booted app (pinned @objectstack 18.6.0,
objectstack dev, admin session, Chromium through Playwright), before the wording change, on probe records:Bulk delete lands in the recycle bin on all three views
DELETE /api/v1/data/crm_expense/IDanswered 200 withrecycleBinEntryId; the object's bin listing went from 0 entries to 1 (retentionDays: 30).POST .../crm_expense/deleteManyanswered 405OBJECT_API_METHOD_NOT_ALLOWED(bulk is not in the object's API methods); the console then sent oneDELETEper id, each 200 withrecycleBinEntryId.DELETE, 200 withrecycleBinEntryId, one bin entry.POST .../crm_opportunity/deleteMany200succeeded: 2; the bin listing then held one entry per row.DELETE, 200 withrecycleBinEntryId. 2 rows: deleteMany 405, then per-idDELETE, both binned.POST /api/v1/data/crm_account/recycle-bin/ENTRY/restoreanswered success and the account read back 200.Walked in English on desktop. The 405 on
deleteManyfor expenses and accounts is the console's fallback working as built; it is noted, not filed.Verification
Two-minute check: open Sales, Accounts, All Accounts; tick one row; click Delete on the selection bar. Expected: the dialog reads "Delete 1 account(s)? They go to the recycle bin, where an administrator can restore them."
Local runs at head
27fe5bbad:pnpm validate0,pnpm typecheck0,pnpm lint0,pnpm hygiene0,pnpm build0; targeted vitest (10 files: i18n-references, bulk-action-dispatch, i18n-package-ownership, i18n-shared-widget-parity, action-references, metadata-references, expense-module, org-locale-stored-text, package-ownership, view-predicate-dialect)Test Files 10 passed (10),Tests 188 passed (188). The fullpnpm testdid not finish inside the container's 30-minute background limit and is left to CI (declared narrowing). After the change, on the restarted app, the All Accounts dialog readsDelete 1 account(s)? They go to the recycle bin, where an administrator can restore them.in English and确定要删除 1 个客户吗?删除的记录会进入回收站,管理员可以在那里恢复。with a zh-CN browser.Generated by Claude Code
🤖 Generated with Claude Code
https://claude.ai/code/session_017xRBcV3h25dAMNWki8e1ns