添加头像功能
This commit is contained in:
parent
1b7aef3095
commit
2c57dd2f2a
|
|
@ -112,4 +112,5 @@ public class EmployeesApplyMQDto implements Serializable {
|
||||||
* 现住址
|
* 现住址
|
||||||
*/
|
*/
|
||||||
private String currentAddress;
|
private String currentAddress;
|
||||||
|
private String headPath;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -95,6 +95,7 @@ public class EmployeesStatusMQDto implements Serializable {
|
||||||
private String noCrimeCertificate;
|
private String noCrimeCertificate;
|
||||||
/**现住址*/
|
/**现住址*/
|
||||||
private String currentAddress;
|
private String currentAddress;
|
||||||
|
private String headPath;
|
||||||
/**有效开始日期*/
|
/**有效开始日期*/
|
||||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy.MM.dd")
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy.MM.dd")
|
||||||
@DateTimeFormat(pattern="yyyy.MM.dd")
|
@DateTimeFormat(pattern="yyyy.MM.dd")
|
||||||
|
|
|
||||||
|
|
@ -104,5 +104,6 @@ public class SysUserMQDto implements Serializable {
|
||||||
* 是否需要初始化密码(0,否,1是)
|
* 是否需要初始化密码(0,否,1是)
|
||||||
*/
|
*/
|
||||||
private String izInitPassword;
|
private String izInitPassword;
|
||||||
|
private String headPath;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -210,6 +210,7 @@ public class SysUserEntity implements Serializable {
|
||||||
* 流程状态
|
* 流程状态
|
||||||
*/
|
*/
|
||||||
private String bpmStatus;
|
private String bpmStatus;
|
||||||
|
private String headPath;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 是否已经绑定第三方
|
* 是否已经绑定第三方
|
||||||
|
|
|
||||||
|
|
@ -187,6 +187,7 @@ public class EmployeesApplyController extends JeecgController<EmployeesApply, IE
|
||||||
mqdto.setQualificationPath(apply.getQualification());
|
mqdto.setQualificationPath(apply.getQualification());
|
||||||
mqdto.setNoCrimeCertificate(apply.getNoCrimeCertificate());
|
mqdto.setNoCrimeCertificate(apply.getNoCrimeCertificate());
|
||||||
mqdto.setCurrentAddress(apply.getCurrentAddress());
|
mqdto.setCurrentAddress(apply.getCurrentAddress());
|
||||||
|
mqdto.setHeadPath(apply.getHeadPath());
|
||||||
}
|
}
|
||||||
rabbitMQUtil.sendToExchange("hldy.employees", "hldy.employeesorg.auditstatus.sync", mqdto);
|
rabbitMQUtil.sendToExchange("hldy.employees", "hldy.employeesorg.auditstatus.sync", mqdto);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -215,6 +215,7 @@ public class EmployeesApply implements Serializable {
|
||||||
@Excel(name = "修改状态", width = 15)
|
@Excel(name = "修改状态", width = 15)
|
||||||
@ApiModelProperty(value = "修改状态")
|
@ApiModelProperty(value = "修改状态")
|
||||||
private java.lang.String modifyStatus;
|
private java.lang.String modifyStatus;
|
||||||
|
private java.lang.String headPath;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 审批字符串 有值时说明是走的审批
|
* 审批字符串 有值时说明是走的审批
|
||||||
|
|
|
||||||
|
|
@ -78,7 +78,8 @@
|
||||||
b.apply_type,
|
b.apply_type,
|
||||||
b.audit_content,
|
b.audit_content,
|
||||||
b.iz_history,
|
b.iz_history,
|
||||||
b.open_id
|
b.open_id,
|
||||||
|
a.head_path
|
||||||
FROM nu_biz_employees_info a
|
FROM nu_biz_employees_info a
|
||||||
LEFT JOIN nu_biz_employees_apply b ON a.id = b.employee_id AND b.iz_history = 'N'
|
LEFT JOIN nu_biz_employees_apply b ON a.id = b.employee_id AND b.iz_history = 'N'
|
||||||
WHERE a.del_flag = '0' AND a.iz_freeze = 'N'
|
WHERE a.del_flag = '0' AND a.iz_freeze = 'N'
|
||||||
|
|
@ -116,7 +117,8 @@
|
||||||
b.apply_type,
|
b.apply_type,
|
||||||
b.audit_content,
|
b.audit_content,
|
||||||
b.iz_history,
|
b.iz_history,
|
||||||
b.open_id
|
b.open_id,
|
||||||
|
b.head_path
|
||||||
FROM nu_biz_employees_apply b
|
FROM nu_biz_employees_apply b
|
||||||
WHERE b.employee_id NOT IN (SELECT id FROM nu_biz_employees_info)
|
WHERE b.employee_id NOT IN (SELECT id FROM nu_biz_employees_info)
|
||||||
AND b.apply_type = '1'
|
AND b.apply_type = '1'
|
||||||
|
|
|
||||||
|
|
@ -88,251 +88,8 @@ public class EmployeesMQListener {
|
||||||
employeesApply.setIzHistory("N");
|
employeesApply.setIzHistory("N");
|
||||||
employeesApply.setApplyType("1");
|
employeesApply.setApplyType("1");
|
||||||
|
|
||||||
//资源文件拉完图片统一存储,不然页面有路径没资源可显示
|
|
||||||
String idCardPositive = employeesApply.getIdCardPositive();
|
|
||||||
String idCardNegative = employeesApply.getIdCardNegative();
|
|
||||||
String healthCertificatePositive = employeesApply.getHealthCertificatePositive();
|
|
||||||
String healthCertificateNegative = employeesApply.getHealthCertificateNegative();
|
|
||||||
String bankPositive = employeesApply.getBankPositive();
|
|
||||||
String bankNegative = employeesApply.getBankNegative();
|
|
||||||
String qualification = employeesApply.getQualification();
|
|
||||||
String noCrimeCertificate = employeesApply.getNoCrimeCertificate();
|
|
||||||
{
|
|
||||||
// employeesApply.setIdCardPositive(null);//身份证正面
|
|
||||||
// employeesApply.setIdCardNegative(null);//身份证反面
|
|
||||||
// employeesApply.setHealthCertificatePositive(null);//健康证正面
|
|
||||||
// employeesApply.setHealthCertificateNegative(null);//健康证反面
|
|
||||||
// employeesApply.setBankPositive(null);//银行卡正面
|
|
||||||
// employeesApply.setBankNegative(null);//银行卡反面
|
|
||||||
// employeesApply.setQualification(null);//资质证
|
|
||||||
// employeesApply.setNoCrimeCertificate(null);//无犯罪证明
|
|
||||||
}
|
|
||||||
employeesApplyService.save(employeesApply);
|
employeesApplyService.save(employeesApply);
|
||||||
|
|
||||||
//去管理平台拉取资源
|
|
||||||
// {
|
|
||||||
// EmployeesApply mediaData = new EmployeesApply();
|
|
||||||
// mediaData.setId(employeesApply.getId());
|
|
||||||
//
|
|
||||||
// JSONObject opeOpenUrl = sysConfigApi.getByKeyByDS("master", "ope_open_url");
|
|
||||||
// String baseUrl = opeOpenUrl.getString("configValue");
|
|
||||||
// if (baseUrl.endsWith("/")) {
|
|
||||||
// baseUrl = baseUrl.substring(0, baseUrl.length() - 1);
|
|
||||||
// }
|
|
||||||
// //身份证正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(idCardPositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(idCardPositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(idCardPositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = idCardPositive.substring(0, idCardPositive.lastIndexOf("/"));
|
|
||||||
// String fileName = idCardPositive.substring(idCardPositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setIdCardPositive(idCardPositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(idCardPositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-身份证正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //身份证反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(idCardNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(idCardNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(idCardNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = idCardNegative.substring(0, idCardNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = idCardNegative.substring(idCardNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setIdCardNegative(idCardNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(idCardNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-身份证反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //健康证正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificatePositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificatePositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(healthCertificatePositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = healthCertificatePositive.substring(0, healthCertificatePositive.lastIndexOf("/"));
|
|
||||||
// String fileName = healthCertificatePositive.substring(healthCertificatePositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setHealthCertificatePositive(healthCertificatePositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(healthCertificatePositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-健康证正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //健康证反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificateNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificateNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(healthCertificateNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = healthCertificateNegative.substring(0, healthCertificateNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = healthCertificateNegative.substring(healthCertificateNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setHealthCertificateNegative(healthCertificateNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(healthCertificateNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-健康证反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //银行卡正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(bankPositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(bankPositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(bankPositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = bankPositive.substring(0, bankPositive.lastIndexOf("/"));
|
|
||||||
// String fileName = bankPositive.substring(bankPositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setBankPositive(bankPositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(bankPositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-银行卡正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //银行卡反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(bankNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(bankNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(bankNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = bankNegative.substring(0, bankNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = bankNegative.substring(bankNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setBankNegative(bankNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(bankNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-银行卡反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //资质证(多张使用逗号分隔)
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(qualification)) {
|
|
||||||
// List<String> list = Arrays.asList(qualification.split(","));
|
|
||||||
// for (int i = 0; i < list.size(); i++) {
|
|
||||||
// String qua = list.get(i);
|
|
||||||
// if (StringUtils.isNotBlank(qua)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(qua, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = qua.substring(0, qua.lastIndexOf("/"));
|
|
||||||
// String fileName = qua.substring(qua.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(qualification);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-资质证文件拉取错误,员工id" + dto.getEmployeeId() + ";文件:" + qua);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// mediaData.setQualification(qualification);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //无犯罪证明
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(noCrimeCertificate)) {
|
|
||||||
// if (StringUtils.isNotBlank(noCrimeCertificate)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(noCrimeCertificate, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = noCrimeCertificate.substring(0, noCrimeCertificate.lastIndexOf("/"));
|
|
||||||
// String fileName = noCrimeCertificate.substring(noCrimeCertificate.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setNoCrimeCertificate(noCrimeCertificate);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(noCrimeCertificate);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-无犯罪证明文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// employeesApplyService.updateById(mediaData);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -370,251 +127,8 @@ public class EmployeesMQListener {
|
||||||
employeesApply.setApplyType(dto.getApplyType());
|
employeesApply.setApplyType(dto.getApplyType());
|
||||||
employeesApply.setModifyStatus(dto.getModifyStatus());
|
employeesApply.setModifyStatus(dto.getModifyStatus());
|
||||||
|
|
||||||
//资源文件拉完图片统一存储,不然页面有路径没资源可显示
|
|
||||||
String idCardPositive = employeesApply.getIdCardPositive();
|
|
||||||
String idCardNegative = employeesApply.getIdCardNegative();
|
|
||||||
String healthCertificatePositive = employeesApply.getHealthCertificatePositive();
|
|
||||||
String healthCertificateNegative = employeesApply.getHealthCertificateNegative();
|
|
||||||
String bankPositive = employeesApply.getBankPositive();
|
|
||||||
String bankNegative = employeesApply.getBankNegative();
|
|
||||||
String qualification = employeesApply.getQualification();
|
|
||||||
String noCrimeCertificate = employeesApply.getNoCrimeCertificate();
|
|
||||||
{
|
|
||||||
// employeesApply.setIdCardPositive(null);//身份证正面
|
|
||||||
// employeesApply.setIdCardNegative(null);//身份证反面
|
|
||||||
// employeesApply.setHealthCertificatePositive(null);//健康证正面
|
|
||||||
// employeesApply.setHealthCertificateNegative(null);//健康证反面
|
|
||||||
// employeesApply.setBankPositive(null);//银行卡正面
|
|
||||||
// employeesApply.setBankNegative(null);//银行卡反面
|
|
||||||
// employeesApply.setQualification(null);//资质证
|
|
||||||
// employeesApply.setNoCrimeCertificate(null);//无犯罪证明
|
|
||||||
}
|
|
||||||
employeesApplyService.save(employeesApply);
|
employeesApplyService.save(employeesApply);
|
||||||
|
|
||||||
//去管理平台拉取资源
|
|
||||||
// {
|
|
||||||
// EmployeesApply mediaData = new EmployeesApply();
|
|
||||||
// mediaData.setId(employeesApply.getId());
|
|
||||||
//
|
|
||||||
// JSONObject opeOpenUrl = sysConfigApi.getByKeyByDS("master", "ope_open_url");
|
|
||||||
// String baseUrl = opeOpenUrl.getString("configValue");
|
|
||||||
// if (baseUrl.endsWith("/")) {
|
|
||||||
// baseUrl = baseUrl.substring(0, baseUrl.length() - 1);
|
|
||||||
// }
|
|
||||||
// //身份证正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(idCardPositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(idCardPositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(idCardPositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = idCardPositive.substring(0, idCardPositive.lastIndexOf("/"));
|
|
||||||
// String fileName = idCardPositive.substring(idCardPositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setIdCardPositive(idCardPositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(idCardPositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-身份证正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //身份证反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(idCardNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(idCardNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(idCardNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = idCardNegative.substring(0, idCardNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = idCardNegative.substring(idCardNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setIdCardNegative(idCardNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(idCardNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-身份证反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //健康证正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificatePositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificatePositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(healthCertificatePositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = healthCertificatePositive.substring(0, healthCertificatePositive.lastIndexOf("/"));
|
|
||||||
// String fileName = healthCertificatePositive.substring(healthCertificatePositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setHealthCertificatePositive(healthCertificatePositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(healthCertificatePositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-健康证正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //健康证反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificateNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(healthCertificateNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(healthCertificateNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = healthCertificateNegative.substring(0, healthCertificateNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = healthCertificateNegative.substring(healthCertificateNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setHealthCertificateNegative(healthCertificateNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(healthCertificateNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-健康证反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //银行卡正面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(bankPositive)) {
|
|
||||||
// if (StringUtils.isNotBlank(bankPositive)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(bankPositive, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = bankPositive.substring(0, bankPositive.lastIndexOf("/"));
|
|
||||||
// String fileName = bankPositive.substring(bankPositive.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setBankPositive(bankPositive);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(bankPositive);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-银行卡正面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //银行卡反面
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(bankNegative)) {
|
|
||||||
// if (StringUtils.isNotBlank(bankNegative)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(bankNegative, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = bankNegative.substring(0, bankNegative.lastIndexOf("/"));
|
|
||||||
// String fileName = bankNegative.substring(bankNegative.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setBankNegative(bankNegative);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(bankNegative);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-银行卡反面文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //资质证(多张使用逗号分隔)
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(qualification)) {
|
|
||||||
// List<String> list = Arrays.asList(qualification.split(","));
|
|
||||||
// for (int i = 0; i < list.size(); i++) {
|
|
||||||
// String qua = list.get(i);
|
|
||||||
// if (StringUtils.isNotBlank(qua)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(qua, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = qua.substring(0, qua.lastIndexOf("/"));
|
|
||||||
// String fileName = qua.substring(qua.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(qualification);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-资质证文件拉取错误,员工id" + dto.getEmployeeId() + ";文件:" + qua);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// mediaData.setQualification(qualification);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// //无犯罪证明
|
|
||||||
// {
|
|
||||||
// if (StringUtils.isNotBlank(noCrimeCertificate)) {
|
|
||||||
// if (StringUtils.isNotBlank(noCrimeCertificate)) {
|
|
||||||
// String url = baseUrl + "/sys/common/open/static/" + URLEncoder.encode(noCrimeCertificate, StandardCharsets.UTF_8).replace("%2F", "/") + "?name=" + SafetyUtil.getSecureKey();
|
|
||||||
// if (upLoadPath.endsWith("/") || upLoadPath.endsWith("\\")) {
|
|
||||||
// upLoadPath = upLoadPath.substring(0, upLoadPath.length() - 1);
|
|
||||||
// }
|
|
||||||
// String filePath = noCrimeCertificate.substring(0, noCrimeCertificate.lastIndexOf("/"));
|
|
||||||
// String fileName = noCrimeCertificate.substring(noCrimeCertificate.lastIndexOf("/") + 1);
|
|
||||||
// if (filePath.startsWith("/") || filePath.startsWith("\\")) {
|
|
||||||
// filePath = filePath.substring(1);
|
|
||||||
// }
|
|
||||||
// try {
|
|
||||||
// FileDownloader.downloadFile(url, upLoadPath + File.separator + filePath, fileName);
|
|
||||||
// mediaData.setNoCrimeCertificate(noCrimeCertificate);
|
|
||||||
// } catch (Exception e) {
|
|
||||||
// e.printStackTrace();
|
|
||||||
// MediaAsyncErrorLog mediaAsyncErrorLog = new MediaAsyncErrorLog();
|
|
||||||
// mediaAsyncErrorLog.setMediaid(noCrimeCertificate);
|
|
||||||
// mediaAsyncErrorLogService.save(mediaAsyncErrorLog);
|
|
||||||
// throw new RuntimeException("员工申请加入机构-无犯罪证明文件拉取错误,员工id" + dto.getEmployeeId());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// employeesApplyService.updateById(mediaData);
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -1394,6 +908,7 @@ public class EmployeesMQListener {
|
||||||
String izInit = dto.getIzInit();
|
String izInit = dto.getIzInit();
|
||||||
String izInitPassword = dto.getIzInitPassword();
|
String izInitPassword = dto.getIzInitPassword();
|
||||||
String employeeId = dto.getEmployeeId();
|
String employeeId = dto.getEmployeeId();
|
||||||
|
String headPath = dto.getHeadPath();
|
||||||
|
|
||||||
//需要初始化
|
//需要初始化
|
||||||
if (izInit.equals("Y")) {
|
if (izInit.equals("Y")) {
|
||||||
|
|
@ -1439,6 +954,7 @@ public class EmployeesMQListener {
|
||||||
j.put("opeType", "employee");
|
j.put("opeType", "employee");
|
||||||
j.put("o_c_", deptInfo.getString("code"));
|
j.put("o_c_", deptInfo.getString("code"));
|
||||||
j.put("employees_id", employeeId);
|
j.put("employees_id", employeeId);
|
||||||
|
j.put("head_path", headPath);
|
||||||
employeesApplyService.initialization(j);
|
employeesApplyService.initialization(j);
|
||||||
} else {
|
} else {
|
||||||
user.setUsername(employeesInfo.getTel());
|
user.setUsername(employeesInfo.getTel());
|
||||||
|
|
@ -1566,6 +1082,7 @@ public class EmployeesMQListener {
|
||||||
BeanUtils.copyProperties(user, sysUserMQDto);
|
BeanUtils.copyProperties(user, sysUserMQDto);
|
||||||
sysUserMQDto.setTargetOrgCode(dto.getTargetOrgCode());
|
sysUserMQDto.setTargetOrgCode(dto.getTargetOrgCode());
|
||||||
sysUserMQDto.setEmployeeId(user.getEmployeesId());
|
sysUserMQDto.setEmployeeId(user.getEmployeesId());
|
||||||
|
sysUserMQDto.setHeadPath(user.getAvatar());
|
||||||
rabbitMQUtil.sendToExchange("hldy.employees", "hldy.employeesorg.sysuser.info", sysUserMQDto);
|
rabbitMQUtil.sendToExchange("hldy.employees", "hldy.employeesorg.sysuser.info", sysUserMQDto);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -220,4 +220,6 @@ public class SysUser implements Serializable {
|
||||||
*/
|
*/
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private boolean izBindThird;
|
private boolean izBindThird;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private boolean headPath;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -164,6 +164,7 @@ public class SysUserApiImpl implements ISysUserAPI {
|
||||||
user.setPassword(passwordEncode);
|
user.setPassword(passwordEncode);
|
||||||
user.setStatus(1);
|
user.setStatus(1);
|
||||||
user.setDelFlag(CommonConstant.DEL_FLAG_0);
|
user.setDelFlag(CommonConstant.DEL_FLAG_0);
|
||||||
|
user.setAvatar(user.getHomePath());
|
||||||
//用户表字段org_code不能在这里设置他的值
|
//用户表字段org_code不能在这里设置他的值
|
||||||
// user.setOrgCode(null);
|
// user.setOrgCode(null);
|
||||||
// 保存用户走一个service 保证事务
|
// 保存用户走一个service 保证事务
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue