|
|
@ -74,29 +74,29 @@ public class HighOrderSchedule { |
|
|
|
* @Param [] |
|
|
|
* @Param [] |
|
|
|
* @return void |
|
|
|
* @return void |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Scheduled(cron="0 0/10 * * * ?") //每 10分钟执行一次
|
|
|
|
// @Scheduled(cron="0 0/10 * * * ?") //每 10分钟执行一次
|
|
|
|
public void integralRebateOrder() { |
|
|
|
// public void integralRebateOrder() {
|
|
|
|
|
|
|
|
//
|
|
|
|
// 查询满足初步返利条件订单
|
|
|
|
// // 查询满足初步返利条件订单
|
|
|
|
List<HighOrder> order = highOrderService.integralRebateOrder(); |
|
|
|
// List<HighOrder> order = highOrderService.integralRebateOrder();
|
|
|
|
for (HighOrder highOrder : order) { |
|
|
|
// for (HighOrder highOrder : order) {
|
|
|
|
|
|
|
|
//
|
|
|
|
// 查询是否存在积分记录
|
|
|
|
// // 查询是否存在积分记录
|
|
|
|
Map<String, Object> map = new HashMap<>(); |
|
|
|
// Map<String, Object> map = new HashMap<>();
|
|
|
|
map.put("goldType", 1); |
|
|
|
// map.put("goldType", 1);
|
|
|
|
map.put("resType", 4); |
|
|
|
// map.put("resType", 4);
|
|
|
|
map.put("userId", highOrder.getMemId()); |
|
|
|
// map.put("userId", highOrder.getMemId());
|
|
|
|
map.put("resId", highOrder.getId()); |
|
|
|
// map.put("resId", highOrder.getId());
|
|
|
|
|
|
|
|
//
|
|
|
|
List<HighGoldRec> goldRecs = highGoldRecService.getGoldRec(map); |
|
|
|
// List<HighGoldRec> goldRecs = highGoldRecService.getGoldRec(map);
|
|
|
|
|
|
|
|
//
|
|
|
|
// 判断是否重复赠送积分
|
|
|
|
// // 判断是否重复赠送积分
|
|
|
|
if (goldRecs.size() == 0) { |
|
|
|
// if (goldRecs.size() == 0) {
|
|
|
|
bsOrderRebateService.insertOrderRebate(highOrder); |
|
|
|
// bsOrderRebateService.insertOrderRebate(highOrder);
|
|
|
|
} |
|
|
|
// }
|
|
|
|
|
|
|
|
//
|
|
|
|
} |
|
|
|
// }
|
|
|
|
} |
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|