Commit 5cf52b95 by 周晓航

预约单配置校验

Signed-off-by: 周晓航 <xiaohang.zhou@freemud.com>
parent e9a97813
......@@ -38,6 +38,10 @@ public class BusinessInfoDto {
private Integer deliveryProcessingAfterMinute;
private Integer deliveryProcessingBeforeMinute;
private Integer orderProgressBarStatus;
/**
* 是否开启 预定单功能 1开 0关
*/
private Integer preOrderSwitch;
private ExpandFields expandFields;
......
......@@ -71,6 +71,7 @@ public enum ResponseResult {
STORE_DDELIVERY_METHOD("43021", "获取门店外卖配送方式异常",""),
STORE_QUERYEXPECTARRIVETIME("43022", "获取门店计算预计送达时间失败",""),
STORE_DATE_ERROR("43023", "门店数据错误",""),
STORE_ITEM_NOT_ADVANCE("43024", "门店未开启预约单配置",""),
/**
* 购物车状态码
......
......@@ -408,9 +408,16 @@ public class CheckOrder {
*/
private void checkAdvanceOrderExpectTime(BusinessInfoDto queryBusinessInfoNew) {
// fisherman-ka 预定单的校验 未完成
// 伪代码 判断 门店是否开启了 预定单服务
// 开启了预定单服务, 不走下面的检验
if (Objects.isNull(queryBusinessInfoNew)) {
return;
}
if (!Objects.equals(queryBusinessInfoNew.getPreOrderSwitch(),1)) {
// 没开启 抛出异常
throw new ServiceException(ResponseResult.STORE_ITEM_NOT_ADVANCE);
}
// 时间范围校验
// 营业结束前校验
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment