完成部分定时任务
This commit is contained in:
@@ -92,7 +92,8 @@ public class DecorationServiceImpl implements DecorationService {
|
||||
private UserAuthMappingService userAuthMappingService;
|
||||
@Resource
|
||||
private ShopInfoMapper shopInfoMapper;
|
||||
|
||||
@Resource
|
||||
private CommonService commonService;
|
||||
|
||||
@Override
|
||||
public DesignInfoVo DesignInfo(Long shopId) {
|
||||
@@ -130,12 +131,14 @@ public class DecorationServiceImpl implements DecorationService {
|
||||
flag++;
|
||||
}
|
||||
if (flag == CommonConstants.FOUR) {
|
||||
//如果设计阶段未完成
|
||||
if (!ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_91.getShopSubStageStatus().
|
||||
equals(shopStageInfoDAO.getShopSubStageInfo(shopId, ShopSubStageEnum.SHOP_STAGE_9).getShopSubStageStatus())) {
|
||||
//如果设计阶段进行中
|
||||
ShopStageInfoDO shopSubStageInfo = shopStageInfoDAO.getShopSubStageInfo(shopId, ShopSubStageEnum.SHOP_STAGE_9);
|
||||
if (ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_90.getShopSubStageStatus().equals(shopSubStageInfo.getShopSubStageStatus())) {
|
||||
//更新设计阶段状态完成//初始化装修款阶段
|
||||
shopStageInfoDAO.batchUpdateShopStageStatus(shopId, Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_91,
|
||||
ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_100));
|
||||
LineInfoDO lineInfo = lineInfoMapper.getByLineId(shopSubStageInfo.getLineId());
|
||||
commonService.sendSms(lineInfo.getMobile(), SMSMsgEnum.DECORATION_MODEL_PAY, null);
|
||||
}
|
||||
}
|
||||
return designInfoVo;
|
||||
|
||||
@@ -222,21 +222,30 @@ public class PreparationServiceImpl implements PreparationService {
|
||||
List<ShopStageInfoDO> shopStageInfo = shopStageInfoDAO.getShopStageInfo(shopId, ShopStageEnum.SHOP_STAGE_2.getShopStage());
|
||||
Map<Integer, ShopStageInfoDO> collect = shopStageInfo.stream().collect(Collectors.toMap(ShopStageInfoDO::getShopSubStage, Function.identity()));
|
||||
//设计
|
||||
if (!ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_91.getShopSubStageStatus().
|
||||
equals(collect.get(ShopSubStageEnum.SHOP_STAGE_9.getShopSubStage()).getShopSubStageStatus())) {
|
||||
Boolean flushFlag = Boolean.FALSE;
|
||||
Integer Status900 = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_90.getShopSubStageStatus();
|
||||
Integer Design = collect.get(ShopSubStageEnum.SHOP_STAGE_9.getShopSubStage()).getShopSubStageStatus();
|
||||
if (Status900.equals(Design)) {
|
||||
decorationService.DesignInfo(shopId);
|
||||
flushFlag = Boolean.TRUE;
|
||||
}
|
||||
//装修款
|
||||
if (!ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_102.getShopSubStageStatus().
|
||||
equals(collect.get(ShopSubStageEnum.SHOP_STAGE_10.getShopSubStage()).getShopSubStageStatus())) {
|
||||
Integer Status1000 = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_100.getShopSubStageStatus();
|
||||
Integer Status1010 = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_101.getShopSubStageStatus();
|
||||
Integer DecorationModel = collect.get(ShopSubStageEnum.SHOP_STAGE_10.getShopSubStage()).getShopSubStageStatus();
|
||||
if (Status1000.equals(DecorationModel) || Status1010.equals(DecorationModel)) {
|
||||
decorationService.getDecorationModel(shopId, null);
|
||||
flushFlag = Boolean.TRUE;
|
||||
}
|
||||
//施工阶段
|
||||
if (!ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_112.getShopSubStageStatus().
|
||||
equals(collect.get(ShopSubStageEnum.SHOP_STAGE_11.getShopSubStage()).getShopSubStageStatus())) {
|
||||
Integer Status1100 = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_110.getShopSubStageStatus();
|
||||
Integer Status1110 = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_111.getShopSubStageStatus();
|
||||
Integer Construction = collect.get(ShopSubStageEnum.SHOP_STAGE_11.getShopSubStage()).getShopSubStageStatus();
|
||||
if (Status1110.equals(Construction) || Status1100.equals(Construction)) {
|
||||
decorationService.getConstructionInfo(shopId);
|
||||
flushFlag = Boolean.TRUE;
|
||||
}
|
||||
return Boolean.TRUE;
|
||||
return flushFlag;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user