正式检测系统加固

This commit is contained in:
wr
2025-02-12 15:14:29 +08:00
parent 04135f7044
commit 8f8788b43c
4 changed files with 319 additions and 150 deletions

View File

@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
import com.njcn.common.pojo.enums.common.DataStateEnum;
import com.njcn.gather.detection.pojo.enums.DetectionCodeEnum;
import com.njcn.gather.script.mapper.PqScriptCheckDataMapper;
import com.njcn.gather.script.pojo.param.PqScriptCheckDataParam;
import com.njcn.gather.script.pojo.po.PqScriptCheckData;
@@ -32,10 +33,7 @@ import java.util.stream.Collectors;
@RequiredArgsConstructor
public class PqScriptCheckDataServiceImpl extends ServiceImpl<PqScriptCheckDataMapper, PqScriptCheckData> implements IPqScriptCheckDataService {
private final String V="real$V2-50";
private final String SV="real$SV_1-49";
private final String I="real$I2-50";
private final String IV="real$SI_1-49";
private final String REAL="real$";
private final DictTreeMapper dictTreeMapper;
@@ -54,17 +52,21 @@ public class PqScriptCheckDataServiceImpl extends ServiceImpl<PqScriptCheckDataM
if(CollUtil.isNotEmpty(pqScriptCheckData)){
if (param.getIsValueTypeName()) {
List<String> checkData = pqScriptCheckData.stream().map(x -> x.getDataType() + "$" + x.getValueType()).distinct().collect(Collectors.toList());
if(!checkData.contains("real$U1")){
if(checkData.contains(V)||checkData.contains(SV)){
checkData.add("real$U1");
String U = REAL + DetectionCodeEnum.U1.getCode();
if(!checkData.contains(U)){
if(checkData.contains(REAL+DetectionCodeEnum.V2_50.getCode())||
checkData.contains(REAL+DetectionCodeEnum.SV_1_49.getCode())){
checkData.add(U);
}
}
if(!checkData.contains("real$I1")){
if(checkData.contains(I)||checkData.contains(IV)){
checkData.add("real$I1");
String I = REAL + DetectionCodeEnum.I1.getCode();
if(!checkData.contains(I)){
if(checkData.contains(REAL+DetectionCodeEnum.I2_50.getCode())||
checkData.contains(REAL+DetectionCodeEnum.SI_1_49.getCode())){
checkData.add(I);
}
}
return checkData;
return checkData.stream().distinct().collect(Collectors.toList());
} else {
return pqScriptCheckData.stream().map(PqScriptCheckData::getValueType).distinct().collect(Collectors.toList());
}