|
@@ -79,9 +79,13 @@ public class KwsEnterpriseService {
|
|
|
@Value(value = "${jumpUrl.entCertificate}")
|
|
@Value(value = "${jumpUrl.entCertificate}")
|
|
|
private String entCertificateUrl;
|
|
private String entCertificateUrl;
|
|
|
|
|
|
|
|
- @Value(value = "${jumpUrl.entCertificate}")
|
|
|
|
|
|
|
+ @Value(value = "${jumpUrl.appEntCertificate}")
|
|
|
private String appEntCertificateUrl;
|
|
private String appEntCertificateUrl;
|
|
|
|
|
|
|
|
|
|
+ @Value(value = "${jumpUrl.entDept}")
|
|
|
|
|
+ private String entDeptUrl;
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
/**
|
|
/**
|
|
|
* @param params 入库
|
|
* @param params 入库
|
|
|
* @desc: 单表入库
|
|
* @desc: 单表入库
|
|
@@ -373,7 +377,10 @@ public class KwsEnterpriseService {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
//子公司不用新建机构、角色等,直接返回
|
|
//子公司不用新建机构、角色等,直接返回
|
|
|
- if (!Objects.isNull(reqVo.getEntPid())) {
|
|
|
|
|
|
|
+ Map<String, Object> map = new HashMap<>();
|
|
|
|
|
+ map.put("entName", kwsEnterprise.getFirmName());
|
|
|
|
|
+ map.put("createByName", kwsEnterprise.getContacts());
|
|
|
|
|
+ if (Objects.nonNull(reqVo.getEntPid())) {
|
|
|
KwsEntDept kwsEntDept = new KwsEntDept();
|
|
KwsEntDept kwsEntDept = new KwsEntDept();
|
|
|
kwsEntDept.setEntId(entId);
|
|
kwsEntDept.setEntId(entId);
|
|
|
kwsEntDept.setEntPid(reqVo.getEntPid());
|
|
kwsEntDept.setEntPid(reqVo.getEntPid());
|
|
@@ -381,15 +388,17 @@ public class KwsEnterpriseService {
|
|
|
if (kwsEntDeptDao.insert(kwsEntDept) <= 0) {
|
|
if (kwsEntDeptDao.insert(kwsEntDept) <= 0) {
|
|
|
throw new SystemException(HttpStatus.CRUD_FAIL_CODE, HttpStatus.INSERT_FAIL);
|
|
throw new SystemException(HttpStatus.CRUD_FAIL_CODE, HttpStatus.INSERT_FAIL);
|
|
|
}
|
|
}
|
|
|
- }
|
|
|
|
|
|
|
|
|
|
- Map<String, Object> map = new HashMap<>();
|
|
|
|
|
- map.put("entName", kwsEnterprise.getFirmName());
|
|
|
|
|
- map.put("createByName", kwsEnterprise.getContacts());
|
|
|
|
|
- commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(userId).setEntId(entId)),
|
|
|
|
|
- MessageEnum.ENT_CERTIFICATE,
|
|
|
|
|
- map,
|
|
|
|
|
- entCertificateUrl,"");
|
|
|
|
|
|
|
+ commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(userId).setEntId(entId)),
|
|
|
|
|
+ MessageEnum.ENT_CERTIFICATE,
|
|
|
|
|
+ map,
|
|
|
|
|
+ entDeptUrl, "");
|
|
|
|
|
+ } else {
|
|
|
|
|
+ commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(userId).setEntId(entId)),
|
|
|
|
|
+ MessageEnum.ENT_CERTIFICATE,
|
|
|
|
|
+ map,
|
|
|
|
|
+ entCertificateUrl, appEntCertificateUrl);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -484,10 +493,19 @@ public class KwsEnterpriseService {
|
|
|
messageEnum = MessageEnum.ENT_DEPT_CERTIFICATE_REFUSED;
|
|
messageEnum = MessageEnum.ENT_DEPT_CERTIFICATE_REFUSED;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(kwsEnterprise.getCreateBy()).setEntId(entId)),
|
|
|
|
|
- messageEnum,
|
|
|
|
|
- map,
|
|
|
|
|
- entCertificateUrl,"");
|
|
|
|
|
|
|
+
|
|
|
|
|
+ if (Objects.isNull(kwsEntDept)) {
|
|
|
|
|
+ commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(kwsEnterprise.getCreateBy()).setEntId(entId)),
|
|
|
|
|
+ messageEnum,
|
|
|
|
|
+ map,
|
|
|
|
|
+ entCertificateUrl, appEntCertificateUrl);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(kwsEnterprise.getCreateBy()).setEntId(entId)),
|
|
|
|
|
+ messageEnum,
|
|
|
|
|
+ map,
|
|
|
|
|
+ entDeptUrl, "");
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -617,14 +635,6 @@ public class KwsEnterpriseService {
|
|
|
|
|
|
|
|
//主体机构
|
|
//主体机构
|
|
|
extracted(reqVo, new IdWorker(1L).nextId());
|
|
extracted(reqVo, new IdWorker(1L).nextId());
|
|
|
- Map<String, Object> map = new HashMap<>();
|
|
|
|
|
- map.put("entName", reqVo.getFirmName());
|
|
|
|
|
- map.put("createByName", reqVo.getContacts());
|
|
|
|
|
- commonService.sendSystemMessage(Collections.singletonList(new UserInfo().setUserId(LoginUserHolder.getUserId()).setEntId(LoginUserHolder.getEntId())),
|
|
|
|
|
- MessageEnum.ENT_DEPT_CERTIFICATE,
|
|
|
|
|
- map,
|
|
|
|
|
- entCertificateUrl,
|
|
|
|
|
- appEntCertificateUrl);
|
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|