2
This commit is contained in:
@@ -133,12 +133,15 @@ class CouponService extends BaseService
|
||||
}
|
||||
|
||||
// 添加优惠卷过期队列
|
||||
$valid_end_time = strtotime($user_coupon['valid_start_time']);
|
||||
$valid_end_time = strtotime($user_coupon['valid_end_time']);
|
||||
|
||||
$data = array();
|
||||
$data['user_coupon_id'] = $user_coupon['user_coupon_id'];
|
||||
|
||||
$time = $valid_end_time - time();
|
||||
if ($time < 0){
|
||||
return false;
|
||||
}
|
||||
$message = new UserCouponExpiredDelayDirectProducer($data);
|
||||
$message->setDelayMs(1000 * $time);
|
||||
$producer = $this->container->get(Producer::class);
|
||||
|
||||
Reference in New Issue
Block a user