Browse Source

Merge remote-tracking branch 'remotes/origin/dev' into dev_heart

master
jianjun 5 years ago
parent
commit
d8d6ec6f20
  1. 2
      epmet-auth/deploy/docker-compose-dev.yml
  2. 2
      epmet-auth/pom.xml
  3. 25
      epmet-auth/src/main/java/com/epmet/service/impl/PublicUserLoginServiceImpl.java
  4. 2
      epmet-module/epmet-third/epmet-third-server/deploy/docker-compose-dev.yml
  5. 2
      epmet-module/epmet-third/epmet-third-server/pom.xml
  6. 2
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/controller/PaUserController.java
  7. 2
      epmet-module/oper-crm/oper-crm-server/deploy/docker-compose-dev.yml
  8. 2
      epmet-module/oper-crm/oper-crm-server/pom.xml
  9. 14
      epmet-module/oper-crm/oper-crm-server/src/main/java/com/epmet/service/impl/CustomerServiceImpl.java
  10. 2
      epmet-user/epmet-user-server/deploy/docker-compose-dev.yml
  11. 2
      epmet-user/epmet-user-server/pom.xml
  12. 1
      epmet-user/epmet-user-server/src/main/java/com/epmet/dao/UserBaseInfoDao.java
  13. 1
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/UserResiInfoServiceImpl.java

2
epmet-auth/deploy/docker-compose-dev.yml

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-auth-server:
container_name: epmet-auth-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-auth:0.3.58
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-auth:0.3.59
ports:
- "8081:8081"
network_mode: host # 使用现有网络

2
epmet-auth/pom.xml

@ -2,7 +2,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<version>0.3.58</version>
<version>0.3.59</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>epmet-cloud</artifactId>

25
epmet-auth/src/main/java/com/epmet/service/impl/PublicUserLoginServiceImpl.java

