实验报告

This commit is contained in:
ls
2025-05-05 23:36:05 +08:00
parent e17e3660b9
commit 1c58c55077
3 changed files with 390 additions and 352 deletions

View File

@@ -1,8 +1,6 @@
package org.jeecg.modules.database.controller;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.ObjUtil;
import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
@@ -428,7 +426,7 @@ public class ExperimentController extends JeecgController<Experiment, IExperimen
dto.setType(ex.getType());
dto.setStartDate(ex.getStartDate());
dto.setEndDate(ex.getEndDate());
String equipmentStr = ex.getDeviationEquipmentList().stream().map(v -> v.getEquipmentNo()).filter(
String equipmentStr = ex.getDeviationEquipmentList().stream().map(v -> v.getEquipmentName()).filter(
v -> StringUtils.isNotBlank(v))
.collect(Collectors.joining("\n"));
dto.setEquipment(equipmentStr);
@@ -447,179 +445,179 @@ public class ExperimentController extends JeecgController<Experiment, IExperimen
String radiationDetailJson = radiationProcess.getRadiationDetail();
if (StringUtils.isNotBlank(radiationDetailJson)) {
RadiationMapDTO radiationMap = JSON.parseObject(radiationDetailJson, RadiationMapDTO.class);
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getXgy(), "小钴源"));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getDgy(), "大钴源"));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getX(), "X光机"));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getElectronics(), "电子加速器"));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getProton(), "质子加速器"));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getXgy(), ex));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getDgy(), ex));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getX(), ex));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getElectronics(), ex));
addIfNotEmpty(detailList, extractedXgy(radiationProcess, radiationMap.getProton(), ex));
}
});
}
//退火过程
List<AnnealProcessExportDTO> annealProcessList = new ArrayList<>();
List<ExperimentAnnealProcess> experimentAnnealProcessList = experimentAnnealProcessService.getByExperimentId(ex.getId());
if (CollUtil.isNotEmpty(experimentAnnealProcessList)) {
experimentAnnealProcessList.forEach(v -> {
List<ExperimentSampleInfo> sampleInfoList = v.getSampleInfoList();
List<ExperimentDeviationEquipment> deviationEquipmentList = v.getDeviationEquipmentList();
List<ExperimentDeviationCondition> deviationConditionList = v.getDeviationConditionList();
if (CollUtil.isNotEmpty(sampleInfoList)) {
for (int j = 0; j < sampleInfoList.size(); j++) {
ExperimentSampleInfo sampleInfo = sampleInfoList.get(j);
AnnealProcessExportDTO annealProcessExportDTO = new AnnealProcessExportDTO();
if (CollUtil.isNotEmpty(deviationConditionList) && deviationConditionList.size() > j && ObjUtil.isNotNull(
deviationConditionList.get(j))
) {
BeanUtil.copyProperties(deviationConditionList.get(j), annealProcessExportDTO);
}
if (CollUtil.isNotEmpty(deviationEquipmentList) && deviationEquipmentList.size() > j && ObjUtil.isNotNull(
deviationEquipmentList.get(j))
) {
BeanUtil.copyProperties(deviationEquipmentList.get(j), annealProcessExportDTO);
}
annealProcessExportDTO.setSampleName(sampleInfo.getSampleName());
annealProcessExportDTO.setSampleModel(sampleInfo.getSampleModel());
annealProcessExportDTO.setSampleType(sampleInfo.getSampleType());
annealProcessExportDTO.setAnnealTemperature(v.getAnnealTemperature());
annealProcessExportDTO.setAnnealStartTime(DateUtils.formatDate(v.getAnnealStartTime(), "yyyy-MM-dd HH:mm"));
annealProcessExportDTO.setAnnealEndTime(DateUtils.formatDate(v.getAnnealEndTime(), "yyyy-MM-dd HH:mm"));
annealProcessList.add(annealProcessExportDTO);
}
}
});
}
dto.setAnnealProcessList(annealProcessList);
//List<AnnealProcessExportDTO> annealProcessList = new ArrayList<>();
//List<ExperimentAnnealProcess> experimentAnnealProcessList = experimentAnnealProcessService.getByExperimentId(ex.getId());
//if (CollUtil.isNotEmpty(experimentAnnealProcessList)) {
// experimentAnnealProcessList.forEach(v -> {
// List<ExperimentSampleInfo> sampleInfoList = v.getSampleInfoList();
// List<ExperimentDeviationEquipment> deviationEquipmentList = v.getDeviationEquipmentList();
// List<ExperimentDeviationCondition> deviationConditionList = v.getDeviationConditionList();
// if (CollUtil.isNotEmpty(sampleInfoList)) {
// for (int j = 0; j < sampleInfoList.size(); j++) {
// ExperimentSampleInfo sampleInfo = sampleInfoList.get(j);
// AnnealProcessExportDTO annealProcessExportDTO = new AnnealProcessExportDTO();
//
// if (CollUtil.isNotEmpty(deviationConditionList) && deviationConditionList.size() > j && ObjUtil.isNotNull(
// deviationConditionList.get(j))
// ) {
// BeanUtil.copyProperties(deviationConditionList.get(j), annealProcessExportDTO);
// }
// if (CollUtil.isNotEmpty(deviationEquipmentList) && deviationEquipmentList.size() > j && ObjUtil.isNotNull(
// deviationEquipmentList.get(j))
// ) {
// BeanUtil.copyProperties(deviationEquipmentList.get(j), annealProcessExportDTO);
// }
//
// annealProcessExportDTO.setSampleName(sampleInfo.getSampleName());
// annealProcessExportDTO.setSampleModel(sampleInfo.getSampleModel());
// annealProcessExportDTO.setSampleType(sampleInfo.getSampleType());
// annealProcessExportDTO.setAnnealTemperature(v.getAnnealTemperature());
// annealProcessExportDTO.setAnnealStartTime(DateUtils.formatDate(v.getAnnealStartTime(), "yyyy-MM-dd HH:mm"));
// annealProcessExportDTO.setAnnealEndTime(DateUtils.formatDate(v.getAnnealEndTime(), "yyyy-MM-dd HH:mm"));
// annealProcessList.add(annealProcessExportDTO);
// }
// }
// });
//}
//
//dto.setAnnealProcessList(annealProcessList);
//测试过程
List<ExperimentTestProcess> experimentTestProcessList = experimentTestProcessService.getByExperimentId(ex.getId());
List<TestProcessExportDTO> testProcessList = new ArrayList<>();
if (CollUtil.isNotEmpty(experimentTestProcessList)) {
experimentTestProcessList.forEach(v -> {
TestProcessExportDTO testProcessExportDTO = new TestProcessExportDTO();
testProcessExportDTO.setEnvironmentalTemperature(v.getEnvironmentalTemperature());
testProcessExportDTO.setEnvironmentalHumidity(v.getEnvironmentalHumidity());
testProcessExportDTO.setTestStandards(ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getName() : "");
testProcessExportDTO.setTemperatureRequirements(
ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getTemperatureRequirements() : "");
testProcessExportDTO.setHumidityRequirements(
ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getHumidityRequirements() : "");
String testParameters = v.getTestParameters();
if (StringUtils.isNotBlank(testParameters)) {
List<Map> jsonObject = JSON.parseArray(testParameters, Map.class);
String collect = jsonObject.stream().map(s -> s.getOrDefault("name", "").toString()).collect(
Collectors.joining(","));
testProcessExportDTO.setTestParameters(collect);
}
List<TestEquipmentDTO> testEquipmentDTOList = v.getTestEquipmentList();
if (CollUtil.isNotEmpty(testEquipmentDTOList)) {
testProcessExportDTO.setEquipmentModel(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getEquipmentModel()))
.map(t -> t.getEquipmentModel())
.collect(Collectors.joining(",")));
testProcessExportDTO.setSampleModel(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getSampleModel()))
.map(t -> t.getSampleModel())
.collect(Collectors.joining(",")));
testProcessExportDTO.setManagementNo(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getManagementNo()))
.map(t -> t.getManagementNo())
.collect(Collectors.joining(",")));
testProcessExportDTO.setLifespan(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getLifespan()))
.map(t -> t.getLifespan())
.collect(Collectors.joining(",")));
testProcessExportDTO.setEquipmentName(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getEquipmentName()))
.map(t -> t.getEquipmentName())
.collect(Collectors.joining(",")));
testProcessExportDTO.setRoomNo(testEquipmentDTOList.stream().filter(
t -> StringUtils.isNotBlank(t.getRoomNo()))
.map(t -> t.getRoomNo())
.collect(Collectors.joining(",")));
}
List<TestMeteringPointDTO> testMeteringPointList = v.getTestMeteringPointList();
if (CollUtil.isNotEmpty(testMeteringPointList)) {
testProcessExportDTO.setMeteringPoint(testMeteringPointList.stream().filter(
t -> StringUtils.isNotBlank(t.getPoint()))
.map(t -> t.getPoint())
.collect(Collectors.joining(",")));
testProcessExportDTO.setMeteringStartTime(testMeteringPointList.stream().filter(
t -> StringUtils.isNotBlank(t.getStartTime()))
.map(t -> t.getStartTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setMeteringEndTime(testMeteringPointList.stream().filter(
t -> StringUtils.isNotBlank(t.getEndTime()))
.map(t -> t.getEndTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setMeteringResult(testMeteringPointList.stream().filter(
t -> StringUtils.isNotBlank(t.getResult()))
.map(t -> t.getResult())
.collect(Collectors.joining(",")));
}
List<TestFluencePointDTO> testFluencePointList = v.getTestFluencePointList();
if (CollUtil.isNotEmpty(testFluencePointList)) {
testProcessExportDTO.setFluencePoint(testFluencePointList.stream().filter(
t -> StringUtils.isNotBlank(t.getPoint()))
.map(t -> t.getPoint())
.collect(Collectors.joining(",")));
testProcessExportDTO.setFluenceStartTime(testFluencePointList.stream().filter(
t -> StringUtils.isNotBlank(t.getStartTime()))
.map(t -> t.getStartTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setFluenceEndTime(testFluencePointList.stream().filter(
t -> StringUtils.isNotBlank(t.getEndTime()))
.map(t -> t.getEndTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setFluenceResult(testFluencePointList.stream().filter(
t -> StringUtils.isNotBlank(t.getResult()))
.map(t -> t.getResult())
.collect(Collectors.joining(",")));
}
List<TestAnnealingDurationDTO> annealingDurationList = v.getAnnealingDurationList();
if (CollUtil.isNotEmpty(annealingDurationList)) {
testProcessExportDTO.setAnnealingPoint(annealingDurationList.stream().filter(
t -> StringUtils.isNotBlank(t.getPoint()))
.map(t -> t.getPoint())
.collect(Collectors.joining(",")));
testProcessExportDTO.setAnnealingStartTime(annealingDurationList.stream().filter(
t -> StringUtils.isNotBlank(t.getStartTime()))
.map(t -> t.getStartTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setAnnealingEndTime(annealingDurationList.stream().filter(
t -> StringUtils.isNotBlank(t.getEndTime()))
.map(t -> t.getEndTime())
.collect(Collectors.joining(",")));
testProcessExportDTO.setAnnealingResult(annealingDurationList.stream().filter(
t -> StringUtils.isNotBlank(t.getResult()))
.map(t -> t.getResult())
.collect(Collectors.joining(",")));
}
testProcessExportDTO.setTestResult(v.getTestResult());
testProcessList.add(testProcessExportDTO);
});
}
dto.setTestProcessList(testProcessList);
//List<ExperimentTestProcess> experimentTestProcessList = experimentTestProcessService.getByExperimentId(ex.getId());
//List<TestProcessExportDTO> testProcessList = new ArrayList<>();
//if (CollUtil.isNotEmpty(experimentTestProcessList)) {
// experimentTestProcessList.forEach(v -> {
// TestProcessExportDTO testProcessExportDTO = new TestProcessExportDTO();
// testProcessExportDTO.setEnvironmentalTemperature(v.getEnvironmentalTemperature());
// testProcessExportDTO.setEnvironmentalHumidity(v.getEnvironmentalHumidity());
// testProcessExportDTO.setTestStandards(ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getName() : "");
// testProcessExportDTO.setTemperatureRequirements(
// ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getTemperatureRequirements() : "");
// testProcessExportDTO.setHumidityRequirements(
// ObjUtil.isNotNull(v.getTestStandards()) ? v.getTestStandards().getHumidityRequirements() : "");
// String testParameters = v.getTestParameters();
// if (StringUtils.isNotBlank(testParameters)) {
// List<Map> jsonObject = JSON.parseArray(testParameters, Map.class);
// String collect = jsonObject.stream().map(s -> s.getOrDefault("name", "").toString()).collect(
// Collectors.joining(","));
// testProcessExportDTO.setTestParameters(collect);
// }
// List<TestEquipmentDTO> testEquipmentDTOList = v.getTestEquipmentList();
// if (CollUtil.isNotEmpty(testEquipmentDTOList)) {
// testProcessExportDTO.setEquipmentModel(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getEquipmentModel()))
// .map(t -> t.getEquipmentModel())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setSampleModel(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getSampleModel()))
// .map(t -> t.getSampleModel())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setManagementNo(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getManagementNo()))
// .map(t -> t.getManagementNo())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setLifespan(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getLifespan()))
// .map(t -> t.getLifespan())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setEquipmentName(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getEquipmentName()))
// .map(t -> t.getEquipmentName())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setRoomNo(testEquipmentDTOList.stream().filter(
// t -> StringUtils.isNotBlank(t.getRoomNo()))
// .map(t -> t.getRoomNo())
// .collect(Collectors.joining(",")));
// }
//
// List<TestMeteringPointDTO> testMeteringPointList = v.getTestMeteringPointList();
// if (CollUtil.isNotEmpty(testMeteringPointList)) {
// testProcessExportDTO.setMeteringPoint(testMeteringPointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getPoint()))
// .map(t -> t.getPoint())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setMeteringStartTime(testMeteringPointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getStartTime()))
// .map(t -> t.getStartTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setMeteringEndTime(testMeteringPointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getEndTime()))
// .map(t -> t.getEndTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setMeteringResult(testMeteringPointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getResult()))
// .map(t -> t.getResult())
// .collect(Collectors.joining(",")));
// }
//
// List<TestFluencePointDTO> testFluencePointList = v.getTestFluencePointList();
// if (CollUtil.isNotEmpty(testFluencePointList)) {
// testProcessExportDTO.setFluencePoint(testFluencePointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getPoint()))
// .map(t -> t.getPoint())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setFluenceStartTime(testFluencePointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getStartTime()))
// .map(t -> t.getStartTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setFluenceEndTime(testFluencePointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getEndTime()))
// .map(t -> t.getEndTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setFluenceResult(testFluencePointList.stream().filter(
// t -> StringUtils.isNotBlank(t.getResult()))
// .map(t -> t.getResult())
// .collect(Collectors.joining(",")));
// }
//
// List<TestAnnealingDurationDTO> annealingDurationList = v.getAnnealingDurationList();
// if (CollUtil.isNotEmpty(annealingDurationList)) {
// testProcessExportDTO.setAnnealingPoint(annealingDurationList.stream().filter(
// t -> StringUtils.isNotBlank(t.getPoint()))
// .map(t -> t.getPoint())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setAnnealingStartTime(annealingDurationList.stream().filter(
// t -> StringUtils.isNotBlank(t.getStartTime()))
// .map(t -> t.getStartTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setAnnealingEndTime(annealingDurationList.stream().filter(
// t -> StringUtils.isNotBlank(t.getEndTime()))
// .map(t -> t.getEndTime())
// .collect(Collectors.joining(",")));
//
// testProcessExportDTO.setAnnealingResult(annealingDurationList.stream().filter(
// t -> StringUtils.isNotBlank(t.getResult()))
// .map(t -> t.getResult())
// .collect(Collectors.joining(",")));
// }
// testProcessExportDTO.setTestResult(v.getTestResult());
// testProcessList.add(testProcessExportDTO);
// });
//}
//dto.setTestProcessList(testProcessList);
dto.setRadiationProcessList(detailList);
resultList.add(dto);
@@ -646,82 +644,107 @@ public class ExperimentController extends JeecgController<Experiment, IExperimen
}
}
private RadiationProcessExportDTO extractedXgy(ExperimentRadiationProcess radiationProcess, List<RadiationDetailDTO> xgy, String name) {
private RadiationProcessExportDTO extractedXgy(ExperimentRadiationProcess radiationProcess, List<RadiationDetailDTO> xgy,
Experiment experiment) {
if (CollUtil.isEmpty(xgy)) {
return null;
}
RadiationProcessExportDTO detail = new RadiationProcessExportDTO();
List<ExperimentSampleInfo> sampleInfoList = radiationProcess.getSampleInfoList();
detail.setRadiateType(name);
detail.setRadiateType(radiationProcess.getRadiationSource());
if (CollUtil.isNotEmpty(sampleInfoList)) {
detail.setSampleModel(sampleInfoList.stream().map(s -> s.getSampleModel()).collect(Collectors.joining(",")));
detail.setSampleType(sampleInfoList.stream().map(s -> s.getSampleType()).collect(Collectors.joining(",")));
detail.setSampleName(sampleInfoList.stream().map(s -> s.getSampleName()).collect(Collectors.joining(",")));
}
//detail.setMeasurementRate(radiationProcess.getMeasurementRate());
detail.setPlannedMeasurementRate(
xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedMeasurementRate())).map(v -> v.getPlannedMeasurementRate())
.collect(Collectors.joining(",")));
detail.setActualMeasurementRate(
detail.setMeasurementRate(
xgy.stream().filter(v -> StringUtils.isNotBlank(v.getActualMeasurementRate())).map(v -> v.getActualMeasurementRate())
.collect(Collectors.joining(",")));
detail.setPlannedMeasurementPoint(
xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedMeasurementPoint())).map(v -> v.getPlannedMeasurementPoint())
.collect(Collectors.joining(",")));
detail.setPoint(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPoint())).map(v -> v.getPoint())
.collect(Collectors.joining(",")));
OptionalDouble maxRate = xgy.stream().map(obj -> obj.getActualMeasurementRate()) // 获取point字段
.filter(point -> StringUtils.isNotBlank(point))
.filter(str -> str.matches("-?\\d+(\\.\\d+)?")) // 只保留数字格式的字符串
.mapToDouble(Double::parseDouble) // 转换为double
.max();
detail.setTotalMeasurementRate(maxRate.isPresent() ? String.valueOf(maxRate.getAsDouble()) : "");
List<ExperimentIrradiationBoard> irradiationBoardList = experiment.getIrradiationBoardList();
if (CollUtil.isNotEmpty(irradiationBoardList)) {
detail.setSourceArea(irradiationBoardList.stream().filter(k -> StringUtils.isNotBlank(k.getSourceArea()))
.map(s -> s.getSourceArea()).collect(Collectors.joining(",")));
}
detail.setSourceDistance(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getSourceDistance())).map(v -> v.getSourceDistance())
.collect(Collectors.joining(",")));
//String measurementRate = radiationProcess.getMeasurementRate();
//if (StringUtils.isNotBlank(measurementRate)) {
// List<Map<String, String>> maps = JSON.parseObject(measurementRate, new TypeReference<>() {});
// List<String> rate = new ArrayList<>();
// maps.stream().forEach(v -> rate.add(String.join(",", v.values())));
// detail.setMeasurementRate(String.join(",", rate));
//}
detail.setTubeCurrent(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getTubeCurrent())).map(v -> v.getTubeCurrent())
.collect(Collectors.joining(",")));
detail.setEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEnergy())).map(v -> v.getEnergy())
.collect(Collectors.joining(",")));
detail.setCalibrationDistance(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getCalibrationDistance()))
.map(v -> v.getCalibrationDistance())
.collect(Collectors.joining(",")));
detail.setIrradiationTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getIrradiationTime())).map(v -> v.getIrradiationTime())
.collect(Collectors.joining(",")));
detail.setActualInjectionRate(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getActualInjectionRate()))
.map(v -> v.getActualInjectionRate())
.collect(Collectors.joining(",")));
detail.setElectronEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getElectronEnergy())).map(v -> v.getElectronEnergy())
.collect(Collectors.joining(",")));
detail.setBeam(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getBeam())).map(v -> v.getBeam())
.collect(Collectors.joining(",")));
detail.setPlateSpacing(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlateSpacing())).map(v -> v.getPlateSpacing())
.collect(Collectors.joining(",")));
detail.setProtonEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getProtonEnergy())).map(v -> v.getProtonEnergy())
.collect(Collectors.joining(",")));
detail.setScanArea(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getScanArea())).map(v -> v.getScanArea())
.collect(Collectors.joining(",")));
detail.setEnvironmentSelect(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEnvironmentSelect()))
.map(v -> v.getEnvironmentSelect())
.collect(Collectors.joining(",")));
detail.setXy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getXy())).map(v -> v.getXy())
.collect(Collectors.joining(",")));
detail.setTypeSelect(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getTypeSelect())).map(v -> v.getTypeSelect())
.collect(Collectors.joining(",")));
detail.setStartTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getStartTime())).map(v -> v.getStartTime())
.collect(Collectors.joining(",")));
detail.setEndTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEndTime())).map(v -> v.getEndTime())
.collect(Collectors.joining(",")));
detail.setPlannedInjectionRate(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedInjectionRate()))
.map(v -> v.getPlannedInjectionRate())
.collect(Collectors.joining(",")));
detail.setPlannedInjectionPoints(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedInjectionPoints()))
.map(v -> v.getPlannedInjectionPoints())
.collect(Collectors.joining(",")));
//detail.setMeasurementRate(radiationProcess.getMeasurementRate());
//detail.setPlannedMeasurementRate(
// xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedMeasurementRate())).map(v -> v.getPlannedMeasurementRate())
// .collect(Collectors.joining(",")));
//detail.setActualMeasurementRate(
// xgy.stream().filter(v -> StringUtils.isNotBlank(v.getActualMeasurementRate())).map(v -> v.getActualMeasurementRate())
// .collect(Collectors.joining(",")));
//detail.setPlannedMeasurementPoint(
// xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedMeasurementPoint())).map(v -> v.getPlannedMeasurementPoint())
// .collect(Collectors.joining(",")));
//detail.setPoint(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPoint())).map(v -> v.getPoint())
// .collect(Collectors.joining(",")));
//
//detail.setSourceDistance(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getSourceDistance())).map(v -> v.getSourceDistance())
// .collect(Collectors.joining(",")));
//
//detail.setTubeCurrent(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getTubeCurrent())).map(v -> v.getTubeCurrent())
// .collect(Collectors.joining(",")));
//
//detail.setEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEnergy())).map(v -> v.getEnergy())
// .collect(Collectors.joining(",")));
//
//detail.setCalibrationDistance(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getCalibrationDistance()))
// .map(v -> v.getCalibrationDistance())
// .collect(Collectors.joining(",")));
//
//detail.setIrradiationTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getIrradiationTime())).map(v -> v
// .getIrradiationTime())
// .collect(Collectors.joining(",")));
//
//detail.setActualInjectionRate(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getActualInjectionRate()))
// .map(v -> v.getActualInjectionRate())
// .collect(Collectors.joining(",")));
//detail.setElectronEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getElectronEnergy())).map(v -> v.getElectronEnergy())
// .collect(Collectors.joining(",")));
//
//detail.setBeam(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getBeam())).map(v -> v.getBeam())
// .collect(Collectors.joining(",")));
//detail.setPlateSpacing(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlateSpacing())).map(v -> v.getPlateSpacing())
// .collect(Collectors.joining(",")));
//
//detail.setProtonEnergy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getProtonEnergy())).map(v -> v.getProtonEnergy())
// .collect(Collectors.joining(",")));
//
//detail.setScanArea(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getScanArea())).map(v -> v.getScanArea())
// .collect(Collectors.joining(",")));
//detail.setEnvironmentSelect(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEnvironmentSelect()))
// .map(v -> v.getEnvironmentSelect())
// .collect(Collectors.joining(",")));
//detail.setXy(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getXy())).map(v -> v.getXy())
// .collect(Collectors.joining(",")));
//
//detail.setTypeSelect(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getTypeSelect())).map(v -> v.getTypeSelect())
// .collect(Collectors.joining(",")));
//
//detail.setStartTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getStartTime())).map(v -> v.getStartTime())
// .collect(Collectors.joining(",")));
//detail.setEndTime(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getEndTime())).map(v -> v.getEndTime())
// .collect(Collectors.joining(",")));
//detail.setPlannedInjectionRate(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedInjectionRate()))
// .map(v -> v.getPlannedInjectionRate())
// .collect(Collectors.joining(",")));
//detail.setPlannedInjectionPoints(xgy.stream().filter(v -> StringUtils.isNotBlank(v.getPlannedInjectionPoints()))
// .map(v -> v.getPlannedInjectionPoints())
// .collect(Collectors.joining(",")));
return detail;
}

