记得上下班打卡 | git大法好,push需谨慎

Commit 9095a716 authored by 张国柄's avatar 张国柄

券码兑换券+同步ucoupon_id;

parent 66930250
...@@ -39,10 +39,16 @@ public class CandyCouponCode implements Serializable { ...@@ -39,10 +39,16 @@ public class CandyCouponCode implements Serializable {
*/ */
private Integer state; private Integer state;
/**
* ~candy_user_coupon.ucoupon_id
*/
private String ucouponId;
/** /**
* 兑换用户UID * 兑换用户UID
*/ */
private String redeemUid; private String redeemUid;
/** /**
* 兑换用户手机号 * 兑换用户手机号
*/ */
......
...@@ -485,7 +485,7 @@ public class CandyCouponServiceImpl implements ICandyCouponService { ...@@ -485,7 +485,7 @@ public class CandyCouponServiceImpl implements ICandyCouponService {
toMqSqls.add(SqlMapping.get("candy_coupon.receive")); toMqSqls.add(SqlMapping.get("candy_coupon.receive"));
objsUserCoupon.add(new Object[]{uCouponId, uid, 1, infoDto.getCouponId(), ccode, now, now, infoDto.getExpireAt()}); objsUserCoupon.add(new Object[]{uCouponId, uid, 1, infoDto.getCouponId(), ccode, now, now, infoDto.getExpireAt()});
toMqSqls.add(SqlMapping.get("candy_coupon_code.receive"));// state:状态[0-可用|1-已用] toMqSqls.add(SqlMapping.get("candy_coupon_code.receive"));// state:状态[0-可用|1-已用]
objsCouponCode.add(new Object[]{1, uid, mobile, now, now, dto.getCouponId(), ccode}); objsCouponCode.add(new Object[]{1, uCouponId, uid, mobile, now, now, dto.getCouponId(), ccode});
queueUtils.sendMsgByRedis( queueUtils.sendMsgByRedis(
MQConst.CandyQueue.COUPON_RECEIVE.getKey(), MQConst.CandyQueue.COUPON_RECEIVE.getKey(),
SqlMapping.gets(toMqSqls, objsUserCoupon, objsCouponCode) SqlMapping.gets(toMqSqls, objsUserCoupon, objsCouponCode)
......
...@@ -6,4 +6,4 @@ candy_coupon.use_insert=INSERT INTO candy_user_coupon (ucoupon_id , uid , state ...@@ -6,4 +6,4 @@ candy_coupon.use_insert=INSERT INTO candy_user_coupon (ucoupon_id , uid , state
candy_coupon.back=UPDATE candy_user_coupon SET state = 1 WHERE uid = ? AND ucoupon_id = ? candy_coupon.back=UPDATE candy_user_coupon SET state = 1 WHERE uid = ? AND ucoupon_id = ?
# -- 领取券 -- # -- 领取券 --
candy_coupon.receive=INSERT INTO candy_user_coupon (ucoupon_id , uid , state , coupon_id , ccode , bind_at , created_at , dued_at) VALUE ( ? , ? , ? , ? , ? , ? , ? , ?) candy_coupon.receive=INSERT INTO candy_user_coupon (ucoupon_id , uid , state , coupon_id , ccode , bind_at , created_at , dued_at) VALUE ( ? , ? , ? , ? , ? , ? , ? , ?)
candy_coupon_code.receive=UPDATE candy_coupon_code SET state=?,redeem_uid=?,redeem_mobile=?,redeem_at=?,updated_at=? WHERE coupon_id=? AND ccode=? candy_coupon_code.receive=UPDATE candy_coupon_code SET state=?,ucoupon_id=?,redeem_uid=?,redeem_mobile=?,redeem_at=?,updated_at=? WHERE coupon_id=? AND ccode=?
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment