feat(pricing): 添加一口价购买功能

- 新增 OnePricePurchaseController 控制器
- 新增 OnePriceConfigFilterRequest、OnePriceConfigRequest、OnePriceInfo等 DTO 类
- 新增 PriceOnePriceConfig 实体类和对应的 Mapper 接口
- 实现 OnePricePurchaseDiscountProvider 优惠提供者
- 实现 OnePricePurchaseServiceImpl 服务实现类
-定义 IOnePricePurchaseService服务接口
- 优化 DiscountDetail 类,添加创建一口价折扣的方法
- 修改 CLAUDE.md,将 error 方法改为 fail 方法
This commit is contained in:
2025-09-05 11:09:54 +08:00
parent 5210b50adb
commit 50c84ac1c9
11 changed files with 1104 additions and 2 deletions

View File

@@ -239,7 +239,7 @@ public class PriceCalculationException extends RuntimeException {
// 在PricingExceptionHandler中统一处理
@ExceptionHandler(PriceCalculationException.class)
public ApiResponse<String> handlePriceCalculationException(PriceCalculationException e) {
return ApiResponse.error(ErrorCode.PRICE_CALCULATION_ERROR, e.getMessage());
return ApiResponse.fail(ErrorCode.PRICE_CALCULATION_ERROR, e.getMessage());
}
```