Browse Source

优化了新增企业的时候二维码生成方法

dev-V1.0.6
vincent 2 months ago
parent
commit
715a3a20ce
  1. 5
      zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EnterpriseInformationServiceImpl.java

5
zdxt-modules/zdxt-enforcement-code/src/main/java/com/zdxt/enforcementcode/service/impl/EnterpriseInformationServiceImpl.java

@ -407,7 +407,8 @@ public class EnterpriseInformationServiceImpl implements IEnterpriseInformationS
// 4. 仅在新增成功时生成二维码 // 4. 仅在新增成功时生成二维码
if (!isUpdate && result > 0) { if (!isUpdate && result > 0) {
generateQrCodeForNewEnterprise(enterpriseInformation); // generateQrCodeForNewEnterprise(enterpriseInformation);
generateQrCode("zfjd", enterpriseInformation.getEnterpriseNumber(), "enterprise", "企业登记");
} }
return result; return result;
@ -462,6 +463,7 @@ public class EnterpriseInformationServiceImpl implements IEnterpriseInformationS
String qrContent = JSONObject.toJSONString(jsonMap); String qrContent = JSONObject.toJSONString(jsonMap);
try { try {
// 生成二维码文件 // 生成二维码文件
String logoPath = ruoYiConfig.getFile().getQrCodeUrl(); String logoPath = ruoYiConfig.getFile().getQrCodeUrl();
String uploadPath = ruoYiConfig.getFile().getUploadPath(); String uploadPath = ruoYiConfig.getFile().getUploadPath();
@ -476,6 +478,7 @@ public class EnterpriseInformationServiceImpl implements IEnterpriseInformationS
qrCodeHistory.setId(uuid); qrCodeHistory.setId(uuid);
qrCodeHistory.setGenerateTime(DateUtils.getNowDate()); qrCodeHistory.setGenerateTime(DateUtils.getNowDate());
qrCodeHistory.setQrCodeUrl(qrCodeUrl); qrCodeHistory.setQrCodeUrl(qrCodeUrl);
qrCodeHistory.setStatus(0L);
qrCodeHistory.setEnterpriseNumber(enterpriseInformation.getEnterpriseNumber()); qrCodeHistory.setEnterpriseNumber(enterpriseInformation.getEnterpriseNumber());
qrCodeHistory.setReasonsChange("企业登记"); qrCodeHistory.setReasonsChange("企业登记");
qrCodeGenerateHistoryService.insertByBo(qrCodeHistory); qrCodeGenerateHistoryService.insertByBo(qrCodeHistory);

Loading…
Cancel
Save