触发器参数 object 是 PintuanOrderMessage 对象,见第35行,直接转为 Pintuan 对象必为空,须要根据id重新查询
Signed-off-by: hucker520 <505169544@qq.com>
This commit is contained in:
parent
ae9e0e27ff
commit
6e820d745c
@ -25,6 +25,8 @@ public class PromotionTimeTriggerExecutor implements TimeTriggerExecutor {
|
||||
*/
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
@Autowired
|
||||
private PintuanService pintuanService;
|
||||
|
||||
|
||||
@Override
|
||||
@ -36,7 +38,7 @@ public class PromotionTimeTriggerExecutor implements TimeTriggerExecutor {
|
||||
//拼团订单自动处理
|
||||
orderService.agglomeratePintuanOrder(pintuanOrderMessage.getPintuanId(), pintuanOrderMessage.getOrderSn());
|
||||
}
|
||||
Pintuan pintuan = JSONUtil.toBean(JSONUtil.parseObj(object), Pintuan.class);
|
||||
Pintuan pintuan = pintuanService.getById(pintuanOrderMessage.getPintuanId());
|
||||
if (pintuan != null && pintuan.getId() != null) {
|
||||
this.orderService.checkFictitiousOrder(pintuan.getId(), pintuan.getRequiredNum(), pintuan.getFictitious());
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user