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

Commit 62b9761a authored by jiangxiulong's avatar jiangxiulong

remind 去掉redis

parent dfd9a8a9
......@@ -15,8 +15,6 @@ public class SweetConstant {
public final static String REDIS_KEY_SWEET_SHOP = "sweet:artists:shop:manual:";
public final static String REDIS_KEY_SWEET_LUCK_DRAW = "sweet:artists:luckDraw:uid:";
public final static String REDIS_KEY_SWEET_REMIND="sweet:remind:unionId:";
public final static String REDIS_KEY_SWEET_WECHAT_USER_INFO="sweet:wechatUser:unionId:";
public final static String REDIS_KEY_SWEET_WECHAT_USER_UNIONID="sweet:wechatUser:openId:";
public final static String REDIS_KEY_SWEET_ANSWER_PHONE="sweet:answer:phone:";
......
......@@ -67,7 +67,7 @@ public class UnsubscribeHandler implements WxMpMessageHandler {
});
queueUtils.sendMsgByRedis(MQConst.SweetQueue.SWEET_USER_INSERT_DRAW.getKey(),
SqlMapping.gets(sqls, sqlsDataA));
redisDataUtils.delSweetWechatUser(sweetWechatUserUnionid);
redisDataUtils.delSweetWechatUser(sweetWechatUserUnionid, wxMpUser.getOpenId());
}
}
return null;
......
......@@ -305,7 +305,6 @@ public class RedisDataUtils {
// 小程序演出提醒
public void setSweetRemind(String openId, String unionId, String performancesId) {
String redisKey = SweetConstant.REDIS_KEY_SWEET_REMIND.concat(unionId);
SweetRemindVo sweetRemindVo = SweetRemindVo.getNew();
sweetRemindVo.setRemindId(IDGenerator.nextSnowId());
sweetRemindVo.setCreatedAt(DateUtil.getNowTime());
......@@ -322,19 +321,6 @@ public class RedisDataUtils {
});
queueUtils.sendMsgByRedis(MQConst.SweetQueue.SWEET_REMIND_INSERT_DRAW.getKey(),
SqlMapping.gets(sqls, sqlsDataA));
// if (null != performanceInfo) {
// sweetRemindVo.setFieldName(performanceInfo.getFieldName());
// sweetRemindVo.setTitle(performanceInfo.getTitle());
// sweetRemindVo.setTimeStart(performanceInfo.getTimeStart());
// sweetRemindVo.setSellTime(performanceInfo.getSellTime());
// }
redisUtil.set(redisKey, sweetRemindVo);
}
public void delSweetRemind(String unionId) {
String redisKey = SweetConstant.REDIS_KEY_SWEET_REMIND.concat(unionId);
redisUtil.del(redisKey);
}
// 正在现场服务号关注事件储存用户信息
......@@ -358,10 +344,12 @@ public class RedisDataUtils {
String redisKey = SweetConstant.REDIS_KEY_SWEET_WECHAT_USER_INFO.concat(unionid);
return (SweetWechatUser) redisUtil.get(redisKey);
}
public void delSweetWechatUser(String unionid) {
public void delSweetWechatUser(String unionid, String openid) {
if (!unionid.isEmpty()) {
String redisKey = SweetConstant.REDIS_KEY_SWEET_WECHAT_USER_INFO.concat(unionid);
redisUtil.del(redisKey);
String redisKeyUnid = SweetConstant.REDIS_KEY_SWEET_WECHAT_USER_UNIONID.concat(openid);
redisUtil.del(redisKeyUnid);
}
}
......
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