调整
This commit is contained in:
parent
c6cc09916b
commit
6a33d03344
@ -39,9 +39,6 @@ public class WeChatServiceImpl implements WeChatService {
|
|||||||
@Value("${weChat.secret}")
|
@Value("${weChat.secret}")
|
||||||
private String secret;
|
private String secret;
|
||||||
|
|
||||||
@Value("${spring.profiles.active}")
|
|
||||||
private String active;
|
|
||||||
|
|
||||||
@Autowired private QrCodeUtil qrCodeUtil;
|
@Autowired private QrCodeUtil qrCodeUtil;
|
||||||
@Autowired private BusUserMapper BusUserMapper;
|
@Autowired private BusUserMapper BusUserMapper;
|
||||||
@Autowired private RestTemplateUtils restTemplateUtil;
|
@Autowired private RestTemplateUtils restTemplateUtil;
|
||||||
@ -68,13 +65,9 @@ public class WeChatServiceImpl implements WeChatService {
|
|||||||
@Override
|
@Override
|
||||||
public LoginVo authorizeLogin(String code, HttpServletRequest request) {
|
public LoginVo authorizeLogin(String code, HttpServletRequest request) {
|
||||||
LoginVo loginVo = new LoginVo();
|
LoginVo loginVo = new LoginVo();
|
||||||
WeChatMiniAuthorizeVo response = null;
|
WeChatMiniAuthorizeVo response = miniAuthCode(code);
|
||||||
if (!active.equals("local")) {
|
// WeChatMiniAuthorizeVo response = new WeChatMiniAuthorizeVo();
|
||||||
response = miniAuthCode(code);
|
// response.setOpenId("123456");
|
||||||
} else {
|
|
||||||
response = new WeChatMiniAuthorizeVo();
|
|
||||||
response.setOpenId("123456");
|
|
||||||
}
|
|
||||||
String openId = response.getOpenId();
|
String openId = response.getOpenId();
|
||||||
String type = "login";
|
String type = "login";
|
||||||
BusUser busUser = BusUserMapper.getUserByOpenId(openId);
|
BusUser busUser = BusUserMapper.getUserByOpenId(openId);
|
||||||
|
Loading…
Reference in New Issue
Block a user