Merge remote-tracking branch 'origin/dev_20230216' into dev_20230216

This commit is contained in:
gaojiabao
2023-06-06 16:57:36 +08:00
10 changed files with 57 additions and 12 deletions
@@ -563,14 +563,11 @@ public class ActSarItemsBussEOService {
});
}
});
qualityEvaluationService.saveBatch(evaluations);
//当新增完成之后进行循环校验查出流程是重新技术委员会评审、评审意见修改就根据标准id将技术委员会评审、评审意见修改的评分赋值为0
for (QualityEvaluation qualityEvaluation :evaluations){
if (qualityEvaluation.getProcessNode().equals("重新技术委员会评审、评审意见修改")){
//qualityEvaluationService.saveBatch(evaluations);
qualityEvaluationService.save(qualityEvaluation);
qualityEvaluationDao.updateByProcessNode(evaluations.get(0).getLawId());
}else {
//qualityEvaluationService.saveBatch(evaluations);
qualityEvaluationService.save(qualityEvaluation);
qualityEvaluationDao.updateByProcessNode(qualityEvaluation.getLawId());
}
}
}
@@ -2,6 +2,7 @@ package com.adc.da.slrs.sarBussStandSn.dao;
import com.adc.da.slrs.sarBussStandSn.entity.SarBussStandSn;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
/**
* <p>
@@ -14,4 +15,8 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
public interface SarBussStandSnDao extends BaseMapper<SarBussStandSn> {
String selectMaxStandnSn();
String selectMaxStandSn(String standSort);
String selectStandSort(String standSort);
}
@@ -19,4 +19,7 @@ public interface ISarBussStandSnService extends IService<SarBussStandSn> {
String selectMaxStandnSn();
String selectMaxStandSn(String standSort);
String selectStandSort(String standSort);
}
@@ -65,4 +65,14 @@ public class SarBussStandSnServiceImpl extends ServiceImpl<SarBussStandSnDao, Sa
public String selectMaxStandnSn() {
return baseMapper.selectMaxStandnSn();
}
@Override
public String selectMaxStandSn(String standSort) {
return baseMapper.selectMaxStandSn(standSort);
}
@Override
public String selectStandSort(String standSort) {
return baseMapper.selectStandSort(standSort);
}
}
@@ -136,5 +136,7 @@ public interface SarBussionessStandDao extends BaseMapper<SarBussionessStand> {
@Select("select * from sar_bussioness_stand where TEXT_STATUS_BUSS is not null")
List<SarBussionessStand> selectAllStandStatus();
String selectMaxStandSn(String standSort);
}
@@ -70,5 +70,7 @@ public interface ISarBussionessStandService extends IService<SarBussionessStand>
ResponseMessage cleaningDataReview();
ResponseMessage repeal(String id, String type);
String selectMaxStandSn(String standSort);
}
@@ -220,11 +220,14 @@ public class SarBussionessStandServiceImpl extends ServiceImpl<SarBussionessStan
@Override
public SarBussionessStand getStandInfoByReviseStatus(String reviseStatus,String standSort,String taskId){
SarBussionessStand bussionessStand = new SarBussionessStand();
String snStandSort = iSarBussStandSnService.selectStandSort(standSort);
QueryWrapper queryWrapper = new QueryWrapper();
queryWrapper.eq("REPLACE(STAND_SORT,' ','')",standSort.replace(" ",""));
int count = iSarBussStandSnService.count(queryWrapper);
String MaxSn = iSarBussStandSnService.selectMaxStandSn(standSort);
String standMaxSn = iSarBussionessStandService.selectMaxStandSn(standSort);
// 1 先验证 当前企标类别 是否存在顺序号
if(count > 0){
if(count > 0 && MaxSn.equals(standMaxSn)){
QueryWrapper qw = new QueryWrapper();
qw.eq("REPLACE(STAND_SORT,' ','')",standSort.replace(" ",""));
qw.eq("TASK_ID",taskId);
@@ -248,24 +251,29 @@ public class SarBussionessStandServiceImpl extends ServiceImpl<SarBussionessStan
}else {
QueryWrapper wrapper1 = new QueryWrapper();
wrapper1.select("MAX(DISTINCT CAST(STAND_SN AS decimal(9)))+1 AS STAND_SN");
//wrapper1.select("MAX(DISTINCT CAST(STAND_SN AS decimal(9)))+1 AS STAND_SN");
wrapper1.select("MAX(DISTINCT CAST(STAND_SN AS decimal(9))) AS STAND_SN");
wrapper1.eq("REPLACE(STAND_SORT,' ','')",standSort.replace(" ",""));
SarBussStandSn one = iSarBussStandSnService.getOne(wrapper1);
// 1.1.2.2 返回顺序号
bussionessStand.setNewStandSn(one.getStandSn());
// 1.1.2.3 获取新的顺序号 存入顺序号表中
if (StringUtils.isBlank(MaxSn) && (StringUtils.isBlank(snStandSort) || snStandSort.equals(standSort))){
saveBussStandSn(reviseStatus, standSort, one.getStandSn(),taskId);
}
}
}
}else {
// 2 获取企标库中 当前类别 最新 顺序号 前提必须顺序号为正规数据
bussionessStand = sarBussionessStandEODao.getStandInfoByReviseStatus(reviseStatus,standSort);
String sn = "1";
String sn = "001";
if(ObjectUtils.isNotEmpty(bussionessStand)){
sn = bussionessStand.getNewStandSn();
}
if (StringUtils.isBlank(MaxSn) && (StringUtils.isBlank(snStandSort) || snStandSort.equals(standSort))){
saveBussStandSn(reviseStatus, standSort, sn, taskId);
}
bussionessStand.setStandSn(sn);
}
@@ -4674,6 +4682,11 @@ public class SarBussionessStandServiceImpl extends ServiceImpl<SarBussionessStan
return Result.success();
}
@Override
public String selectMaxStandSn(String standSort) {
return baseMapper.selectMaxStandSn(standSort);
}
public String updateInfo(List<String> asList,String standId,String attfId) {
//重复的集合
List<AttFileEO> chongfu = new ArrayList<>();
@@ -382,4 +382,8 @@ public class StateSync {
}
}
}
@Scheduled(cron = "0 30 13 * * ?")
public void shangBan(){
logger.info("下午的工作时间开始了,加油!");
}
}
@@ -5,5 +5,11 @@
<select id="selectMaxStandnSn" resultType="java.lang.String">
select Max(STAND_SN) from sar_buss_stand_sn
</select>
<select id="selectMaxStandSn" resultType="java.lang.String">
select Max(STAND_SN) from sar_buss_stand_sn where STAND_SORT = #{standSort} and VALID_FLAG = '0'
</select>
<select id="selectStandSort" resultType="java.lang.String">
select STAND_SORT from sar_buss_stand_sn where STAND_SORT = #{standSort} and VALID_FLAG = '0' limit 1
</select>
</mapper>
@@ -351,7 +351,7 @@
</select>
<select id="getStandInfoByReviseStatus" resultMap="BaseResultMap" parameterType="java.lang.String">
select MAX(DISTINCT CAST(stand_number AS decimal(9)))+1 AS newStandSn from sar_bussioness_stand
select MAX(DISTINCT CAST(stand_number AS decimal(9))) AS newStandSn from sar_bussioness_stand
where REPLACE(STAND_SORT,' ','') = REPLACE(#{standSort},' ','') and valid_flag=0
</select>
@@ -1257,6 +1257,9 @@
resultType="com.adc.da.slrs.sarBussionessStand.entity.SarBussionessStand">
select * from sar_bussioness_stand where stand_code = #{standCode} and VALID_FLAG = 0 limit 1
</select>
<select id="selectMaxStandSn" resultType="java.lang.String">
select max(STAND_NUMBER) from sar_bussioness_stand where STAND_SORT =#{standSort} and VALID_FLAG = 0
</select>
<update id="updateByIdInfo" >
update sar_buss_stand_attr_info ss set ss.FBGBUSS = #{strFile}