1.消息推送fix

This commit is contained in:
SongZhang 2024-08-09 16:45:53 +08:00
parent 7f8a658143
commit 538fc8f91b
1 changed files with 11 additions and 0 deletions

View File

@ -65,6 +65,17 @@ public class LoginService {
}
public void addShopId(String openId, String shopId, Integer type, String nickName, String avatar) {
TbUserShopMsg shopMsg = tbUserShopMsgMapper.selectByShopIdAndOpenId(Integer.valueOf(shopId), openId);
if (Objects.isNull(shopMsg)) {
shopMsg = new TbUserShopMsg();
shopMsg.setShopId(Integer.valueOf(shopId));
shopMsg.setOpenId(openId);
shopMsg.setCreateTime(new Date());
shopMsg.setStatus("1");
tbUserShopMsgMapper.insert(shopMsg);
}
// 为商家绑定openid
TbShopOpenId tbShopOpenId = shopOpenIdMapper.countByOpenId(openId, Integer.valueOf(shopId), type);
if (tbShopOpenId == null) {