feat(admin): Add group filtering for account listings#561
Merged
Wei-Shaw merged 1 commit intoWei-Shaw:mainfrom Feb 13, 2026
Merged
feat(admin): Add group filtering for account listings#561Wei-Shaw merged 1 commit intoWei-Shaw:mainfrom
Wei-Shaw merged 1 commit intoWei-Shaw:mainfrom
Conversation
- Add groupID parameter to ListAccounts and ListWithFilters methods - Implement account filtering by group ID in repository query - Add group query parameter parsing in account handler - Update all ListAccounts/ListWithFilters call sites with groupID parameter - Add group filter UI component to AccountTableFilters - Add i18n translations for group filter label in English and Chinese - Update API contract and test stubs to reflect new signature - Enable filtering accounts by their assigned groups in admin panel
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.
概述
本 PR 为管理后台账户列表新增「按分组筛选」功能,管理员可通过下拉选择指定分组,快速定位该分组下的所有账户。
变更内容
账户管理 - 分组筛选
ListAccounts/ListWithFilters方法新增groupID参数,查询时通过HasGroupWith(accountgroup.ID(groupID))过滤指定分组的账户group参数并传递至 repository 层AccountTableFilters组件新增分组下拉筛选器,选择分组后自动刷新列表admin.accounts.groupFilter)ListAccounts/ListWithFilters的 stub 签名,补充groupID参数涉及文件
backend/internal/repository/account_repo.goListAccounts/ListWithFilters增加groupID过滤条件backend/internal/handler/admin/account_handler.gogroupquery 参数并传入 repositorybackend/internal/handler/admin/admin_service_stub_test.gofrontend/src/components/admin/account/AccountTableFilters.vuefrontend/src/api/admin/accounts.tsgroupID字段frontend/src/i18n/locales/zh.tsfrontend/src/i18n/locales/en.ts测试计划
go build ./...编译通过gofmt/go vet检查无报错