Browse Source

Merge branches 'dev' and 'dev_heart' of http://git.elinkit.com.cn:7070/r/epmet-cloud into dev_heart

master
yinzuomei 5 years ago
parent
commit
fccad9752c
  1. 17
      epmet-auth/src/main/java/com/epmet/service/impl/PublicUserLoginServiceImpl.java
  2. 2
      epmet-gateway/deploy/docker-compose-dev.yml
  3. 2
      epmet-gateway/pom.xml
  4. 2
      epmet-module/epmet-heart/epmet-heart-server/deploy/docker-compose-dev.yml
  5. 2
      epmet-module/epmet-heart/epmet-heart-server/pom.xml
  6. 2
      epmet-module/epmet-point/epmet-point-server/deploy/docker-compose-dev.yml
  7. 2
      epmet-module/epmet-point/epmet-point-server/pom.xml
  8. 5
      epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/CodeCustomerDTO.java
  9. 4
      epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/form/UploadListFormDTO.java
  10. 6
      epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/result/CustomerUserResultDTO.java
  11. 6
      epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/result/InitCustomerResultDTO.java
  12. 2
      epmet-module/epmet-third/epmet-third-server/deploy/docker-compose-dev.yml
  13. 2
      epmet-module/epmet-third/epmet-third-server/pom.xml
  14. 9
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/controller/AppLetAuthorizationController.java
  15. 7
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/BusinessInfoDao.java
  16. 4
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/CodeCustomerDao.java
  17. 7
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniCategoryInfoDao.java
  18. 7
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniInfoDao.java
  19. 7
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniNetworkInfoDao.java
  20. 5
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/entity/CodeCustomerEntity.java
  21. 2
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/AppLetAuthorizationService.java
  22. 2
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/CodeCustomerService.java
  23. 6
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/AppLetAuthorizationServiceImpl.java
  24. 4
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/CodeCustomerServiceImpl.java
  25. 3
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/CodeServiceImpl.java
  26. 7
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/ComponentVerifyTicketServiceImpl.java
  27. 2
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/PaCustomerServiceImpl.java
  28. 2
      epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/wxapi/constant/WxMaCodeConstant.java
  29. 11
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/BusinessInfoDao.xml
  30. 3
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/CodeCustomerDao.xml
  31. 2
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/CustomerMpDao.xml
  32. 11
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniCategoryInfoDao.xml
  33. 13
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniInfoDao.xml
  34. 11
      epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniNetworkInfoDao.xml
  35. 2
      epmet-module/oper-crm/oper-crm-server/deploy/docker-compose-dev.yml
  36. 2
      epmet-module/oper-crm/oper-crm-server/pom.xml
  37. 11
      epmet-module/oper-crm/oper-crm-server/src/main/java/com/epmet/service/impl/CustomerServiceImpl.java

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

