|
@@ -5,6 +5,7 @@ import com.alibaba.fastjson.JSONObject;
|
|
import com.caimei365.user.components.CommonService;
|
|
import com.caimei365.user.components.CommonService;
|
|
import com.caimei365.user.components.WeChatService;
|
|
import com.caimei365.user.components.WeChatService;
|
|
import com.caimei365.user.mapper.LoginMapper;
|
|
import com.caimei365.user.mapper.LoginMapper;
|
|
|
|
+import com.caimei365.user.mapper.OperationMapper;
|
|
import com.caimei365.user.mapper.RegisterMapper;
|
|
import com.caimei365.user.mapper.RegisterMapper;
|
|
import com.caimei365.user.model.ResponseJson;
|
|
import com.caimei365.user.model.ResponseJson;
|
|
import com.caimei365.user.model.dto.AuthBindDto;
|
|
import com.caimei365.user.model.dto.AuthBindDto;
|
|
@@ -44,6 +45,8 @@ public class LoginServiceImpl implements LoginService {
|
|
private LoginMapper loginMapper;
|
|
private LoginMapper loginMapper;
|
|
@Resource
|
|
@Resource
|
|
private RegisterMapper registerMapper;
|
|
private RegisterMapper registerMapper;
|
|
|
|
+ @Resource
|
|
|
|
+ private OperationMapper operationMapper;
|
|
|
|
|
|
/**
|
|
/**
|
|
* 小程序邀请码过期天数
|
|
* 小程序邀请码过期天数
|
|
@@ -231,12 +234,12 @@ public class LoginServiceImpl implements LoginService {
|
|
return ResponseJson.error("您的微信尚未绑定任何机构", operation);
|
|
return ResponseJson.error("您的微信尚未绑定任何机构", operation);
|
|
} else {
|
|
} else {
|
|
// 表示 openId存在, unionId不存在
|
|
// 表示 openId存在, unionId不存在
|
|
- loginMapper.updateOperationUnionId(operation.getUserId(), unionId);
|
|
|
|
|
|
+ operationMapper.updateOperationUnionId(operation.getUserId(), unionId);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// 如果unionId存在, openId不存在
|
|
// 如果unionId存在, openId不存在
|
|
if (StringUtils.isEmpty(operation.getOpenId()) || StringUtils.isBlank(operation.getOpenId())) {
|
|
if (StringUtils.isEmpty(operation.getOpenId()) || StringUtils.isBlank(operation.getOpenId())) {
|
|
- loginMapper.updateOperationOpenId(operation.getUserId(), openId);
|
|
|
|
|
|
+ operationMapper.updateOperationOpenId(operation.getUserId(), openId);
|
|
}
|
|
}
|
|
operation.setOpenId(openId);
|
|
operation.setOpenId(openId);
|
|
operation.setUnionId(unionId);
|
|
operation.setUnionId(unionId);
|
|
@@ -422,7 +425,7 @@ public class LoginServiceImpl implements LoginService {
|
|
operationPo.setUserType(2);
|
|
operationPo.setUserType(2);
|
|
}
|
|
}
|
|
// 更新运营人员信息
|
|
// 更新运营人员信息
|
|
- loginMapper.updateOperationByInvitation(operationPo);
|
|
|
|
|
|
+ operationMapper.updateOperationByInvitation(operationPo);
|
|
// 返回登录校验结果
|
|
// 返回登录校验结果
|
|
return logonVerify(operation);
|
|
return logonVerify(operation);
|
|
}
|
|
}
|
|
@@ -529,8 +532,6 @@ public class LoginServiceImpl implements LoginService {
|
|
registerMapper.insertOperation(operation);
|
|
registerMapper.insertOperation(operation);
|
|
return ResponseJson.success("绑定微信成功", user);
|
|
return ResponseJson.success("绑定微信成功", user);
|
|
}
|
|
}
|
|
-
|
|
|
|
-
|
|
|
|
/**
|
|
/**
|
|
* 解绑运营人员
|
|
* 解绑运营人员
|
|
*
|
|
*
|
|
@@ -547,6 +548,6 @@ public class LoginServiceImpl implements LoginService {
|
|
operation.setStatus(1);
|
|
operation.setStatus(1);
|
|
operation.setDelFlag(1);
|
|
operation.setDelFlag(1);
|
|
// 解绑运营人员
|
|
// 解绑运营人员
|
|
- loginMapper.updateOperationByUnbind(operation);
|
|
|
|
|
|
+ operationMapper.updateOperationByUnbind(operation);
|
|
}
|
|
}
|
|
}
|
|
}
|