Merge remote-tracking branch 'origin/cc_partner_init' into cc_partner_init
This commit is contained in:
@@ -148,7 +148,7 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
|
||||
}
|
||||
//2.未查到证照信息,所以查询鲜丰的默认值(只要鲜丰接口内有值,总是优先使用鲜丰数据)
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
||||
if (Objects.nonNull(shopInfoDO.getStoreNum())) {
|
||||
if (Objects.nonNull(shopInfoDO.getStoreNum()) && StringUtil.isNotBlank(shopInfoDO.getStoreNum())) {
|
||||
GetStoreInfoByCodeResponse storeInfoCode = coolStoreStartFlowService.getStoreInfoCode(shopInfoDO.getStoreNum());
|
||||
if (Objects.nonNull(storeInfoCode.getData().getStoreDocument()) && storeInfoCode.getCode() == 0) {
|
||||
//替换落库的值
|
||||
@@ -174,11 +174,13 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
|
||||
return new PageInfo<>();
|
||||
}
|
||||
List<RegionDO> fightRegion = regionDao.getFightRegionByRegionIds(regionIds);
|
||||
List<String> fightRegionIds = fightRegion.stream().map(RegionDO::getRegionId).collect(Collectors.toList());
|
||||
if (CollectionUtils.isEmpty(fightRegion)) {
|
||||
return new PageInfo<>();
|
||||
}
|
||||
|
||||
PageHelper.startPage(request.getPageNum(), request.getPageSize());
|
||||
licenseListResponses = applyLicenseMapper.licenseList(request, null, fightRegion);
|
||||
licenseListResponses = applyLicenseMapper.licenseList(request, null, fightRegionIds);
|
||||
} else {
|
||||
PageHelper.startPage(request.getPageNum(), request.getPageSize());
|
||||
licenseListResponses = applyLicenseMapper.licenseList(request, user.getUserId(), null);
|
||||
@@ -231,7 +233,6 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
|
||||
licenseTransactDO.setSubmitStatus(2);
|
||||
shopAuditInfoDO.setRejectReason(result);
|
||||
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_42;
|
||||
licenseTransactDO.setDeleted(Constants.ONE_INTEGER);
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
||||
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
commonService.sendSms(lineInfoDO.getMobile(), SMSMsgEnum.LICENSE_NOT_PASS);
|
||||
|
||||
@@ -500,7 +500,8 @@ public class EmployeeTrainingServiceImpl implements EmployeeTrainingService {
|
||||
employeeTrainingDAO.updateByPrimaryKeySelective(employeeTrainingDO);
|
||||
}
|
||||
}
|
||||
|
||||
assessmentUserTrainingVO.setAssessmentNum(employeeTrainingDO.getAssessmentNum());
|
||||
assessmentUserTrainingVO.setAssessmentTotalNum(employeeTrainingDO.getAssessmentTotalNum());
|
||||
assessmentUserTrainingVO.setPracticalExamScore(employeeTrainingDO.getPracticalExamScore());
|
||||
assessmentUserTrainingVO.setPracticalExamStatus(employeeTrainingDO.getPracticalExamStatus());
|
||||
assessmentUserTrainingVO.setId(tempUserDetailDO.getId());
|
||||
@@ -567,6 +568,7 @@ public class EmployeeTrainingServiceImpl implements EmployeeTrainingService {
|
||||
employeeTrainingDAO.updateByPrimaryKeySelective(employeeTrainingDO);
|
||||
}
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public void assessmentUserCommit(EmployeeAssessmentCommitListRequest request) {
|
||||
if (CollectionUtils.isEmpty(request.getList())) {
|
||||
@@ -594,7 +596,7 @@ public class EmployeeTrainingServiceImpl implements EmployeeTrainingService {
|
||||
if (item.getId() != null) {
|
||||
assessmentDataDO = assessmentDataDAO.selectByPrimaryKey(item.getId());
|
||||
} else {
|
||||
assessmentDataDO = assessmentDataDAO.selectByTemplateId(item.getTemplateId(), employeeTrainingDO.getXfsgUserDetailId().toString(), item.getShopId());
|
||||
assessmentDataDO = assessmentDataDAO.selectByTemplateId(item.getTemplateId(), userId, item.getShopId());
|
||||
}
|
||||
if (assessmentDataDO != null) {
|
||||
assessmentDataDO.setScore(item.getScore());
|
||||
@@ -607,7 +609,7 @@ public class EmployeeTrainingServiceImpl implements EmployeeTrainingService {
|
||||
assessmentDataDO.setShopId(item.getShopId());
|
||||
assessmentDataDO.setComments(item.getComments());
|
||||
assessmentDataDO.setScore(item.getScore());
|
||||
assessmentDataDO.setAssessmentUserId(employeeTrainingDO.getXfsgUserDetailId().toString());
|
||||
assessmentDataDO.setAssessmentUserId(userId);
|
||||
assessmentDataDO.setPicture(item.getPicture());
|
||||
assessmentDataDO.setVideo(item.getVideo());
|
||||
assessmentDataDAO.insertSelective(assessmentDataDO);
|
||||
@@ -622,7 +624,7 @@ public class EmployeeTrainingServiceImpl implements EmployeeTrainingService {
|
||||
if (totalScore.get().intValue() > CommonConstants.NINETY) {
|
||||
employeeTrainingDO.setPracticalExamStatus(1);
|
||||
} else {
|
||||
employeeTrainingDO.setPracticalExamStatus(0);
|
||||
employeeTrainingDO.setPracticalExamStatus(2);
|
||||
}
|
||||
employeeTrainingDO.setPracticalExamScore(totalScore.get().intValue());
|
||||
employeeTrainingDO.setActualAssessmentTime(new Date());
|
||||
|
||||
@@ -121,7 +121,7 @@ public class LinePayServiceImpl implements LinePayService {
|
||||
} else {
|
||||
fillLinePay(Boolean.FALSE, linePayDO, request, partnerUser);
|
||||
linePayDAO.updateLinePay(linePayDO);
|
||||
return null;
|
||||
return linePayDO.getId();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -959,11 +959,15 @@ public class PointServiceImpl implements PointService {
|
||||
commonService.sendSms(lineInfo.getMobile(),SMSMsgEnum.LICENSE_SUBMITTED);
|
||||
//发送工作通知
|
||||
Map<String, String> requestMap = new HashMap<>();
|
||||
requestMap.put("storeName",shopInfo.getShopName());
|
||||
requestMap.put("partnerName",lineInfo.getUsername());
|
||||
requestMap.put("partnerMobile",lineInfo.getMobile());
|
||||
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);
|
||||
}
|
||||
|
||||
@@ -194,17 +194,20 @@ public class PreparationServiceImpl implements PreparationService {
|
||||
data2.setShopSubStageStatus(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_110.getShopSubStageStatus());
|
||||
list.add(data2);
|
||||
//初始化xfsg_acceptance_info表
|
||||
AcceptanceInfoDO acceptanceInfoDO1 = acceptanceInfoDAO.selectByShopId(shopId);
|
||||
AcceptanceInfoDO acceptanceInfoDO = new AcceptanceInfoDO();
|
||||
acceptanceInfoDO.setShopId(shopId);
|
||||
acceptanceInfoDO.setCreateTime(new Date());
|
||||
acceptanceInfoDAO.insertSelectiveAcceptanceInfo(acceptanceInfoDO);
|
||||
if(Objects.isNull(acceptanceInfoDO1)) {
|
||||
acceptanceInfoDAO.insertSelectiveAcceptanceInfo(acceptanceInfoDO);
|
||||
}
|
||||
ShopStageInfoDO data3 = shopStageInfoDOMap.get(ShopSubStageEnum.SHOP_STAGE_14.getShopSubStage());
|
||||
data3.setShopSubStageStatus(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_140.getShopSubStageStatus());
|
||||
list.add(data3);
|
||||
//发送督导钉钉
|
||||
Map<String, String> messageMap = new HashMap<>();
|
||||
messageMap.put("storeName",shopInfo.getShopName());
|
||||
messageMap.put("shopId",shopId.toString());
|
||||
messageMap.put("shopId",String.valueOf(shopId));
|
||||
messageMap.put("lineId", shopInfo.getLineId().toString());
|
||||
messageMap.put("partnerUsername",lineInfo.getUsername());
|
||||
messageMap.put("shopName",shopInfo.getShopName());
|
||||
@@ -216,9 +219,9 @@ public class PreparationServiceImpl implements PreparationService {
|
||||
//发送督导钉钉
|
||||
Map<String, String> messageMap1 = new HashMap<>();
|
||||
messageMap1.put("storeName",shopInfo.getShopName());
|
||||
messageMap1.put("shopId",shopId.toString());
|
||||
messageMap1.put("shopId",String.valueOf(shopId));
|
||||
messageMap1.put("shopName",shopInfo.getShopName());
|
||||
messageMap1.put("lineId", shopInfo.getLineId().toString());
|
||||
messageMap1.put("lineId", String.valueOf(shopInfo.getLineId()));
|
||||
messageMap1.put("partnerUsername",lineInfo.getUsername());
|
||||
messageMap1.put("partnerMobile",lineInfo.getMobile());
|
||||
commonService.sendMessage(Arrays.asList(shopInfo.getSupervisorUserId()), MessageEnum.MESSAGE_27, messageMap1);
|
||||
@@ -236,8 +239,8 @@ public class PreparationServiceImpl implements PreparationService {
|
||||
openAcceptanceInfoDO.setShopId(shopId);
|
||||
openAcceptanceInfoDO.setAcceptanceStatus(CommonConstants.ZERO);
|
||||
openAcceptanceInfoDAO.insertSelective(openAcceptanceInfoDO);
|
||||
shopStageInfoDAO.updateShopStageInfo(shopId, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_160);
|
||||
}
|
||||
shopStageInfoDAO.updateShopStageInfo(shopId, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_160);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -97,6 +97,11 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
if (Constants.ZERO_INTEGER.equals(request.getAuditResult())) {
|
||||
shopAuditInfoDO.setResultType(Constants.ONE_INTEGER);
|
||||
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<>();
|
||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
||||
LineInfoDO lineInfo = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
@@ -105,11 +110,6 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
requestMap.put("partnerMobile", lineInfo.getMobile());
|
||||
requestMap.put("lineId", String.valueOf(lineInfo.getId()));
|
||||
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);
|
||||
Long auditId = shopAuditInfoDO.getId();
|
||||
@@ -292,11 +292,11 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
@Override
|
||||
public AddSignFranchiseResponse getSignFranchise(Long shopId) {
|
||||
SignFranchiseDO signFranchiseDO = signFranchiseMapper.selectByShopId(shopId);
|
||||
if (Objects.isNull(signFranchiseDO)) {
|
||||
throw new ServiceException(ErrorCodeEnum.SIGN_FRANCHISE_NOT_FOUND);
|
||||
}
|
||||
AddSignFranchiseResponse response = from(signFranchiseDO, shopId);
|
||||
ShopAuditInfoDO shopAuditInfoDO = shopAuditInfoMapper.selectByPrimaryKey(signFranchiseDO.getAuditId());
|
||||
ShopAuditInfoDO shopAuditInfoDO = null;
|
||||
if (Objects.nonNull(signFranchiseDO)) {
|
||||
shopAuditInfoDO = shopAuditInfoMapper.selectByPrimaryKey(signFranchiseDO.getAuditId());
|
||||
}
|
||||
if (Objects.nonNull(shopAuditInfoDO)) {
|
||||
response.setStatus(shopAuditInfoDO.getResultType());
|
||||
if (shopAuditInfoDO.getResultType() == 0) {
|
||||
@@ -340,7 +340,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
addSignFranchiseResponse.setIsBusinessLicense(signFranchiseDO.getIsBusinessLicense());
|
||||
addSignFranchiseResponse.setIsFoodLicense(signFranchiseDO.getIsFoodLicense());
|
||||
addSignFranchiseResponse.setContractStartTime(signFranchiseDO.getContractStartTime());
|
||||
addSignFranchiseResponse.setContractStartEndTime(signFranchiseDO.getContractStartEndTime());
|
||||
addSignFranchiseResponse.setContractStartEndTime(signFranchiseDO.getContractEndTime());
|
||||
addSignFranchiseResponse.setImpressionNum(signFranchiseDO.getImpressionNum());
|
||||
addSignFranchiseResponse.setBusinessStartHours(signFranchiseDO.getBusinessStartHours());
|
||||
addSignFranchiseResponse.setBusinessEndHours(signFranchiseDO.getBusinessEndHours());
|
||||
@@ -372,6 +372,8 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
|
||||
addSignFranchiseResponse.setLicenseName(licenseTransactDO.getBusinessLicense());
|
||||
addSignFranchiseResponse.setOpeAddress(licenseTransactDO.getLicenseAddress());
|
||||
addSignFranchiseResponse.setOperator(licenseTransactDO.getOperator());
|
||||
addSignFranchiseResponse.setLicenseCode(licenseTransactDO.getCreditCode());
|
||||
addSignFranchiseResponse.setType(LicenseTypeEnum.match(licenseTransactDO.getLicenseType()).getMessage());
|
||||
}
|
||||
if (Objects.nonNull(lineInfoDO)) {
|
||||
addSignFranchiseResponse.setPartnerName(lineInfoDO.getUsername());
|
||||
|
||||
@@ -404,6 +404,11 @@ public class SysStoreAppServiceImpl implements SysStoreAppService, AuditResultSe
|
||||
ShopSubStageStatusEnum shopSubStageStatusEnum = null;
|
||||
//1.成功/失败原因
|
||||
try {
|
||||
//删除上次提交数据
|
||||
ShopAuditInfoDO deleteShopAuditDo = shopAuditInfoMapper.selectBykeyAndType(shopId);
|
||||
deleteShopAuditDo.setDeleted(false);
|
||||
shopAuditInfoMapper.updateByPrimaryKeySelective(deleteShopAuditDo);
|
||||
//新增本次数据
|
||||
shopAuditInfoDO.setShopId(shopId);
|
||||
shopAuditInfoDO.setAuditType(AuditTypeEnum.SYS_BUILD.getCode());
|
||||
shopAuditInfoDO.setSubmittedUserId("");
|
||||
@@ -425,7 +430,6 @@ public class SysStoreAppServiceImpl implements SysStoreAppService, AuditResultSe
|
||||
preparationService.contractAndBuildStoreCompletion(shopId);
|
||||
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
|
||||
commonService.sendSms(lineInfoDO.getMobile(), SMSMsgEnum.SYS_BUILD_STORE_DONE);
|
||||
|
||||
// 异步处理
|
||||
simpleMessageService.send(JSONObject.toJSONString(shopInfoDO), RocketMqTagEnum.SYNC_TRAINING_SHOP_PERSON);
|
||||
}
|
||||
|
||||
@@ -190,11 +190,11 @@ public class TempUserDetailServiceImpl implements TempUserDetailService {
|
||||
public void registrationCompleted(Long shopId) {
|
||||
ShopStageInfoDO shopStageInfoDO = shopStageInfoDAO.getShopSubStageInfo(shopId, ShopSubStageEnum.SHOP_STAGE_5);
|
||||
if(shopStageInfoDO != null){
|
||||
shopStageInfoDO.setShopSubStageStatus(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_51.getShopSubStageStatus());
|
||||
shopStageInfoDAO.batchUpdate(Collections.singletonList(shopStageInfoDO));
|
||||
shopStageInfoDAO.updateShopStageInfo(shopId, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_51);
|
||||
//状态结束
|
||||
preparationService.whetherToOpenForAcceptance(shopId);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ public class YlfServiceImpl implements YlfService {
|
||||
if (status != 200) {
|
||||
String msg = (String) JSONObject.parseObject(forObject, JSONObject.class).get("msg");
|
||||
log.info("获取云立方装修公司信息失败,id:{}", id);
|
||||
throw new ServiceException(ErrorCodeEnum.YLF_ERROR,msg);
|
||||
throw new ServiceException(msg);
|
||||
}
|
||||
Object data = JSONObject.parseObject(forObject, JSONObject.class).get("data");
|
||||
if (data == null) {
|
||||
@@ -53,7 +53,7 @@ public class YlfServiceImpl implements YlfService {
|
||||
return list.get(0);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
throw new ServiceException(((ServiceException)e).getErrorMessage());
|
||||
throw new ServiceException(ErrorCodeEnum.YLF_ERROR,((ServiceException)e).getErrorMessage());
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@@ -73,7 +73,7 @@ public class YlfServiceImpl implements YlfService {
|
||||
if (status != 200) {
|
||||
log.info("获取云立方装修公司信息失败,storeNum:{}", storeNum);
|
||||
String msg = (String) jsonObject.get("msg");
|
||||
throw new ServiceException(ErrorCodeEnum.YLF_ERROR,msg);
|
||||
throw new ServiceException(msg);
|
||||
}
|
||||
JSONObject data = jsonObject.getJSONObject("data");
|
||||
log.info("CoolStoreStartFlowServiceImpl#getOrder,jsonObject:{}", jsonObject);
|
||||
@@ -95,7 +95,7 @@ public class YlfServiceImpl implements YlfService {
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.info("调用云立方获取项目列表异常,getProjectList error:{}", e);
|
||||
throw new ServiceException(((ServiceException)e).getErrorMessage());
|
||||
throw new ServiceException(ErrorCodeEnum.YLF_ERROR,((ServiceException)e).getErrorMessage());
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user