提交 8e96503b authored 作者: 吕本才's avatar 吕本才

提交数据时,增加轮次结束配置,区分查询和提交的配置

上级 46eb7811
......@@ -171,4 +171,5 @@ public class Constants
public static final String[] JOB_ERROR_STR = { "java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml",
"org.springframework", "org.apache", "com.ruoyi.common.utils.file", "com.ruoyi.common.config", "com.ruoyi.generator" };
public static final String DEALER_ROUND = "dealer.round";
public static final String DEALER_ROUND_OVER = "dealer.round.over";
}
......@@ -45,9 +45,9 @@ public class DealerRoundInfoServiceImpl extends ServiceImpl<DealerRoundInfoMappe
@Override
public int saveRoundInfo(WechatDealerRoundInfoReq dealerRoundInfoReq) {
String config = configService.selectConfigByKeyFromDb(Constants.DEALER_ROUND);
Integer round = Integer.parseInt(config);
if (round <= 0) {
String config = configService.selectConfigByKeyFromDb(Constants.DEALER_ROUND_OVER);
Boolean round = Boolean.parseBoolean(config);
if (round) {
throw new ServiceException("当前轮次活动已经结束");
}
Long userId = SecurityUtils.getUserId();
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论