已使用的优惠卷还要 endtime 判断吗
这个代码看的我很困惑
@Query("select c From Coupon c\n" +
"join UserCoupon uc\n" +
"on c.id = uc.couponId\n" +
"join User u\n" +
"on u.id = uc.userId\n" +
"where u.id = :uid\n" +
"and uc.status = 2\n" +
"and uc.orderId is not null \n" +
"and c.startTime < :now\n" +
"and c.endTime > :now")
这个 endTime 的判断不需要的了把?
40
收起
恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧
0 星