Files
xinlong-shop-taro/.workbuddy/memory/2026-06-25.md
赵忠林 44ca5bbbfc feat(shop): 添加商品详情页轮播图点击放大预览功能
- 在 src/pages/shop/product-detail.tsx 的轮播图 Image 上添加 onClick 事件
- 使用 Taro.previewImage 实现图片全屏预览和左右滑动浏览
- 同样在 src/pages/points/product-detail.tsx 商品图片添加点击预览功能
- 新增完整的 shop-api 秒杀模块,包含实体、参数、mapper、service、controller 和定时任务
- 实现防重复提交、活动校验、限购校验和原子扣库存的秒杀核心下单逻辑
- 提供管理端 CRUD 与用户端秒杀订单相关接口
- 引入定时任务 SeckillStatusTask 定时更新秒杀活动状态
- 添加秒杀模块相关数据库建表脚本和接口路径对齐前端设计
2026-06-26 22:25:07 +08:00

25 lines
1.6 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 2026-06-25 工作日志
## 商品详情页图片不显示修复
- **文件**: `src/pages/shop/product-detail.tsx`
- **问题**: 商品详情区域 `product.content` 包含 Markdown 图片语法(`![alt](url)`),微信小程序的 `RichText` 组件不支持 Markdown导致原样输出文本而非渲染图片
- **修复**: 新增 `parseContent()` 函数,将 Markdown 图片语法转为 `<img>` HTML 标签,同时兜底处理裸 URL 图片链接
- **构建状态**: 编译通过 ✓
## weiyu-taro 项目同步修复
- **文件**: `/Users/gxwebsoft/VUE/weiyu-taro/src/pages/shop/product-detail.tsx`
- 同样缺少 Markdown 图片语法转 HTML 的 `parseContent()` 函数,已同步添加
- 与 xinlong-shop-taro 修复方案完全一致
## shop-api 后端秒杀模块实现
- **项目路径**: `/Users/gxwebsoft/JAVA/shop-api`
- 新增完整的秒杀后端模块,参考 ShopGoods 四层架构模板
- **Entity**: ShopSeckill.java + ShopSeckillOrder.java含 tenantId 多租户)
- **Param**: ShopSeckillParam.java
- **Mapper**: ShopSeckillMapper + ShopSeckillOrderMapper + XML含原子扣库存 SQL
- **Service**: ShopSeckillServiceImpl核心下单逻辑防重复提交→活动校验→限购校验→原子扣库存→创建订单→Redis记录已购
- **Controller**: ShopSeckillController管理端 CRUD + 用户端 createOrder/myOrders/timeSlots
- **定时任务**: SeckillStatusTask每60秒自动更新过期秒杀状态
- **建表SQL**: src/main/resources/sql/shop_seckill.sql
- API 路径 `/api/shop/shopSeckill`,与前端 `/shopSeckill/*` 对齐