@ -162,13 +162,16 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
CheckPaUserFormDTO dto = new CheckPaUserFormDTO();
dto.setPhone(formDTO.getPhone());
dto.setSource(formDTO.getSource());
String url = ThirdApiConstant.THIRD_PAUSER_CHECKPAUSER;
Result<String> result = HttpClientManager.getInstance().sendPostByJSON(url, JSON.toJSONString(dto));
String data = HttpClientManager.getInstance().sendPostByJSON(ThirdApiConstant.THIRD_PAUSER_CHECKPAUSER, JSON.toJSONString(dto)).getData();
JSONObject toResult = JSON.parseObject(data);
Result result = ConvertUtils.mapToEntity(toResult, Result.class);
if (!result.success()) {
logger.error(String.format(SEND_SMS_CODE_ERROR, formDTO.getPhone(), result.getCode(), result.getMsg()));
throw new RenException(result.getCode());
}
CustomerUserResultDTO resultDTO = JSONObject.parseObject(result.getData(), CustomerUserResultDTO.class);
Object RegisterResult = result.getData();
JSONObject jsonObject = JSON.parseObject(RegisterResult.toString());
CustomerUserResultDTO resultDTO = ConvertUtils.mapToEntity(jsonObject, CustomerUserResultDTO.class);
//登陆
if (formDTO.getIsLogon() && null == resultDTO.getPaUserResult()) {
throw new RenException(EpmetErrorCode.PUBLIC_NOT_EXISTS.getCode());
@ -204,13 +207,16 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
CheckPaUserFormDTO dto = new CheckPaUserFormDTO();
dto.setPhone(formDTO.getPhone());
dto.setSource(formDTO.getSource());
String url = ThirdApiConstant.THIRD_PAUSER_CHECKPAUSER;
Result<String> result = HttpClientManager.getInstance().sendPostByJSON(url, JSON.toJSONString(dto));
String data = HttpClientManager.getInstance().sendPostByJSON(ThirdApiConstant.THIRD_PAUSER_CHECKPAUSER, JSON.toJSONString(dto)).getData();
JSONObject toResult = JSON.parseObject(data);
Result result = ConvertUtils.mapToEntity(toResult, Result.class);
if (!result.success()) {
logger.error(String.format("手机验证码登录异常,手机号[%s],code[%s],msg[%s]", formDTO.getPhone(), result.getCode(), result.getMsg()));
throw new RenException(result.getCode());
}
CustomerUserResultDTO resultDTO = JSONObject.parseObject(result.getData(), CustomerUserResultDTO.class);
Object RegisterResult = result.getData();
JSONObject jsonObject = JSON.parseObject(RegisterResult.toString());
CustomerUserResultDTO resultDTO = ConvertUtils.mapToEntity(jsonObject, CustomerUserResultDTO.class);
//2.用户不存在时不允许登陆
PaUserDTO userDTO = resultDTO.getPaUserResult();
@ -247,9 +253,10 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
visited.setLogonUserId(tokenDTO.getUserId());
visited.setPhone(formDTO.getPhone());
visited.setSource(formDTO.getSource());
String saveUserVisitedUrl = ThirdApiConstant.THIRD_PAUSERVISITED_SAVEUSERVISITED;
Result<String> visitedResult = HttpClientManager.getInstance().sendPostByJSON(saveUserVisitedUrl, JSON.toJSONString(visited));
if(!visitedResult.success()){
String data1 = HttpClientManager.getInstance().sendPostByJSON(ThirdApiConstant.THIRD_PAUSERVISITED_SAVEUSERVISITED, JSON.toJSONString(visited)).getData();
JSONObject json = JSON.parseObject(data1);
Result visitedResult = ConvertUtils.mapToEntity(json, Result.class);
if (!visitedResult.success()) {
logger.error(PublicUserLoginConstant.SAVE_VISITED_EXCEPTION);
}

2
epmet-module/epmet-third/epmet-third-server/deploy/docker-compose-dev.yml

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-third-server:
container_name: epmet-third-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-third-server:0.0.81
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-third-server:0.0.82
ports:
- "8110:8110"
network_mode: host # 使用现有网络

2
epmet-module/epmet-third/epmet-third-server/pom.xml

@ -2,7 +2,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<version>0.0.81</version>
<version>0.0.82</version>
<parent>
<groupId>com.epmet</groupId>

2
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/controller/PaUserController.java

@ -112,7 +112,7 @@ public class PaUserController {
* @Author sun
* @Description 根据手机号查询公众号用户基本信息校验用户是否存在
**/
@PostMapping(value = "/checkpauser/{phone}")
@PostMapping(value = "/checkpauser")
public Result<CustomerUserResultDTO> checkPaUser(@RequestBody CheckPaUserFormDTO formDTO) {
return new Result<CustomerUserResultDTO>().ok(paUserService.checkPaUser(formDTO));
}

2
epmet-module/oper-crm/oper-crm-server/deploy/docker-compose-dev.yml

@ -2,7 +2,7 @@ version: "3.7"
services:
oper-crm-server:
container_name: oper-crm-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/oper-crm-server:0.3.56
image: 192.168.1.130:10080/epmet-cloud-dev/oper-crm-server:0.3.57
ports:
- "8090:8090"
network_mode: host # 使用现有网络

2
epmet-module/oper-crm/oper-crm-server/pom.xml

@ -2,7 +2,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<version>0.3.56</version>
<version>0.3.57</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>oper-crm</artifactId>

14
epmet-module/oper-crm/oper-crm-server/src/main/java/com/epmet/service/impl/CustomerServiceImpl.java

@ -406,11 +406,16 @@ public class CustomerServiceImpl extends BaseServiceImpl<CustomerDao, CustomerEn
public void init(CustomerInitFormDTO formDTO) {
//1.调用epmet-third服务,根据客户Id查询第三方服务中的客户、组织、管理员等信息
String url = "https://epmet-cloud.elinkservice.cn/api/third/pacustomer/getcustomeragencyuser/" + formDTO.getCustomerId();
Result<String> thirdResult = HttpClientManager.getInstance().sendPostByJSON(url, null);
String data = HttpClientManager.getInstance().sendPostByJSON(url, null).getData();
JSONObject toResult = JSON.parseObject(data);
Result thirdResult = ConvertUtils.mapToEntity(toResult, Result.class);
if (!thirdResult.success()) {
throw new RenException(thirdResult.getCode(), thirdResult.getInternalMsg());
}
InitCustomerResultDTO initCustomer = JSONObject.parseObject(thirdResult.getData(), InitCustomerResultDTO.class);
Object RegisterResult = thirdResult.getData();
JSONObject jsonObject = JSON.parseObject(RegisterResult.toString());
InitCustomerResultDTO initCustomer = ConvertUtils.mapToEntity(jsonObject, InitCustomerResultDTO.class);
PaCustomerDTO paCustomer = initCustomer.getPaCustomer();
PaCustomerAgencyDTO paAgency = initCustomer.getPaAgency();
PaUserDTO paUser = initCustomer.getPaUser();
@ -491,11 +496,14 @@ public class CustomerServiceImpl extends BaseServiceImpl<CustomerDao, CustomerEn
//6.更新第三方数据库中客户数据状态为已初始化
String customerUrl = "https://epmet-cloud.elinkservice.cn/api/third/pacustomer/updatecustomer/" + formDTO.getCustomerId();
Result<String> customerResult = HttpClientManager.getInstance().sendPostByJSON(customerUrl, null);
String data1 = HttpClientManager.getInstance().sendPostByJSON(customerUrl, null).getData();
JSONObject json = JSON.parseObject(data1);
Result customerResult = ConvertUtils.mapToEntity(json, Result.class);
if (!customerResult.success()) {
throw new RenException(customerResult.getCode(), customerResult.getInternalMsg());
}
}
}

2
epmet-user/epmet-user-server/deploy/docker-compose-dev.yml

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-user-server:
container_name: epmet-user-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-user-server:0.3.97
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-user-server:0.3.100
ports:
- "8087:8087"
network_mode: host # 不会创建新的网络

2
epmet-user/epmet-user-server/pom.xml

@ -2,7 +2,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<version>0.3.97</version>
<version>0.3.100</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>epmet-user</artifactId>

1
epmet-user/epmet-user-server/src/main/java/com/epmet/dao/UserBaseInfoDao.java

@ -18,7 +18,6 @@
package com.epmet.dao;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.result.ResiUserBaseInfoResultDTO;
import com.epmet.dto.result.UserBaseInfoResultDTO;
import com.epmet.dto.result.UserWechatResultDTO;

1
epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/UserResiInfoServiceImpl.java

@ -154,7 +154,6 @@ public class UserResiInfoServiceImpl extends BaseServiceImpl<UserResiInfoDao, Us
/**
* 居民注册信息提交
*
* @param userResiInfoDTO
* @Author sunUserRoleServiceImpl
*/

Loading…
Cancel
Save