fix:加盟合同财务阶段 财务之后推送 默认一小时自动分配
This commit is contained in:
@@ -257,9 +257,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
operationLogService.addOperationLog(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83,
|
||||
user.getUserId(), auditFranchiseFeeUsers,
|
||||
OperationTypeEnum.OPERATION_TYPE_1, "加盟签约合同审批", OperationStatusEnum.NOT_PROCESSED, 1);
|
||||
operationLogService.addOperationLog(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83_5,
|
||||
user.getUserId(), financeUsers,
|
||||
OperationTypeEnum.OPERATION_TYPE_1, "加盟签约合同财务审批", OperationStatusEnum.NOT_PROCESSED, 2);
|
||||
} else {
|
||||
//修改签约人信息
|
||||
signFranchiseMapper.updateByPrimaryKeySelective(signFranchiseDO);
|
||||
@@ -337,9 +334,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
operationLogService.addOperationLog(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83,
|
||||
user.getUserId(), userIds,
|
||||
OperationTypeEnum.OPERATION_TYPE_1, "加盟签约合同审批", OperationStatusEnum.NOT_PROCESSED, 1);
|
||||
operationLogService.addOperationLog(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83_5,
|
||||
user.getUserId(), financeUsers,
|
||||
OperationTypeEnum.OPERATION_TYPE_1, "加盟签约合同财务审批", OperationStatusEnum.NOT_PROCESSED, 2);
|
||||
return Boolean.TRUE;
|
||||
}
|
||||
|
||||
@@ -464,6 +458,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
shopAuditInfoDO.setSubmittedUserId(user.getUserId());
|
||||
shopAuditInfoDO.setSubmittedUserName(user.getName());
|
||||
//驳回
|
||||
ContractCallbackDTO contractCallbackDTO = null;
|
||||
if (Constants.ZERO_INTEGER.equals(request.getAuditResult())) {
|
||||
auditReject(request, shopAuditInfoDO, shopInfoDO);
|
||||
} else if (Constants.ONE_INTEGER.equals(request.getAuditResult())) {
|
||||
@@ -472,7 +467,8 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
//更新状态为加盟商
|
||||
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
shopStageInfoDAO.updateShopStageInfo(shopId, SHOP_SUB_STAGE_STATUS_83_5);
|
||||
|
||||
//推送数据
|
||||
contractCallbackDTO = pushContractRequest(shopInfoDO, request.getShopId());
|
||||
Boolean sendNotice = Boolean.TRUE;
|
||||
if (sendNotice) {
|
||||
HashMap<String, String> map = new HashMap<>();
|
||||
@@ -484,6 +480,9 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
if (Objects.nonNull(userDOList)) {
|
||||
finances.addAll(userDOList.stream().map(EnterpriseUserDO::getUserId).collect(Collectors.toList()));
|
||||
}
|
||||
operationLogService.addOperationLog(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83_5,
|
||||
user.getUserId(), userDOList,
|
||||
OperationTypeEnum.OPERATION_TYPE_1, "加盟签约合同财务审批", OperationStatusEnum.NOT_PROCESSED, 2);
|
||||
commonService.sendQWMessage(finances,
|
||||
MessageEnum.MESSAGE_19_1,
|
||||
map);
|
||||
@@ -491,7 +490,11 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
}
|
||||
shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
|
||||
Long auditId = shopAuditInfoDO.getId();
|
||||
signFranchiseDAO.updateAuditByShopId(auditId, shopId);
|
||||
if (contractCallbackDTO != null && StringUtils.isNotEmpty(contractCallbackDTO.getStoreCode())) {
|
||||
shopInfoDO.setShopCode(contractCallbackDTO.getStoreCode());
|
||||
shopInfoMapper.updateByPrimaryKeySelective(shopInfoDO);
|
||||
}
|
||||
signFranchiseDAO.updateAuditByShopId(auditId, shopId, contractCallbackDTO);
|
||||
//审批记录表记录
|
||||
List<OperationLogDO> operationLogs = operationLogDAO.getBySubStageStatusEnumAndsStatus(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83, OperationTypeEnum.OPERATION_TYPE_1.getCode());
|
||||
operationLogService.batchUpdateProcessed(operationLogs, auditId, user.getUserId(), request.getCause());
|
||||
@@ -557,7 +560,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
shopAuditInfoDO.setSubmittedUserId(user.getUserId());
|
||||
shopAuditInfoDO.setSubmittedUserName(user.getName());
|
||||
//驳回
|
||||
ContractCallbackDTO contractCallbackDTO = null;
|
||||
if (Constants.ZERO_INTEGER.equals(request.getAuditResult())) {
|
||||
auditReject(request, shopAuditInfoDO, shopInfoDO);
|
||||
} else if (Constants.ONE_INTEGER.equals(request.getAuditResult())) {
|
||||
@@ -590,7 +592,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
shopDecorationAssignDO.setShopId(shopId);
|
||||
shopDecorationAssignDAO.insert(shopDecorationAssignDO);
|
||||
//新增一个延迟队列 四个小时之后确定是否手动分配 没有手动分配 直接自动分配 红圈通推送和下一个流程开始改为分配团队之后 触发
|
||||
simpleMessageService.send(String.valueOf(shopDecorationAssignDO.getId()), RocketMqTagEnum.DELAY_SHOP_DECORATION_ASSIGN, System.currentTimeMillis() + 4 * 60 * 60 * 1000);
|
||||
simpleMessageService.send(String.valueOf(shopDecorationAssignDO.getId()), RocketMqTagEnum.DELAY_SHOP_DECORATION_ASSIGN, System.currentTimeMillis() + 1 * 60 * 60 * 1000);
|
||||
}
|
||||
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
|
||||
shopAuditInfoDO.setPassReason(request.getCause());
|
||||
@@ -616,8 +618,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
preparationService.contractAndBuildStoreCompletion(request.getShopId());
|
||||
}
|
||||
|
||||
//推送数据
|
||||
contractCallbackDTO = pushContractRequest(shopInfoDO, request.getShopId());
|
||||
|
||||
Boolean sendNotice = Boolean.TRUE;
|
||||
commonService.sendSms(lineInfoDO.getMobile(), SMSMsgEnum.SIGN_CONTRACT);
|
||||
@@ -633,11 +633,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
}
|
||||
shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
|
||||
Long auditId = shopAuditInfoDO.getId();
|
||||
if (contractCallbackDTO != null && StringUtils.isNotEmpty(contractCallbackDTO.getStoreCode())) {
|
||||
shopInfoDO.setShopCode(contractCallbackDTO.getStoreCode());
|
||||
shopInfoMapper.updateByPrimaryKeySelective(shopInfoDO);
|
||||
}
|
||||
signFranchiseDAO.updateAuditByShopId(auditId, shopId, contractCallbackDTO);
|
||||
signFranchiseDAO.updateAuditByShopId(auditId, shopId);
|
||||
//审批记录表记录
|
||||
List<OperationLogDO> operationLogs = operationLogDAO.getBySubStageStatusEnumAndsStatus(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83_5, OperationTypeEnum.OPERATION_TYPE_1.getCode());
|
||||
operationLogService.batchUpdateProcessed(operationLogs, auditId, user.getUserId(), request.getCause());
|
||||
|
||||
Reference in New Issue
Block a user