微调
This commit is contained in:
@@ -856,8 +856,6 @@ public class SocketDevResponseService {
|
||||
storageParam.setDevId(devId);
|
||||
indexes.addAll(adHarmonicService.getIndex(storageParam));
|
||||
});
|
||||
List<Integer> notErrorCheckIndex = pqScriptCheckDataService.listNotErrorCheckIndex(param.getScriptId());
|
||||
indexes.removeAll(notErrorCheckIndex);
|
||||
issueParam.setIndexList(indexes.stream().collect(Collectors.toList()));
|
||||
issueParam.setIsPhaseSequence(SourceOperateCodeEnum.RE_ERROR_TEST.getValue());
|
||||
} else {
|
||||
|
||||
@@ -332,7 +332,6 @@ public class AdPlanServiceImpl extends ServiceImpl<AdPlanMapper, AdPlan> impleme
|
||||
//
|
||||
// scriptDtlsList = scriptDtlsList.stream().filter(obj -> !sortSet.contains(obj.getScriptIndex())).collect(Collectors.toList());
|
||||
// }
|
||||
List<Integer> notErrorCheckIndex = pqScriptCheckDataService.listNotErrorCheckIndex(scriptId);
|
||||
Set<Integer> indexes = new HashSet<>();
|
||||
StorageParam storageParam = new StorageParam();
|
||||
storageParam.setCode(adPlan.getCode() + "");
|
||||
@@ -341,7 +340,6 @@ public class AdPlanServiceImpl extends ServiceImpl<AdPlanMapper, AdPlan> impleme
|
||||
storageParam.setDevId(devId);
|
||||
indexes.addAll(adHarmonicService.getIndex(storageParam));
|
||||
});
|
||||
indexes.removeAll(notErrorCheckIndex);
|
||||
scriptDtlsList = scriptDtlsList.stream().filter(obj -> indexes.contains(obj.getScriptIndex())).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
|
||||
@@ -51,12 +51,4 @@ public interface IPqScriptCheckDataService extends IService<PqScriptCheckData> {
|
||||
* @return
|
||||
*/
|
||||
boolean deleteByScriptIds(List<String> ids);
|
||||
|
||||
/**
|
||||
* 根据脚本id查询出不参与误差比较的检查项对应的index
|
||||
*
|
||||
* @param scriptId
|
||||
* @return
|
||||
*/
|
||||
List<Integer> listNotErrorCheckIndex(String scriptId);
|
||||
}
|
||||
|
||||
@@ -145,25 +145,4 @@ public class PqScriptCheckDataServiceImpl extends ServiceImpl<PqScriptCheckDataM
|
||||
public boolean deleteByScriptIds(List<String> ids) {
|
||||
return this.remove(new LambdaQueryWrapper<PqScriptCheckData>().in(PqScriptCheckData::getScriptId, ids));
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Integer> listNotErrorCheckIndex(String scriptId) {
|
||||
LambdaQueryWrapper<PqScriptCheckData> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.select(PqScriptCheckData::getScriptIndex)
|
||||
.eq(PqScriptCheckData::getScriptId, scriptId)
|
||||
.eq(PqScriptCheckData::getErrorFlag, 0);
|
||||
|
||||
List<Integer> list1 = this.list(wrapper).stream().map(PqScriptCheckData::getScriptIndex).distinct().collect(Collectors.toList());
|
||||
for (int i = list1.size() - 1; i >= 0; i--) {
|
||||
wrapper.clear();
|
||||
wrapper.eq(PqScriptCheckData::getScriptId, scriptId);
|
||||
wrapper.eq(PqScriptCheckData::getScriptIndex, list1.get(i));
|
||||
List<PqScriptCheckData> list = this.list(wrapper);
|
||||
long count = list.stream().filter(x -> x.getErrorFlag() == 1).count();
|
||||
if (count != 0) {
|
||||
list1.remove(i);
|
||||
}
|
||||
}
|
||||
return list1;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user