View File

@@ -39,8 +39,14 @@ public class ExperimentExportDTO implements Serializable {
private String startDate;
@Excel(name = "实验结束日期", width = 15, needMerge = true)
private String endDate;
@ExcelCollection(name = "试验过程")
private List<RadiationProcessExportDTO> radiationProcessList;
@Excel(name = "使用设备", width = 15, needMerge = true)
private String equipment;
@Excel(name = "试验负责人", width = 15, needMerge = true)
private String supervisorName;
@Excel(name = "已出报告份数", width = 15, needMerge = true)
@@ -48,13 +54,13 @@ public class ExperimentExportDTO implements Serializable {
@Excel(name = "试验员及评分", width = 15, needMerge = true)
private String rateUserAndScore;
@ExcelCollection(name = "辐照过程")
private List<RadiationProcessExportDTO> radiationProcessList;
@ExcelCollection(name = "退火过程")
private List<AnnealProcessExportDTO> annealProcessList;
@ExcelCollection(name = "测试过程")
private List<TestProcessExportDTO> testProcessList;
//@ExcelCollection(name = "辐照过程")
//private List<RadiationProcessExportDTO> radiationProcessList;
//
//@ExcelCollection(name = "退火过程")
//private List<AnnealProcessExportDTO> annealProcessList;
//
//@ExcelCollection(name = "测试过程")
//private List<TestProcessExportDTO> testProcessList;
}

View File

@@ -25,120 +25,129 @@ public class RadiationProcessExportDTO implements Serializable {
private String radiateType;
@Excel(name = "样品型号", width = 15)
private String sampleModel;
@Excel(name = "样品名称", width = 15)
private String sampleName;
@Excel(name = "样品类型", width = 15)
private String sampleType;
//@Excel(name = "剂量率/注量率", width = 15)
//private String measurementRate;
@Excel(name = "剂量率/注量率", width = 15)
private String measurementRate;
/**
* 计划剂量率
*/
@Excel(name = "计划剂量率", width = 15)
private String plannedMeasurementRate;
/**
* 实际剂量率
*/
@Excel(name = "实际剂量率", width = 15)
private String actualMeasurementRate;
/**
* 计划剂量点
*/
@Excel(name = "计划剂量点", width = 15)
private String plannedMeasurementPoint;
/**
* 计划注量点
*/
@Excel(name = "计划量点", width = 15)
private String plannedInjectionPoints;
/**
* 计划注量率
*/
@Excel(name = "计划注量率", width = 15)
private String plannedInjectionRate;
/**
* 实际注量率
*/
@Excel(name = "实际注量率", width = 15)
private String actualInjectionRate;
/**
* 实际剂量点
*/
@Excel(name = "实际剂量点", width = 15)
private String point;
/**
* 源口距离
*/
@Excel(name = "源口距离", width = 15)
private String sourceDistance;
/**
* 管电流
*/
@Excel(name = "管电流", width = 15)
private String tubeCurrent;
/**
* 能量
*/
@Excel(name = "X光机能量", width = 15)
private String energy;
/**
* 标定距离
*/
@Excel(name = "标定距离", width = 15)
private String calibrationDistance;
/**
* 辐照时间
*/
@Excel(name = "辐照时间", width = 15)
private String irradiationTime;
/**
* 电子能量
*/
@Excel(name = "电子能量", width = 15)
private String electronEnergy;
/**
* 束流
*/
@Excel(name = "束流", width = 15)
private String beam;
/**
* 板距
*/
@Excel(name = "板距", width = 15)
private String plateSpacing;
/**
* 质子能量
*/
@Excel(name = "质子能量", width = 15)
private String protonEnergy;
/**
* 扫描面积
*/
@Excel(name = "扫描面积", width = 15)
private String scanArea;
/**
* 辐射环境
*/
@Excel(name = "辐射环境", width = 15)
private String environmentSelect;
/**
* 均匀性
*/
@Excel(name = "均匀性", width = 15)
private String xy;
/**
* 试验类型
*/
@Excel(name = "试验类型", width = 15)
private String typeSelect;
/**
* 辐照开始时间
*/
@Excel(name = "辐照开始时间", width = 15)
private String startTime;
/**
* 辐照结束时间
*/
@Excel(name = "辐照结束时间", width = 15)
private String endTime;
@Excel(name = "总剂量/注量krad(Si)", width = 15)
private String totalMeasurementRate;
@Excel(name = "占源面积(cm)", width = 15)
private String sourceArea;
//
///**
// * 计划剂量率
// */
//@Excel(name = "计划剂量率", width = 15)
//private String plannedMeasurementRate;
///**
// * 实际剂量率
// */
//@Excel(name = "实际剂量率", width = 15)
//private String actualMeasurementRate;
///**
// * 计划量点
// */
//@Excel(name = "计划剂量点", width = 15)
//private String plannedMeasurementPoint;
///**
// * 计划注量点
// */
//@Excel(name = "计划注量点", width = 15)
//private String plannedInjectionPoints;
///**
// * 计划注量率
// */
//@Excel(name = "计划注量率", width = 15)
//private String plannedInjectionRate;
///**
// * 实际注量率
// */
//@Excel(name = "实际注量率", width = 15)
//private String actualInjectionRate;
///**
// * 实际剂量点
// */
//@Excel(name = "实际剂量点", width = 15)
//private String point;
///**
// * 源口距离
// */
//@Excel(name = "源口距离", width = 15)
//private String sourceDistance;
///**
// * 管电流
// */
//@Excel(name = "管电流", width = 15)
//private String tubeCurrent;
///**
// * 能量
// */
//@Excel(name = "X光机能量", width = 15)
//private String energy;
///**
// * 标定距离
// */
//@Excel(name = "标定距离", width = 15)
//private String calibrationDistance;
///**
// * 辐照时间
// */
//@Excel(name = "辐照时间", width = 15)
//private String irradiationTime;
///**
// * 电子能量
// */
//@Excel(name = "电子能量", width = 15)
//private String electronEnergy;
///**
// * 束流
// */
//@Excel(name = "束流", width = 15)
//private String beam;
///**
// * 板距
// */
//@Excel(name = "板距", width = 15)
//private String plateSpacing;
///**
// * 质子能量
// */
//@Excel(name = "质子能量", width = 15)
//private String protonEnergy;
///**
// * 扫描面积
// */
//@Excel(name = "扫描面积", width = 15)
//private String scanArea;
///**
// * 辐射环境
// */
//@Excel(name = "辐射环境", width = 15)
//private String environmentSelect;
///**
// * 均匀性
// */
//@Excel(name = "均匀性", width = 15)
//private String xy;
///**
// * 试验类型
// */
//@Excel(name = "试验类型", width = 15)
//private String typeSelect;
///**
// * 辐照开始时间
// */
//@Excel(name = "辐照开始时间", width = 15)
//private String startTime;
///**
// * 辐照结束时间
// */
//@Excel(name = "辐照结束时间", width = 15)
//private String endTime;
}