@ -171,13 +171,14 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
}
Object RegisterResult = result.getData();
JSONObject jsonObject = JSON.parseObject(RegisterResult.toString());
CustomerUserResultDTO resultDTO = ConvertUtils.mapToEntity(jsonObject, CustomerUserResultDTO.class);
Map<String,Object> map = (Map)jsonObject.get("paUserResult");
PaUserDTO userDTO = ConvertUtils.mapToEntity(map, PaUserDTO.class);
//登陆
if (formDTO.getIsLogon() && null == resultDTO.getPaUserResult()) {
if (formDTO.getIsLogon() && null == userDTO) {
throw new RenException(EpmetErrorCode.PUBLIC_NOT_EXISTS.getCode());
}
//注册
if (!formDTO.getIsLogon() && null != resultDTO.getPaUserResult()) {
if (!formDTO.getIsLogon() && null != userDTO) {
throw new RenException(EpmetErrorCode.MOBILE_USED.getCode());
}
//3、发送短信验证码
@ -216,10 +217,10 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
}
Object RegisterResult = result.getData();
JSONObject jsonObject = JSON.parseObject(RegisterResult.toString());
CustomerUserResultDTO resultDTO = ConvertUtils.mapToEntity(jsonObject, CustomerUserResultDTO.class);
//2.用户不存在时不允许登陆
PaUserDTO userDTO = resultDTO.getPaUserResult();
Map<String,Object> map1 = (Map)jsonObject.get("paUserResult");
PaUserDTO userDTO = ConvertUtils.mapToEntity(map1, PaUserDTO.class);
if (null == userDTO || StringUtils.isBlank(userDTO.getId())) {
throw new RenException(EpmetErrorCode.PUBLIC_NOT_EXISTS.getCode());
}
@ -236,13 +237,15 @@ public class PublicUserLoginServiceImpl implements PublicUserLoginService {
//4-1.生成token
String token = this.generateGovWxmpToken(userDTO.getId());
//4-2.判断是否存在信息,给customerId赋值
PaCustomerDTO customerDTO = resultDTO.getPaCustomerResult();
Map<String,Object> map2 = (Map)jsonObject.get("paCustomerResult");
PaCustomerDTO customerDTO = ConvertUtils.mapToEntity(map2, PaCustomerDTO.class);
String customerId = "";
if (null != customerDTO && !StringUtils.isBlank(customerDTO.getId())) {
customerId = customerDTO.getId();
}
//4-3.token存入redis
PaUserWechatDTO wechatDTO = resultDTO.getPaUserWechatResult();
Map<String,Object> map3 = (Map)jsonObject.get("PaUserWechatDTO");
PaUserWechatDTO wechatDTO = ConvertUtils.mapToEntity(map3, PaUserWechatDTO.class);
String openid = wechatDTO.getWxOpenId();
String unionId = (null == wechatDTO.getUnionId() ? "" : wechatDTO.getUnionId());
this.saveLatestGovTokenDto(customerId, userDTO.getId(), openid, unionId, token);

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

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-gateway-server:
container_name: epmet-gateway-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-gateway:0.3.28
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-gateway:0.3.29
ports:
- "8080:8080"
network_mode: host # 使用现有网络

2
epmet-gateway/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.28</version>
<version>0.3.29</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>epmet-cloud</artifactId>

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

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-heart-server:
container_name: epmet-heart-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-heart-server:0.0.18
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-heart-server:0.0.20
ports:
- "8111:8111"
network_mode: host # 使用现有网络

2
epmet-module/epmet-heart/epmet-heart-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.0.18</version>
<version>0.0.20</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>epmet-heart</artifactId>

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

@ -2,7 +2,7 @@ version: "3.7"
services:
epmet-point-server:
container_name: epmet-point-server-dev
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-point-server:0.0.11
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-point-server:0.0.13
ports:
- "8112:8112"
network_mode: host # 使用现有网络

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

@ -3,7 +3,7 @@
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.0.11</version>
<version>0.0.13</version>
<parent>
<artifactId>epmet-point</artifactId>
<groupId>com.epmet</groupId>

5
epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/CodeCustomerDTO.java

@ -78,6 +78,11 @@ public class CodeCustomerDTO implements Serializable {
*/
private String userDesc;
/**
* 数据来源(dev:开发 test:体验 prod:生产)
*/
private String source;
/**
* 状态 未审核:unaudited审核中:auditing审核成功audit_success审核被拒绝audit_failed已撤回:withdrawn审核延后:delay发布成功release_success, 发布失败release_failed
*/

4
epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/form/UploadListFormDTO.java

@ -43,4 +43,8 @@ public class UploadListFormDTO implements Serializable {
* 页面条数
*/
private Integer pageSize;
/**
* 数据来源(dev:开发 test:体验 prod:生产)
*/
private String source;
}

6
epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/result/CustomerUserResultDTO.java

@ -16,15 +16,15 @@ public class CustomerUserResultDTO implements Serializable {
private static final long serialVersionUID = 5214475907074876716L;
/**
* 用户信息
* 用户信息 别名不能随便修改 否则影响程序
*/
private PaUserDTO paUserResult;
/**
* 用户对应的客户信息
* 用户对应的客户信息 别名不能随便修改 否则影响程序
*/
private PaCustomerDTO paCustomerResult;
/**
* 用户对应的微信基本信息
* 用户对应的微信基本信息 别名不能随便修改 否则影响程序
*/
private PaUserWechatDTO paUserWechatResult;
}

6
epmet-module/epmet-third/epmet-third-client/src/main/java/com/epmet/dto/result/InitCustomerResultDTO.java

@ -17,15 +17,15 @@ public class InitCustomerResultDTO implements Serializable {
private static final long serialVersionUID = 3253989119352850315L;
/**
* 注册客户信息
* 注册客户信息 别名不能随便修改 否则影响程序
*/
private PaCustomerDTO paCustomer;
/**
* 注册客户组织信息
* 注册客户组织信息 别名不能随便修改 否则影响程序
*/
private PaCustomerAgencyDTO paAgency;
/**
* 注册客户管理员信息
* 注册客户管理员信息 别名不能随便修改 否则影响程序
*/
private PaUserDTO paUser;

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.82
image: 192.168.1.130:10080/epmet-cloud-dev/epmet-third-server:0.0.91
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.82</version>
<version>0.0.91</version>
<parent>
<groupId>com.epmet</groupId>

9
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/controller/AppLetAuthorizationController.java

@ -10,10 +10,7 @@ import com.epmet.dto.form.RemoveBindFormDTO;
import com.epmet.dto.result.GoToAuthResultDTO;
import com.epmet.service.AppLetAuthorizationService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
/**
* @Author zxc
@ -32,9 +29,9 @@ public class AppLetAuthorizationController {
* @author zxc
*/
@PostMapping("gotoauth")
public Result<GoToAuthResultDTO> goToAuth(@LoginUser TokenDto tokenDto, @RequestBody GoToAuthFormDTO formDTO){
public Result<GoToAuthResultDTO> goToAuth(@LoginUser TokenDto tokenDto, @RequestBody GoToAuthFormDTO formDTO, @RequestHeader("source")String source){
ValidatorUtils.validateEntity(formDTO);
GoToAuthResultDTO goToAuthResultDTO = appLetAuthorizationService.goToAuth(tokenDto,formDTO);
GoToAuthResultDTO goToAuthResultDTO = appLetAuthorizationService.goToAuth(tokenDto,formDTO,source);
return new Result().ok(goToAuthResultDTO);
}

7
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/BusinessInfoDao.java

@ -41,4 +41,11 @@ public interface BusinessInfoDao extends BaseDao<BusinessInfoEntity> {
*/
void insertBusinessInfo(@Param("businessInfoList") List<BusinessInfoFormDTO> businessInfoList);
/**
* @Description 功能开通信息删除
* @param
* @author zxc
*/
void deleteBusinessInfo(@Param("customerId")String customerId,@Param("clientType")String clientType);
}

4
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/CodeCustomerDao.java

@ -76,9 +76,9 @@ public interface CodeCustomerDao extends BaseDao<CodeCustomerEntity> {
* 获取审核中代码列表
* @author zhaoqifeng
* @date 2020/7/15 18:17
* @param
* @param source
* @return java.util.List<com.epmet.dto.CodeCustomerDTO>
*/
List<CodeCustomerDTO> selectAuditingCodeList();
List<CodeCustomerDTO> selectAuditingCodeList(@Param("source") String source);
}

7
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniCategoryInfoDao.java

@ -41,4 +41,11 @@ public interface MiniCategoryInfoDao extends BaseDao<MiniCategoryInfoEntity> {
*/
void insertCategoryInfo(@Param("miniCategoryInfoList") List<MiniCategoryInfoFormDTO> miniCategoryInfoList);
/**
* @Description 小程序配置的类目信息删除
* @param
* @author zxc
*/
void deleteCategoryInfo(@Param("customerId")String customerId,@Param("clientType")String clientType);
}

7
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniInfoDao.java

@ -40,6 +40,13 @@ public interface MiniInfoDao extends BaseDao<MiniInfoEntity> {
*/
void insertMiniInfo(MiniInfoFormDTO formDTO);
/**
* @Description 删除小程序信息
* @param formDTO
* @author zxc
*/
void deleteMiniInfo(MiniInfoFormDTO formDTO);
/**
* @Description 根据原始ID查询 customerId clientType
* @param toUserName

7
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/dao/MiniNetworkInfoDao.java

@ -41,4 +41,11 @@ public interface MiniNetworkInfoDao extends BaseDao<MiniNetworkInfoEntity> {
*/
void insertNetworkInfo(@Param("networkInfoList") List<MiniNetworkInfoFormDTO> networkInfoList);
/**
* @Description 小程序配置的合法域名信息删除
* @param
* @author zxc
*/
void deleteNetworkInfo(@Param("customerId")String customerId,@Param("clientType")String clientType);
}

5
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/entity/CodeCustomerEntity.java

@ -78,6 +78,11 @@ public class CodeCustomerEntity extends BaseEpmetEntity {
*/
private String userDesc;
/**
* 数据来源(dev:开发 test:体验 prod:生产)
*/
private String source;
/**
* 状态 未审核:unaudited审核中:auditing审核成功audit_success审核被拒绝audit_failed已撤回:withdrawn审核延后:delay发布成功release_success, 发布失败release_failed
*/

2
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/AppLetAuthorizationService.java

@ -17,7 +17,7 @@ public interface AppLetAuthorizationService {
* @param tokenDto
* @author zxc
*/
GoToAuthResultDTO goToAuth(TokenDto tokenDto, GoToAuthFormDTO formDTO);
GoToAuthResultDTO goToAuth(TokenDto tokenDto, GoToAuthFormDTO formDTO,String source);
/**
* @Description 将公众号/小程序从开放平台帐号下解绑

2
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/CodeCustomerService.java

@ -110,7 +110,7 @@ public interface CodeCustomerService extends BaseService<CodeCustomerEntity> {
* @param
* @return java.util.List<com.epmet.dto.CodeCustomerDTO>
*/
List<CodeCustomerDTO> getAuditingCodeList();
List<CodeCustomerDTO> getAuditingCodeList(String source);
/**
* 删除旧代码记录

6
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/AppLetAuthorizationServiceImpl.java

@ -55,14 +55,16 @@ public class AppLetAuthorizationServiceImpl implements AppLetAuthorizationServic
* @author zxc
*/
@Override
public GoToAuthResultDTO goToAuth(TokenDto tokenDto, GoToAuthFormDTO formDTO) {
public GoToAuthResultDTO goToAuth(TokenDto tokenDto, GoToAuthFormDTO formDTO,String source) {
GoToAuthResultDTO result = new GoToAuthResultDTO();
String userId = tokenDto.getUserId();
//获取预授权码
String preAuthCode = componentVerifyTicketService.preAuthCode();
String redirectUrl = WxMaCodeConstant.WEB_URL + formDTO.getClientType();
// String redirectUrl = WxMaCodeConstant.WEB_URL + formDTO.getClientType();
String redirectUrl = String.format(WxMaCodeConstant.WEB_URL,source,formDTO.getClientType());
String authUrl = String.format(WxMaCodeConstant.API_AUTH_REGISTER_URL, componentAppId, preAuthCode, redirectUrl);
result.setUrl(authUrl);
log.info("返回URL:"+result.getUrl());
return result;
}

4
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/CodeCustomerServiceImpl.java

@ -115,8 +115,8 @@ public class CodeCustomerServiceImpl extends BaseServiceImpl<CodeCustomerDao, Co
}
@Override
public List<CodeCustomerDTO> getAuditingCodeList() {
return baseDao.selectAuditingCodeList();
public List<CodeCustomerDTO> getAuditingCodeList(String source) {
return baseDao.selectAuditingCodeList(source);
}
@Override

3
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/CodeServiceImpl.java

@ -152,6 +152,7 @@ public class CodeServiceImpl implements CodeService {
//将上传信息存入表中
CodeCustomerDTO codeCustomerDTO = ConvertUtils.sourceToTarget(formDTO, CodeCustomerDTO.class);
codeCustomerDTO.setCustomerName(paCustomerDTO.getCustomerName());
codeCustomerDTO.setSource(paCustomerDTO.getSource());
codeCustomerDTO.setExtJson(extJson);
codeCustomerDTO.setAppId(authInfo.getAuthorizerAppid());
codeCustomerDTO.setStatus(CodeConstant.UNAUDITED);
@ -162,7 +163,7 @@ public class CodeServiceImpl implements CodeService {
@Override
public PageData uploadList(UploadListFormDTO formDTO) {
List<CodeCustomerDTO> auditingList = codeCustomerService.getAuditingCodeList();
List<CodeCustomerDTO> auditingList = codeCustomerService.getAuditingCodeList(formDTO.getSource());
if (null != auditingList && auditingList.size() > NumConstant.ZERO) {
auditingList.forEach(code -> {
//获取小程序调用令牌

7
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/ComponentVerifyTicketServiceImpl.java

@ -125,7 +125,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
switch (infotype){
case ModuleConstant.TICKET_UNDERLINE_KEY: //接收票据 【component_verify_ticket】
String ComponentVerifyTicket = result.get(ModuleConstant.TICKET_KEY);
log.info(String.format(COMPONENT_VERIFY_TICKET));
log.info(String.format(COMPONENT_VERIFY_TICKET,ComponentVerifyTicket));
// 缓存 ticket
redisThird.setComponentVerifyTicket(ComponentVerifyTicket);
// 存数据库
@ -437,6 +437,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
miniInfoFormDTO.setCustomerId(customerId);
miniInfoFormDTO.setClientType(clientType);
//基础信息插入
miniInfoDao.deleteMiniInfo(miniInfoFormDTO);
miniInfoDao.insertMiniInfo(miniInfoFormDTO);
String primaryId = miniInfoFormDTO.getId();
//todo 功能的开通状况信息插入
@ -451,6 +452,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
businessInfoForm.setPrimaryId(primaryId);
businessInfoList.add(businessInfoForm);
});
businessInfoDao.deleteBusinessInfo(customerId,clientType);
businessInfoDao.insertBusinessInfo(businessInfoList);
//todo 小程序配置的合法域名信息插入
Map miniProgramInfo = (Map) authorizerInfo.get(ModuleConstant.MINI_PROGRAM_INFO);
@ -465,6 +467,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
miniNetworkInfoForm.setPrimaryId(primaryId);
networkInfoList.add(miniNetworkInfoForm);
});
miniNetworkInfoDao.deleteNetworkInfo(customerId,clientType);
miniNetworkInfoDao.insertNetworkInfo(networkInfoList);
//todo 小程序配置的类目信息插入
List<MiniCategoryInfoFormDTO> categoryInfoList = new ArrayList<>();
@ -481,6 +484,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
categoryInfoList.add(categoryInfo);
});
});
miniCategoryInfoDao.deleteCategoryInfo(customerId, clientType);
miniCategoryInfoDao.insertCategoryInfo(categoryInfoList);
}
}else {
@ -501,6 +505,7 @@ public class ComponentVerifyTicketServiceImpl implements ComponentVerifyTicketSe
businessInfoForm.setPrimaryId(primaryId);
businessInfoList.add(businessInfoForm);
});
businessInfoDao.deleteBusinessInfo(customerId,clientType);
businessInfoDao.insertBusinessInfo(businessInfoList);
}
log.info("保存授权方基本信息结束");

2
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/service/impl/PaCustomerServiceImpl.java

@ -210,6 +210,7 @@ public class PaCustomerServiceImpl extends BaseServiceImpl<PaCustomerDao, PaCust
visitedEntity.setWxOpenId(wechatEntity.getWxOpenId());
visitedEntity.setOpenId(wechatEntity.getWxOpenId());
visitedEntity.setPhone(formDTO.getPhone());
visitedEntity.setSource(formDTO.getSource());
if (paUserVisitedDao.insert(visitedEntity) < NumConstant.ONE) {
throw new RenException(PaConstant.SAVE_VISITED_EXCEPTION);
}
@ -240,6 +241,7 @@ public class PaCustomerServiceImpl extends BaseServiceImpl<PaCustomerDao, PaCust
visitedEntity.setWxOpenId(wechatEntity.getWxOpenId());
visitedEntity.setOpenId(wechatEntity.getWxOpenId());
visitedEntity.setPhone(formDTO.getPhone());
visitedEntity.setSource(formDTO.getSource());
if (paUserVisitedDao.insert(visitedEntity) < NumConstant.ONE) {
throw new RenException(PaConstant.SAVE_VISITED_EXCEPTION);
}

2
epmet-module/epmet-third/epmet-third-server/src/main/java/com/epmet/wxapi/constant/WxMaCodeConstant.java

@ -33,7 +33,7 @@ public interface WxMaCodeConstant {
/**
* 前端地址 授权之后的跳转的地址
*/
String WEB_URL = "https://epmet-cloud.elinkservice.cn/third/mpweb/page/#/info?clientType=";
String WEB_URL = "https://epmet-cloud.elinkservice.cn/third/mpweb/page/%s/#/info?clientType=%s";
/**
* 授权注册页面扫码授权

11
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/BusinessInfoDao.xml

@ -24,4 +24,15 @@
)
</foreach>
</insert>
<!-- 功能开通信息删除 -->
<delete id="deleteBusinessInfo">
DELETE
FROM
business_info
WHERE
del_flag = 0
AND customer_id = #{customerId}
AND client_type = #{clientType}
</delete>
</mapper>

3
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/CodeCustomerDao.xml

@ -38,6 +38,7 @@
LEFT JOIN code_audit_result car ON cc.ID = car.CODE_ID AND car.DEL_FLAG = '0'
WHERE
cc.DEL_FLAG = '0'
AND cc.SOURCE = #{source}
<if test="customerId != null and customerId.trim() != ''">
AND cc.CUSTOMER_ID = #{customerId}
</if>
@ -85,7 +86,7 @@
AND template_id = #{templateId}
</select>
<select id="selectAuditingCodeList" resultType="com.epmet.dto.CodeCustomerDTO">
select * FROM code_customer WHERE DEL_FLAG = '0' AND STATUS = 'auditing'
select * FROM code_customer WHERE DEL_FLAG = '0' AND STATUS = 'auditing' AND SOURCE = #{source}
</select>
<update id="deleteCode">
UPDATE code_customer

2
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/CustomerMpDao.xml

@ -72,7 +72,7 @@
WHERE
cm.del_flag = '0'
AND pc.del_flag = '0'
AND pc.source = '#{source}'
AND pc.source = #{source}
ORDER BY
cm.customer_id ASC,
cm.client ASC

11
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniCategoryInfoDao.xml

@ -24,4 +24,15 @@
)
</foreach>
</insert>
<!-- 小程序配置的类目信息删除 -->
<delete id="deleteCategoryInfo">
DELETE
FROM
mini_category_info
WHERE
del_flag = 0
AND customer_id = #{customerId}
AND client_type = #{clientType}
</delete>
</mapper>

13
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniInfoDao.xml

@ -6,7 +6,7 @@
<!-- 插入小程序信息 -->
<insert id="insertMiniInfo">
<selectKey keyProperty="id" order="AFTER" resultType="String">
SELECT LAST_INSERT_ID() AS id
SELECT id AS id from mini_info where del_flag = 0 and customer_id = #{customerId} and client_type = #{clientType} order by created_time desc limit 1
</selectKey>
INSERT INTO mini_info ( ID, CUSTOMER_ID, CLIENT_TYPE, NICK_NAME, HEAD_IMG, SERVICE_TYPE_INFO, VERIFY_TYPE_INFO, USER_NAME,
PRINCIPAL_NAME, SIGNATURE, QRCODE_URL, DEL_FLAG, REVISION, CREATED_BY, CREATED_TIME, UPDATED_BY, UPDATED_TIME)
@ -32,6 +32,17 @@
)
</insert>
<!-- 删除小程序信息 -->
<delete id="deleteMiniInfo">
DELETE
FROM
mini_info
WHERE
del_flag = 0
AND customer_id = #{customerId}
AND client_type = #{clientType}
</delete>
<!-- 根据原始ID查询 customerId 和 clientType -->
<select id="selectCustomerIdAndClientByToUserName" resultType="com.epmet.dto.result.CustomerIdAndClientResultDTO">
SELECT

11
epmet-module/epmet-third/epmet-third-server/src/main/resources/mapper/MiniNetworkInfoDao.xml

@ -24,4 +24,15 @@
)
</foreach>
</insert>
<!-- 小程序配置的合法域名信息删除 -->
<delete id="deleteNetworkInfo">
DELETE
FROM
mini_network_info
WHERE
del_flag = 0
AND customer_id = #{customerId}
AND client_type = #{clientType}
</delete>
</mapper>

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.57
image: 192.168.1.130:10080/epmet-cloud-dev/oper-crm-server:0.3.58
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.57</version>
<version>0.3.58</version>
<parent>
<groupId>com.epmet</groupId>
<artifactId>oper-crm</artifactId>

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

@ -414,11 +414,12 @@ public class CustomerServiceImpl extends BaseServiceImpl<CustomerDao, CustomerEn
}
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();
Map<String,Object> map1 = (Map)jsonObject.get("paCustomer");
PaCustomerDTO paCustomer = ConvertUtils.mapToEntity(map1, PaCustomerDTO.class);
Map<String,Object> map2 = (Map)jsonObject.get("paAgency");
PaCustomerAgencyDTO paAgency = ConvertUtils.mapToEntity(map2, PaCustomerAgencyDTO.class);
Map<String,Object> map3 = (Map)jsonObject.get("paUser");
PaUserDTO paUser = ConvertUtils.mapToEntity(map3, PaUserDTO.class);
//2.校验当前客户是否已初始化,不存在则初始客户信息
CustomerEntity entity = baseDao.selectById(formDTO.getCustomerId());

Loading…
Cancel
Save