|
@@ -20,10 +20,7 @@ import com.cyksj.dto.Result;
|
|
|
import com.cyksj.enums.GatewayResponse;
|
|
import com.cyksj.enums.GatewayResponse;
|
|
|
import com.cyksj.mapper.PhoneCodeMapper;
|
|
import com.cyksj.mapper.PhoneCodeMapper;
|
|
|
import com.cyksj.mapper.manage.cps.UserDistributePopularizeMapper;
|
|
import com.cyksj.mapper.manage.cps.UserDistributePopularizeMapper;
|
|
|
-import com.cyksj.model.dto.AuthRedirect;
|
|
|
|
|
-import com.cyksj.model.dto.AuthToken;
|
|
|
|
|
-import com.cyksj.model.dto.GzhOAuth2UserInfo;
|
|
|
|
|
-import com.cyksj.model.dto.JsSdkTicket;
|
|
|
|
|
|
|
+import com.cyksj.model.dto.*;
|
|
|
import com.cyksj.model.entity.PhoneCode;
|
|
import com.cyksj.model.entity.PhoneCode;
|
|
|
import com.cyksj.model.entity.User;
|
|
import com.cyksj.model.entity.User;
|
|
|
import com.cyksj.model.entity.UserDistributePopularize;
|
|
import com.cyksj.model.entity.UserDistributePopularize;
|
|
@@ -455,6 +452,14 @@ public class AuthorizationController {
|
|
|
if (sharedId != null) {
|
|
if (sharedId != null) {
|
|
|
distributeService.saveDistributionInvitation(sharedId, user.getId(), dsPopularizeId);
|
|
distributeService.saveDistributionInvitation(sharedId, user.getId(), dsPopularizeId);
|
|
|
}
|
|
}
|
|
|
|
|
+ //缓存用户注册 回传信息
|
|
|
|
|
+ if (StrUtil.isNotBlank(loginReq.getCallback())) {
|
|
|
|
|
+ OrderDonPostDataDto orderDonPostDataDto = new OrderDonPostDataDto()
|
|
|
|
|
+ .setUserId(user.getId())
|
|
|
|
|
+ .setCallback(loginReq.getCallback())
|
|
|
|
|
+ .setCallbackType(loginReq.getCallbackType());
|
|
|
|
|
+ redisService.set(RedisService.key.ORDER_DON_POST_DATA_USER_KEY.getName() + user.getId(), Jsons.toJson(orderDonPostDataDto));
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
//写回登陆信息
|
|
//写回登陆信息
|
|
|
StpUserUtil.login(user.getId());
|
|
StpUserUtil.login(user.getId());
|
|
@@ -473,7 +478,7 @@ public class AuthorizationController {
|
|
|
String json = Codec.DoBase64.custom().setData(state).decodeAsText();
|
|
String json = Codec.DoBase64.custom().setData(state).decodeAsText();
|
|
|
AuthRedirect re = Jsons.parseObject(json, AuthRedirect.class);
|
|
AuthRedirect re = Jsons.parseObject(json, AuthRedirect.class);
|
|
|
//保存用户信息
|
|
//保存用户信息
|
|
|
- User user = userService.saveAuth(userinfo, re.getSharedId(), re.getDsType(), re.getPid(), registerEnv, re.getDsCode());
|
|
|
|
|
|
|
+ User user = userService.saveAuth(userinfo, re.getSharedId(), re.getDsType(), re.getPid(), registerEnv, re.getDsCode(), re.getCallback(), re.getCallbackType());
|
|
|
if (user == null) {
|
|
if (user == null) {
|
|
|
throw BusinessRuntimeException.getInstance("系统错误,请重新授权");
|
|
throw BusinessRuntimeException.getInstance("系统错误,请重新授权");
|
|
|
}
|
|
}
|