|
|
@ -2,7 +2,9 @@ package com.jwtech.quartz.task; |
|
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil; |
|
|
|
import cn.hutool.core.util.ObjectUtil; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.jwtech.util.StringUtil; |
|
|
|
import com.kms.build.domain.*; |
|
|
|
import com.kms.build.mapper.*; |
|
|
|
import com.kms.build.service.*; |
|
|
@ -59,6 +61,9 @@ public class evaluateTask { |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private BsSgcjsjdBuiProInfoService bsSgcjsjdBuiProInfoService; |
|
|
|
@Autowired |
|
|
|
private BsSgcJsjdBuiDedicatedAccountMapper bsSgcJsjdBuiDedicatedAccountMapper; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// @Scheduled(cron = "0 1 0 * * ?") //每天0点1分执行
|
|
|
@ -397,10 +402,35 @@ public class evaluateTask { |
|
|
|
} |
|
|
|
|
|
|
|
//若在工程施工合同签订之日起30日后未开设
|
|
|
|
@Scheduled(cron = "0 0/2 * * * ?") |
|
|
|
public void noOpenAccount(){ |
|
|
|
List<BsSgcjsjdBuiProInfo> bsSgcjsjdBuiProInfos = bsSgcjsjdBuiProInfoMapper.selectList(null); |
|
|
|
Date date=new Date(); |
|
|
|
for(BsSgcjsjdBuiProInfo bs:bsSgcjsjdBuiProInfos){ |
|
|
|
|
|
|
|
LambdaQueryWrapper<BsSgcJsjdBuiContInfo>lw=new LambdaQueryWrapper<>(); |
|
|
|
List<BsSgcJsjdBuiContInfo> bsSgcJsjdBuiContInfos = bsSgcJsjdBuiContInfoMapper.selectList(lw.eq(BsSgcJsjdBuiContInfo::getProNo, bs.getProNo()) |
|
|
|
.eq(BsSgcJsjdBuiContInfo::getProCode, bs.getProCode()) |
|
|
|
.eq(BsSgcJsjdBuiContInfo::getContractType, "1").orderByAsc(BsSgcJsjdBuiContInfo::getSigningTime)); |
|
|
|
if (ObjectUtil.isNotEmpty(bsSgcJsjdBuiContInfos)){ |
|
|
|
BsSgcJsjdBuiContInfo bsSgcJsjdBuiContInfo = bsSgcJsjdBuiContInfos.get(0); |
|
|
|
LambdaQueryWrapper<BsSgcJsjdBuiDedicatedAccount>bsalw=new LambdaQueryWrapper<>(); |
|
|
|
List<BsSgcJsjdBuiDedicatedAccount> bsSgcJsjdBuiDedicatedAccounts = bsSgcJsjdBuiDedicatedAccountMapper.selectList(bsalw.eq(BsSgcJsjdBuiDedicatedAccount::getProCode, bs.getProCode()) |
|
|
|
.eq(BsSgcJsjdBuiDedicatedAccount::getProNo, bs.getProNo()).orderByAsc(BsSgcJsjdBuiDedicatedAccount::getAccountsTime)); |
|
|
|
WarnType warnType=WarnType.NO_OPEN_ACCOUNT; |
|
|
|
if (ObjectUtil.isEmpty(bsSgcJsjdBuiDedicatedAccounts)){ |
|
|
|
long l = DateUtil.betweenDay(bsSgcJsjdBuiContInfo.getSigningTime(), date, true); |
|
|
|
if (l>30){ |
|
|
|
warnOperate.sendWarn(bs.getProNo(),bs.getProCode(), |
|
|
|
warnType,warnType.getWarnResult()); |
|
|
|
} |
|
|
|
}else { |
|
|
|
long l = DateUtil.betweenDay(bsSgcJsjdBuiContInfo.getSigningTime(), bsSgcJsjdBuiDedicatedAccounts.get(0).getAccountsTime(), true); |
|
|
|
if (l>30){ |
|
|
|
warnOperate.sendWarn(bs.getProNo(),bs.getProCode(), |
|
|
|
warnType,warnType.getWarnResult()); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|