| @@ -114,8 +114,8 @@ public class WxUserGrantController extends BaseController { | |||||
| String openId = null; | String openId = null; | ||||
| String unionId = null; | String unionId = null; | ||||
| WxAppinfo wxAppinfo = wxAppinfoServie.getCAppInfoFromRedis(appId); | |||||
| try { | try { | ||||
| WxAppinfo wxAppinfo = wxAppinfoServie.getCAppInfoFromRedis(appId); | |||||
| WxMaJscode2SessionResult session = wxWeappService.jsCode2SessionInfo(code, wxAppinfo, false); | WxMaJscode2SessionResult session = wxWeappService.jsCode2SessionInfo(code, wxAppinfo, false); | ||||
| logger.info("sessionResult: " + session); | logger.info("sessionResult: " + session); | ||||
| if (null != session) { | if (null != session) { | ||||
| @@ -147,6 +147,7 @@ public class WxUserGrantController extends BaseController { | |||||
| cUser = new WxCUser(); | cUser = new WxCUser(); | ||||
| cUser.setOpenId(openId); | cUser.setOpenId(openId); | ||||
| cUser.setUnionId(unionId); | cUser.setUnionId(unionId); | ||||
| cUser.updateTenantInfo(wxAppinfo); | |||||
| wxCUserService.saveOrUpdate(cUser); | wxCUserService.saveOrUpdate(cUser); | ||||
| } | } | ||||
| WxCUserCache.cacheApp(objectCommonRedisTemplate, cUser); | WxCUserCache.cacheApp(objectCommonRedisTemplate, cUser); | ||||