feat: 店铺列表新增条件
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 6m47s
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 6m47s
This commit is contained in:
23
openspec/changes/add-shop-contact-phone-search/proposal.md
Normal file
23
openspec/changes/add-shop-contact-phone-search/proposal.md
Normal file
@@ -0,0 +1,23 @@
|
||||
# Change: 新增店铺联系电话精确搜索
|
||||
|
||||
## Why
|
||||
|
||||
运营无法通过店铺联系电话快速定位目标店铺。店铺列表已支持名称、编号和层级等条件筛选,但缺少联系电话的精确检索入口。
|
||||
|
||||
## What Changes
|
||||
|
||||
- 在店铺列表筛选区增加“联系电话”输入框,限制输入为 11 位数字。
|
||||
- 将有效联系电话以 `contact_phone` 参数传递给现有 `GET /api/admin/shops` 查询,保持原店铺分页响应结构。
|
||||
- 空联系电话不传 `contact_phone` 参数;非法号码不发起查询并显示输入错误提示。
|
||||
- 使用搜索栏现有查询和清空能力:查询从第一页加载;清空联系电话后保留其他筛选条件并恢复不带联系电话条件的店铺列表。
|
||||
- 保持有效联系电话精确匹配;支持加载中和空结果状态。
|
||||
|
||||
## Impact
|
||||
|
||||
- Affected specs: `shop-management`
|
||||
- Affected code:
|
||||
- `src/types/api/shop.ts`
|
||||
- `src/api/modules/shop.ts`
|
||||
- `src/views/shop-management/list/index.vue`
|
||||
- API contract:
|
||||
- `GET /api/admin/shops?contact_phone=13800138000`
|
||||
Reference in New Issue
Block a user