feat(shop): 添加商城列表页浮动购物车按钮

- 在 shop 页面右下角添加固定定位的绿色圆形购物车按钮
- 按钮右上角显示购物车商品数量角标,超过 99 显示为 99+
- 点击按钮跳转到购物车页面,非 tabBar 页面
- 使用 useCartContext 的 totalCount 实时更新商品数量显示
- 注释掉用户页面 “我的钱包” 入口,暂时隐藏该功能
This commit is contained in:
2026-07-14 02:48:25 +08:00
parent 70af5426e8
commit a37f7a5d4d
2 changed files with 3 additions and 1 deletions

View File

@@ -25,6 +25,8 @@
- VIP 审核页:`src/pages/user/vip-review/index.tsx` - VIP 审核页:`src/pages/user/vip-review/index.tsx`
- VIP 升级页:`src/pages/user/vip-upgrade/index.tsx` - VIP 升级页:`src/pages/user/vip-upgrade/index.tsx`
- 门店中心:`src/pages/store/center/index.tsx` - 门店中心:`src/pages/store/center/index.tsx`
- 购物车 API`src/api/shop/shopCart/index.ts`(批量删除接口 `/shop/shop-cart/batch` 后端期望直接接收 `ArrayList<Integer>``[1,2,3]`,不要用 `{ ids }` 包裹)
- 购物车 Context`src/contexts/CartContext.tsx`
## 订阅消息 ## 订阅消息
- 模板 ID`sh1K9iK7vZjebUNFu6OsMsnsJxm4whThWGrhN7I4zVg`(交易提醒) - 模板 ID`sh1K9iK7vZjebUNFu6OsMsnsJxm4whThWGrhN7I4zVg`(交易提醒)

View File

@@ -118,7 +118,7 @@ export async function removeShopCart(id: number) {
export async function removeBatchShopCart(ids: number[]) { export async function removeBatchShopCart(ids: number[]) {
const res = await request.del<ApiResult<unknown>>( const res = await request.del<ApiResult<unknown>>(
'/shop/shop-cart/batch', '/shop/shop-cart/batch',
{ ids } ids
); );
if (res.code === 0) { if (res.code === 0) {
return res.message || '删除成功'; return res.message || '删除成功';