细节优化

This commit is contained in:
guohb
2024-05-15 10:47:11 +08:00
parent 47988b4e33
commit 4766d58782
4 changed files with 17 additions and 8 deletions

View File

@@ -32,6 +32,7 @@ public enum MessageEnum {
MESSAGE_14("已为您分配一位加盟商,请查收", "##### 加盟商姓名:${partnerUsername}\n##### 手机号码:${partnerMobile}\n##### 意向加盟区域:${wantShopName}\n"), MESSAGE_14("已为您分配一位加盟商,请查收", "##### 加盟商姓名:${partnerUsername}\n##### 手机号码:${partnerMobile}\n##### 意向加盟区域:${wantShopName}\n"),
MESSAGE_15("您有一份加盟商上传的租赁合同待审核,请查收", "##### 加盟商姓名:${partnerUsername}\n##### 提交时间:${submitTime}\n"), MESSAGE_15("您有一份加盟商上传的租赁合同待审核,请查收", "##### 加盟商姓名:${partnerUsername}\n##### 提交时间:${submitTime}\n"),
MESSAGE_16("您有一家门店待提交系统建店申请,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"), MESSAGE_16("您有一家门店待提交系统建店申请,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
MESSAGE_16_1("您有一家门店待提交系统建店申请,请查收", "##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
MESSAGE_17("您收到一份证照信息审核申请,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"), MESSAGE_17("您收到一份证照信息审核申请,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
MESSAGE_18("您有一个门店已缴纳加盟费/保证金,请审核", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"), MESSAGE_18("您有一个门店已缴纳加盟费/保证金,请审核", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),
MESSAGE_19("您有一个门店待提交加盟合同审核,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"), MESSAGE_19("您有一个门店待提交加盟合同审核,请查收", "##### 门店名称:${storeName}\n##### 加盟商姓名:${partnerName}\n##### 加盟商手机号码:${partnerMobile}\n"),

View File

@@ -959,11 +959,15 @@ public class PointServiceImpl implements PointService {
commonService.sendSms(lineInfo.getMobile(),SMSMsgEnum.LICENSE_SUBMITTED); commonService.sendSms(lineInfo.getMobile(),SMSMsgEnum.LICENSE_SUBMITTED);
//发送工作通知 //发送工作通知
Map<String, String> requestMap = new HashMap<>(); Map<String, String> requestMap = new HashMap<>();
requestMap.put("storeName",shopInfo.getShopName());
requestMap.put("partnerName",lineInfo.getUsername()); requestMap.put("partnerName",lineInfo.getUsername());
requestMap.put("partnerMobile",lineInfo.getMobile()); requestMap.put("partnerMobile",lineInfo.getMobile());
requestMap.put("lineId",String.valueOf(lineInfo.getId())); requestMap.put("lineId",String.valueOf(lineInfo.getId()));
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()),MessageEnum.MESSAGE_16,requestMap); if (Objects.nonNull(shopInfo.getShopName())) {
requestMap.put("storeName",shopInfo.getShopName());
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()),MessageEnum.MESSAGE_16,requestMap);
}else {
commonService.sendMessage(Arrays.asList(lineInfo.getInvestmentManager()),MessageEnum.MESSAGE_16_1,requestMap);
}
} }
return shopStageInfoDAO.updateShopStageAndAuditInfo(shopId, subStageStatus, auditId); return shopStageInfoDAO.updateShopStageAndAuditInfo(shopId, subStageStatus, auditId);
} }

View File

@@ -97,6 +97,11 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
if (Constants.ZERO_INTEGER.equals(request.getAuditResult())) { if (Constants.ZERO_INTEGER.equals(request.getAuditResult())) {
shopAuditInfoDO.setResultType(Constants.ONE_INTEGER); shopAuditInfoDO.setResultType(Constants.ONE_INTEGER);
shopAuditInfoDO.setRejectReason(request.getCause()); shopAuditInfoDO.setRejectReason(request.getCause());
} else if (Constants.ONE_INTEGER.equals(request.getAuditResult())) {
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
shopAuditInfoDO.setPassReason(request.getCause());
//校验建店与加盟签约合同是否完成 并初始化后续流程数据
preparationService.contractAndBuildStoreCompletion(shopId);
Map<String, String> requestMap = new HashMap<>(); Map<String, String> requestMap = new HashMap<>();
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId); ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
LineInfoDO lineInfo = lineInfoMapper.getByLineId(shopInfoDO.getLineId()); LineInfoDO lineInfo = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
@@ -105,11 +110,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
requestMap.put("partnerMobile", lineInfo.getMobile()); requestMap.put("partnerMobile", lineInfo.getMobile());
requestMap.put("lineId", String.valueOf(lineInfo.getId())); requestMap.put("lineId", String.valueOf(lineInfo.getId()));
commonService.sendMessage(Collections.singletonList(lineInfo.getInvestmentManager()), MessageEnum.MESSAGE_19, requestMap); commonService.sendMessage(Collections.singletonList(lineInfo.getInvestmentManager()), MessageEnum.MESSAGE_19, requestMap);
} else if (Constants.ONE_INTEGER.equals(request.getAuditResult())) {
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
shopAuditInfoDO.setPassReason(request.getCause());
//校验建店与加盟签约合同是否完成 并初始化后续流程数据
preparationService.contractAndBuildStoreCompletion(shopId);
} }
shopAuditInfoMapper.insertSelective(shopAuditInfoDO); shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
Long auditId = shopAuditInfoDO.getId(); Long auditId = shopAuditInfoDO.getId();

View File

@@ -404,6 +404,11 @@ public class SysStoreAppServiceImpl implements SysStoreAppService, AuditResultSe
ShopSubStageStatusEnum shopSubStageStatusEnum = null; ShopSubStageStatusEnum shopSubStageStatusEnum = null;
//1.成功/失败原因 //1.成功/失败原因
try { try {
//删除上次提交数据
ShopAuditInfoDO deleteShopAuditDo = shopAuditInfoMapper.selectBykeyAndType(shopId);
deleteShopAuditDo.setDeleted(false);
shopAuditInfoMapper.updateByPrimaryKeySelective(deleteShopAuditDo);
//新增本次数据
shopAuditInfoDO.setShopId(shopId); shopAuditInfoDO.setShopId(shopId);
shopAuditInfoDO.setAuditType(AuditTypeEnum.SYS_BUILD.getCode()); shopAuditInfoDO.setAuditType(AuditTypeEnum.SYS_BUILD.getCode());
shopAuditInfoDO.setSubmittedUserId(""); shopAuditInfoDO.setSubmittedUserId("");
@@ -425,7 +430,6 @@ public class SysStoreAppServiceImpl implements SysStoreAppService, AuditResultSe
preparationService.contractAndBuildStoreCompletion(shopId); preparationService.contractAndBuildStoreCompletion(shopId);
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId()); LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
commonService.sendSms(lineInfoDO.getMobile(), SMSMsgEnum.SYS_BUILD_STORE_DONE); commonService.sendSms(lineInfoDO.getMobile(), SMSMsgEnum.SYS_BUILD_STORE_DONE);
// 异步处理 // 异步处理
simpleMessageService.send(JSONObject.toJSONString(shopInfoDO), RocketMqTagEnum.SYNC_TRAINING_SHOP_PERSON); simpleMessageService.send(JSONObject.toJSONString(shopInfoDO), RocketMqTagEnum.SYNC_TRAINING_SHOP_PERSON);
} }