| | |
| | | import com.yeshi.fanli.dao.mybatis.user.UserInfoModifyRecordMapper;
|
| | | import com.yeshi.fanli.dto.mq.user.UserTopicTagEnum;
|
| | | import com.yeshi.fanli.dto.mq.user.body.UserAccountBindingMQMsg;
|
| | | import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
|
| | | import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg.UserInfoUpdateTypeEnum;
|
| | | import com.yeshi.fanli.entity.bus.user.BindingAccount;
|
| | | import com.yeshi.fanli.entity.bus.user.UserExtraTaoBaoInfo;
|
| | | import com.yeshi.fanli.entity.bus.user.UserInfo;
|
| | |
| | | import com.yeshi.fanli.service.inter.user.tb.UserExtraTaoBaoInfoService;
|
| | | import com.yeshi.fanli.util.Constant;
|
| | | import com.yeshi.fanli.util.StringUtil;
|
| | | import com.yeshi.fanli.util.rocketmq.MQMsgBodyFactory;
|
| | | import com.yeshi.fanli.util.rocketmq.MQTopicName;
|
| | |
|
| | | @Service
|
| | |
| | | mqMsg = new UserAccountBindingMQMsg(uid, UserAccountBindingMQMsg.TYPE_ALIPAY, value,
|
| | | new Date());
|
| | | }
|
| | | Message message = new Message(MQTopicName.TOPIC_USER.name(),
|
| | | UserTopicTagEnum.userAccountBinding.name(), new Gson().toJson(mqMsg).getBytes());
|
| | | producer.send(message);
|
| | | Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER,
|
| | | UserTopicTagEnum.userAccountBinding, mqMsg);
|
| | | if (!Constant.IS_TEST)
|
| | | producer.send(message);
|
| | | } else {// 修改
|
| | | UserInfoUpdateMQMsg mqMsg = null;
|
| | |
|
| | | if (type == ModifyTypeEnum.portrait) {
|
| | | mqMsg = new UserInfoUpdateMQMsg(uid, UserInfoUpdateTypeEnum.portrait, value, new Date());
|
| | | } else if (type == ModifyTypeEnum.nickName)
|
| | | mqMsg = new UserInfoUpdateMQMsg(uid, UserInfoUpdateTypeEnum.nickName, value, new Date());
|
| | | else if (type == ModifyTypeEnum.setWeiXinNum)
|
| | | mqMsg = new UserInfoUpdateMQMsg(uid, UserInfoUpdateTypeEnum.wxId, value, new Date());
|
| | |
|
| | | if (mqMsg != null) {
|
| | | Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER,
|
| | | UserTopicTagEnum.userInfoUpdate, mqMsg);
|
| | | producer.send(message);
|
| | | }
|
| | | }
|
| | | }
|
| | | } catch (Exception e) {
|