按照IDC程序修改web-statistic下的查询台站具体样例详情信息接口
This commit is contained in:
parent
7af968c5df
commit
86895dad3b
|
@ -0,0 +1,75 @@
|
|||
package org.jeecg.common.util;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
|
||||
import com.baomidou.mybatisplus.core.toolkit.StringPool;
|
||||
import org.apache.commons.net.ftp.FTPClient;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
public class ReadLineUtil {
|
||||
|
||||
@Autowired
|
||||
private FTPUtil ftpUtil;
|
||||
|
||||
public List<Integer> readLine(String filePath){
|
||||
List<Integer> lineValue = new LinkedList<>();
|
||||
|
||||
lineValue.add(1);
|
||||
lineValue.add(2859);
|
||||
lineValue.add(6965);
|
||||
lineValue.add(4344);
|
||||
lineValue.add(3088);
|
||||
lineValue.add(3149);
|
||||
lineValue.add(2917);
|
||||
lineValue.add(2375);
|
||||
lineValue.add(1829);
|
||||
lineValue.add(1760);
|
||||
lineValue.add(1914);
|
||||
lineValue.add(2128);
|
||||
lineValue.add(2238);
|
||||
lineValue.add(1954);
|
||||
lineValue.add(1899);
|
||||
lineValue.add(2146);
|
||||
lineValue.add(2758);
|
||||
lineValue.add(3177);
|
||||
lineValue.add(2846);
|
||||
lineValue.add(2507);
|
||||
lineValue.add(2456);
|
||||
lineValue.add(2723);
|
||||
lineValue.add(3227);
|
||||
lineValue.add(3461);
|
||||
lineValue.add(3464);
|
||||
lineValue.add(3144);
|
||||
lineValue.add(3081);
|
||||
lineValue.add(3381);
|
||||
lineValue.add(3234);
|
||||
lineValue.add(3163);
|
||||
lineValue.add(3357);
|
||||
lineValue.add(3534);
|
||||
lineValue.add(3756);
|
||||
lineValue.add(3911);
|
||||
lineValue.add(3552);
|
||||
|
||||
// //连接ftp
|
||||
// FTPClient ftpClient = ftpUtil.LoginFTP();
|
||||
// //判断ftp是否连接成功
|
||||
// if (Objects.isNull(ftpClient)){
|
||||
// throw new RuntimeException("ftp连接失败!");
|
||||
// }
|
||||
// //根据字符切割文件路径
|
||||
// List<String> paths = Arrays.asList(filePath.split(StringPool.SLASH));
|
||||
// if (CollectionUtils.isNotEmpty(paths)){
|
||||
//
|
||||
// }
|
||||
return lineValue;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -62,35 +62,10 @@ public class WebStatisticsController {
|
|||
return gardsSohDataService.findSohPage(queryRequest, stationIds, startTime, endTime);
|
||||
}
|
||||
|
||||
@GetMapping("findParticulateInfo")
|
||||
@ApiOperation(value = "查看IMS DATA下气溶胶数据详情", notes = "查看IMS DATA下气溶胶数据详情")
|
||||
public Result findParticulateInfo(Integer sampleId){
|
||||
return gardsSampleDataService.findParticulateInfo(sampleId);
|
||||
}
|
||||
|
||||
@GetMapping("findParticulateEnergy")
|
||||
@ApiOperation(value = "查看IMS DATA下气溶胶ENERGY数据", notes = "查看IMS DATA下气溶胶ENERGY数据")
|
||||
public Result findParticulateEnergy(Integer sampleId){
|
||||
return gardsSampleDataService.findParticulateEnergy(sampleId);
|
||||
}
|
||||
|
||||
@GetMapping("findParticulateResolution")
|
||||
@ApiOperation(value = "查看IMS DATA下气溶胶RESOLUTION数据", notes = "查看IMS DATA下气溶胶RESOLUTION数据")
|
||||
public Result findParticulateResolution(Integer sampleId){
|
||||
return gardsSampleDataService.findParticulateResolution(sampleId);
|
||||
}
|
||||
|
||||
@GetMapping("findParticulateEfficiency")
|
||||
@ApiOperation(value = "查看IMS DATA下气溶胶EFFICIENCY数据", notes = "查看IMS DATA下气溶胶EFFICIENCY数据")
|
||||
public Result findParticulateEfficiency(Integer sampleId){
|
||||
return gardsSampleDataService.findParticulateEfficiency(sampleId);
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("findParticulateCertificate")
|
||||
@ApiOperation(value = "查看IMS DATA下气溶胶CERTIFICATE数据", notes = "查看IMS DATA下气溶胶CERTIFICATE数据")
|
||||
public Result findParticulateCertificate(Integer sampleId){
|
||||
return gardsSampleCertService.findParticulateCertificate(sampleId);
|
||||
@GetMapping("findGeneratedReport")
|
||||
@ApiOperation(value = "查询报告详情页面", notes = "查询报告详情页面")
|
||||
public Result findGeneratedReport(Integer sampleId){
|
||||
return gardsSampleDataService.findGeneratedReport(sampleId);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,36 @@
|
|||
package org.jeecg.modules.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "GARDS_BG_EFFICIENCY_PAIRS")
|
||||
public class GardsBgEfficiencyPairs implements Serializable {
|
||||
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
|
||||
@TableField(value = "ROI")
|
||||
private Integer roi;
|
||||
|
||||
@TableField(value = "NUCLIDE_NAME")
|
||||
private String nuclideName;
|
||||
|
||||
@TableField(value = "BG_EFFICIENCY")
|
||||
private Double bgEfficiency;
|
||||
|
||||
@TableField(value = "BG_EFFIC_ERROR")
|
||||
private Double bgEfficError;
|
||||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package org.jeecg.modules.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "GARDS_HISTOGRAM")
|
||||
public class GardsHistogram implements Serializable {
|
||||
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
|
||||
@TableField(value = "FILENAME")
|
||||
private String fileName;
|
||||
|
||||
@TableField(value = "G_CHANNELS")
|
||||
private Integer GChannels;
|
||||
|
||||
@TableField(value = "B_CHANNELS")
|
||||
private Integer BChannels;
|
||||
|
||||
@TableField(value = "G_ENERGY_SPAN")
|
||||
private Integer GEnergySpan;
|
||||
|
||||
@TableField(value = "B_ENERGY_SPAN")
|
||||
private Integer BEnergySpan;
|
||||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package org.jeecg.modules.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "GARDS_ROI_LIMITS")
|
||||
public class GardsRoiLimits implements Serializable {
|
||||
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
|
||||
@TableField(value = "ROI")
|
||||
private Integer roi;
|
||||
|
||||
@TableField(value = "B_ENERGY_START")
|
||||
private Double BEnergyStart;
|
||||
|
||||
@TableField(value = "B_ENERGY_STOP")
|
||||
private Double BEnergyStop;
|
||||
|
||||
@TableField(value = "G_ENERGY_START")
|
||||
private Double GEnergyStart;
|
||||
|
||||
@TableField(value = "G_ENERGY_STOP")
|
||||
private Double GEnergyStop;
|
||||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
|
@ -23,7 +23,7 @@ public class GardsSampleCert implements Serializable {
|
|||
* 刻度源活度(Bq)total_source_activity
|
||||
*/
|
||||
@TableField(value = "QUANTITY")
|
||||
private Integer quantity;
|
||||
private Double quantity;
|
||||
|
||||
/**
|
||||
* 鉴定日期
|
||||
|
|
|
@ -14,7 +14,7 @@ public class GardsSampleCertLine implements Serializable {
|
|||
* 台站ID号
|
||||
*/
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
private Double sampleId;
|
||||
|
||||
/**
|
||||
* 核素名称
|
||||
|
@ -32,37 +32,37 @@ public class GardsSampleCertLine implements Serializable {
|
|||
* γ能量(keV)
|
||||
*/
|
||||
@TableField(value = "ENERGY")
|
||||
private Integer energy;
|
||||
private Double energy;
|
||||
|
||||
/**
|
||||
* 核素活度(Bq)
|
||||
*/
|
||||
@TableField(value = "ACTIVITY")
|
||||
private Integer activity;
|
||||
private Double activity;
|
||||
|
||||
/**
|
||||
* 核素活度不确定度(%)
|
||||
*/
|
||||
@TableField(value = "ERROR")
|
||||
private Integer error;
|
||||
private Double error;
|
||||
|
||||
/**
|
||||
* γ射线强度(%)
|
||||
*/
|
||||
@TableField(value = "ABUNDANCE")
|
||||
private Integer abundance;
|
||||
private Double abundance;
|
||||
|
||||
/**
|
||||
* β射线强度(%)
|
||||
*/
|
||||
@TableField(value = "B_ABUNDANCE")
|
||||
private Integer bAbundance;
|
||||
private Double bAbundance;
|
||||
|
||||
/**
|
||||
* β能量
|
||||
*/
|
||||
@TableField(value = "B_ENERGY")
|
||||
private Integer bEnergy;
|
||||
private Double bEnergy;
|
||||
|
||||
/**
|
||||
* 衰变模式:
|
||||
|
|
|
@ -0,0 +1,39 @@
|
|||
package org.jeecg.modules.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "GARDS_SAMPLE_RATIOS")
|
||||
public class GardsSampleRatios implements Serializable {
|
||||
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
|
||||
@TableField(value = "RATIO_ID")
|
||||
private String ratioId;
|
||||
|
||||
@TableField(value = "UPPER_ROI_NUMBER")
|
||||
private Integer upperRoiNumber;
|
||||
|
||||
@TableField(value = "LOWER_ROI_NUMBER")
|
||||
private Integer lowerRoiNumber;
|
||||
|
||||
@TableField(value = "COUNT_RATIO")
|
||||
private Double countRatio;
|
||||
|
||||
@TableField(value = "COUNT_RATIO_ERR")
|
||||
private Double countRatioErr;
|
||||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
|
@ -0,0 +1,39 @@
|
|||
package org.jeecg.modules.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
@TableName(value = "GARDS_SPECTRUM")
|
||||
public class GardsSpectrum implements Serializable {
|
||||
|
||||
@TableField(value = "SAMPLE_ID")
|
||||
private Integer sampleId;
|
||||
|
||||
@TableField(value = "SAMPLE_TYPE")
|
||||
private String sampleType;
|
||||
|
||||
@TableField(value = "FILENAME")
|
||||
private String fileName;
|
||||
|
||||
@TableField(value = "CHANNELS")
|
||||
private Integer channels;
|
||||
|
||||
@TableField(value = "ENERGY_SPAN")
|
||||
private Integer energySpan;
|
||||
|
||||
@TableField(value = "START_CHANNEL")
|
||||
private Integer startChannel;
|
||||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class Acquisition implements Serializable {
|
||||
|
||||
private String acquisitionStartDate;
|
||||
|
||||
private Double acquisitionRealTime;
|
||||
|
||||
private Double acquisitionLiveTime;
|
||||
|
||||
}
|
|
@ -0,0 +1,21 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
@Data
|
||||
public class BEfficiency implements Serializable {
|
||||
|
||||
private String nuclideName;
|
||||
|
||||
private Integer roiNumber;
|
||||
|
||||
private Double coincidenceEfficiency;
|
||||
|
||||
private Date roiGRangeStart;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class BEnergy implements Serializable {
|
||||
|
||||
private Double electronEnergy;
|
||||
|
||||
private String decayModeDescriptor;
|
||||
|
||||
private Double maximumChannel;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class BResolution implements Serializable {
|
||||
|
||||
private Double electronEnergy;
|
||||
|
||||
private Double FWHM;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class BetaSpectrum implements Serializable {
|
||||
|
||||
private Integer numberBChannels;
|
||||
|
||||
private Integer energySpan;
|
||||
|
||||
private List<Integer> bSpectrumSubBlock;
|
||||
|
||||
}
|
|
@ -0,0 +1,12 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class Calibration implements Serializable {
|
||||
|
||||
private String dateOfLastCalibration;
|
||||
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
import org.jeecg.modules.entity.GardsSampleCertLine;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class Certificate implements Serializable {
|
||||
|
||||
private Double totalSourceActivity;
|
||||
|
||||
private String assayDate;
|
||||
|
||||
private String unitsOfActivity;
|
||||
|
||||
private List<CertificateLine> certificateSubBlock;
|
||||
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class CertificateLine implements Serializable {
|
||||
|
||||
private String nuclideName;
|
||||
|
||||
private String halfLife;
|
||||
|
||||
private Double Genergy;
|
||||
|
||||
private Double nuclideActivity;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
private Double intensity;
|
||||
|
||||
private String electronDecayModeDescriptor;
|
||||
|
||||
private Double maxBParticleEnergy;
|
||||
|
||||
private Double particleBIntensity;
|
||||
|
||||
}
|
|
@ -0,0 +1,12 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class Comment implements Serializable {
|
||||
|
||||
private String text;
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class GEfficiency implements Serializable {
|
||||
|
||||
private Double energy;
|
||||
|
||||
private Double efficiency;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class GEnergy implements Serializable {
|
||||
|
||||
private Double energy;
|
||||
|
||||
private Double centroid;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,16 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class GResolution implements Serializable {
|
||||
|
||||
private Double energy;
|
||||
|
||||
private Double FWHM;
|
||||
|
||||
private Double uncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class GammaSpectrum implements Serializable {
|
||||
|
||||
private Integer numberGChannels;
|
||||
|
||||
private Integer energySpan;
|
||||
|
||||
private List<Integer> gSpectrumSubBlock;
|
||||
|
||||
}
|
|
@ -0,0 +1,30 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class GeneralInformation implements Serializable {
|
||||
|
||||
private String siteCode;
|
||||
|
||||
private String detectorCode;
|
||||
|
||||
private String systemType;
|
||||
|
||||
private String sampleGeometry;
|
||||
|
||||
private String spectrumQualifier;
|
||||
|
||||
private String sampleReferenceIdentification;
|
||||
|
||||
private String measurementIdentification;
|
||||
|
||||
private String detectorBackgroundMeasurementId;
|
||||
|
||||
private String gasBackgroundMeasurementId;
|
||||
|
||||
private String transmitDate;
|
||||
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
import org.apache.poi.ss.formula.functions.T;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class Histogram implements Serializable {
|
||||
|
||||
private Integer BChannels;
|
||||
|
||||
private Integer BEnergySpan;
|
||||
|
||||
private Integer GChannels;
|
||||
|
||||
private Integer GEnergySpan;
|
||||
|
||||
private List<Integer> histogramSubBlock;
|
||||
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class Ratios implements Serializable {
|
||||
|
||||
private String ratioId;
|
||||
|
||||
private Integer roiNumberHigherEnergy;
|
||||
|
||||
private Integer roiNumberLowerEnergy;
|
||||
|
||||
private Double countRatio;
|
||||
|
||||
private Double countRatioUncertainty;
|
||||
|
||||
}
|
|
@ -0,0 +1,43 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class Report implements Serializable {
|
||||
|
||||
private GeneralInformation headerBlock;
|
||||
|
||||
private Comment commentBlock;
|
||||
|
||||
private Acquisition acquisitionBlock;
|
||||
|
||||
private Calibration calibrationBlock;
|
||||
|
||||
private List<GEnergy> gEnergyBlock;
|
||||
|
||||
private List<BEnergy> bEnergyBlock;
|
||||
|
||||
private List<GResolution> gResolutionBlock;
|
||||
|
||||
private List<BResolution> bResolutionBlock;
|
||||
|
||||
private List<GEfficiency> gEfficiencyBlock;
|
||||
|
||||
private List<BEfficiency> bgEfficiencyBlock;
|
||||
|
||||
private List<Roi> roiLimitsBlock;
|
||||
|
||||
private List<Ratios> ratiosBlock;
|
||||
|
||||
private GammaSpectrum gSpectrumBlock;
|
||||
|
||||
private BetaSpectrum bSpectrumBlock;
|
||||
|
||||
private Histogram histogramBlock;
|
||||
|
||||
private Certificate certificateBlock;
|
||||
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
package org.jeecg.modules.entity.data;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
@Data
|
||||
public class Roi implements Serializable {
|
||||
|
||||
private Integer roiNumber;
|
||||
|
||||
private Double roiBRangeStart;
|
||||
|
||||
private Double roiBRangeStop;
|
||||
|
||||
private Double roiGRangeStart;
|
||||
|
||||
private Double roiGRangeStop;
|
||||
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package org.jeecg.modules.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.jeecg.modules.entity.GardsBgEfficiencyPairs;
|
||||
|
||||
public interface GardsBgEfficiencyPairsMapper extends BaseMapper<GardsBgEfficiencyPairs> {
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package org.jeecg.modules.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.jeecg.modules.entity.GardsHistogram;
|
||||
|
||||
public interface GardsHistogramMapper extends BaseMapper<GardsHistogram> {
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package org.jeecg.modules.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.jeecg.modules.entity.GardsRoiLimits;
|
||||
|
||||
public interface GardsRoiLimitsMapper extends BaseMapper<GardsRoiLimits> {
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package org.jeecg.modules.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.jeecg.modules.entity.GardsSampleRatios;
|
||||
|
||||
public interface GardsSampleRatiosMapper extends BaseMapper<GardsSampleRatios> {
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
package org.jeecg.modules.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.jeecg.modules.entity.GardsSpectrum;
|
||||
|
||||
public interface GardsSpectrumMapper extends BaseMapper<GardsSpectrum> {
|
||||
}
|
|
@ -28,28 +28,7 @@ public interface IGardsSampleDataService extends IService<GardsSampleData> {
|
|||
* @param sampleId
|
||||
* @return
|
||||
*/
|
||||
Result findParticulateInfo(Integer sampleId);
|
||||
|
||||
/**
|
||||
* 查询谱数据的能量数据
|
||||
* @param sampleId
|
||||
* @return
|
||||
*/
|
||||
Result findParticulateEnergy(Integer sampleId);
|
||||
|
||||
/**
|
||||
* 查询
|
||||
* @param sampleId
|
||||
* @return
|
||||
*/
|
||||
Result findParticulateResolution(Integer sampleId);
|
||||
|
||||
/**
|
||||
* 查询
|
||||
* @param sampleId
|
||||
* @return
|
||||
*/
|
||||
Result findParticulateEfficiency(Integer sampleId);
|
||||
Result findGeneratedReport(Integer sampleId);
|
||||
|
||||
/**
|
||||
* 查询全部基础数据
|
||||
|
|
|
@ -9,15 +9,12 @@ import org.apache.commons.lang3.StringUtils;
|
|||
import org.jeecg.common.api.QueryRequest;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.jeecg.common.util.DateUtils;
|
||||
import org.jeecg.common.util.ReadLineUtil;
|
||||
import org.jeecg.common.util.RedisUtil;
|
||||
import org.jeecg.modules.entity.GardsCalibrationPairsOrig;
|
||||
import org.jeecg.modules.entity.GardsSampleAux;
|
||||
import org.jeecg.modules.entity.*;
|
||||
import org.jeecg.modules.base.entity.GardsSampleData;
|
||||
import org.jeecg.modules.entity.GardsSampleDescription;
|
||||
import org.jeecg.modules.mapper.GardsCalibrationPairsOrigMapper;
|
||||
import org.jeecg.modules.mapper.GardsSampleAuxMapper;
|
||||
import org.jeecg.modules.mapper.GardsSampleDataMapper;
|
||||
import org.jeecg.modules.mapper.GardsSampleDescriptionMapper;
|
||||
import org.jeecg.modules.entity.data.*;
|
||||
import org.jeecg.modules.mapper.*;
|
||||
import org.jeecg.modules.service.IGardsSampleDataService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
@ -40,6 +37,22 @@ public class GardsSampleDataServiceImpl extends ServiceImpl<GardsSampleDataMappe
|
|||
private GardsCalibrationPairsOrigMapper gardsCalibrationPairsOrigMapper;
|
||||
@Autowired
|
||||
private GardsSampleDescriptionMapper gardsSampleDescriptionMapper;
|
||||
@Autowired
|
||||
private GardsBgEfficiencyPairsMapper gardsBgEfficiencyPairsMapper;
|
||||
@Autowired
|
||||
private GardsRoiLimitsMapper gardsRoiLimitsMapper;
|
||||
@Autowired
|
||||
private GardsSampleRatiosMapper gardsSampleRatiosMapper;
|
||||
@Autowired
|
||||
private GardsSpectrumMapper gardsSpectrumMapper;
|
||||
@Autowired
|
||||
private GardsHistogramMapper gardsHistogramMapper;
|
||||
@Autowired
|
||||
private GardsSampleCertMapper gardsSampleCertMapper;
|
||||
@Autowired
|
||||
private GardsSampleCertLineMapper gardsSampleCertLineMapper;
|
||||
@Autowired
|
||||
private ReadLineUtil readLineUtil;
|
||||
|
||||
@Override
|
||||
public Result findParticulatePage(QueryRequest queryRequest, Integer[] stationIds, String dataType, String spectralQualifie, Date startTime,Date endTime) {
|
||||
|
@ -99,9 +112,46 @@ public class GardsSampleDataServiceImpl extends ServiceImpl<GardsSampleDataMappe
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result findParticulateInfo(Integer sampleId) {
|
||||
public Result findGeneratedReport(Integer sampleId) {
|
||||
Result result = new Result();
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
Report report = new Report();
|
||||
//查询info
|
||||
this.findInfo(sampleId, report);
|
||||
//查询G_energy
|
||||
this.findGEnergy(sampleId, report);
|
||||
//查询B_energy
|
||||
this.findBEnergy(sampleId, report);
|
||||
//查询G_Resolution
|
||||
this.findGResolution(sampleId, report);
|
||||
//查询B_Resolution
|
||||
this.findBResolution(sampleId, report);
|
||||
//查询G_Efficiency
|
||||
this.findGEfficiency(sampleId, report);
|
||||
//查询B_gEfficiency
|
||||
this.findBgEfficiency(sampleId, report);
|
||||
//查询ROI
|
||||
this.findRoiLimits(sampleId, report);
|
||||
//查询RATIOS
|
||||
this.findRatios(sampleId, report);
|
||||
//查询 GAMMA SPECTRUM
|
||||
this.findGSpectrum(sampleId, report);
|
||||
//查询 BETA SPECTRUM
|
||||
this.findBSpectrum(sampleId, report);
|
||||
//查询Histogram
|
||||
this.findHistogram(sampleId, report);
|
||||
//查询Certificate
|
||||
this.findCertificate(sampleId, report);
|
||||
result.setSuccess(true);
|
||||
result.setResult(report);
|
||||
return result;
|
||||
}
|
||||
|
||||
private void findInfo(Integer sampleId, Report report) {
|
||||
//声明多个对象 分别封装独立的信息
|
||||
GeneralInformation generalInformation = new GeneralInformation();
|
||||
Comment comment = new Comment();
|
||||
Acquisition acquisition = new Acquisition();
|
||||
Calibration calibration = new Calibration();
|
||||
//获取redis中缓存的台站信息
|
||||
Map<Integer, String> stationMap = (Map<Integer, String>)redisUtil.get("stationMap");
|
||||
//根据sample_id查询sample_data内容
|
||||
|
@ -122,128 +172,261 @@ public class GardsSampleDataServiceImpl extends ServiceImpl<GardsSampleDataMappe
|
|||
GardsSampleDescription gardsSampleDescription = gardsSampleDescriptionMapper.selectOne(descriptionQueryWrapper);
|
||||
if (Objects.nonNull(gardsSampleData)){
|
||||
//封装数据内容
|
||||
map.put("Site Code", gardsSampleData.getStationName());
|
||||
map.put("Detector Code",gardsSampleData.getSiteDetCode());
|
||||
map.put("System Type",gardsSampleData.getSampleType());
|
||||
map.put("Sample Geometry",gardsSampleData.getGeometry());
|
||||
map.put("Spectrum Qualifier",gardsSampleData.getSpectralQualifie());
|
||||
map.put("Transmit Time", gardsSampleData.getTransmitDtg());
|
||||
map.put("Acquisition Time", gardsSampleData.getAcquisitionStart());
|
||||
map.put("Acquisition Real Time", gardsSampleData.getAcquisitionRealSec());
|
||||
map.put("Acquisition Live Time", gardsSampleData.getAcquisitionLiveSec());
|
||||
generalInformation.setSiteCode(gardsSampleData.getStationName());
|
||||
generalInformation.setDetectorCode(gardsSampleData.getSiteDetCode());
|
||||
generalInformation.setSystemType(gardsSampleData.getSampleType());
|
||||
generalInformation.setSampleGeometry(gardsSampleData.getGeometry());
|
||||
generalInformation.setSpectrumQualifier(gardsSampleData.getSpectralQualifie());
|
||||
generalInformation.setTransmitDate(DateUtils.formatDate(gardsSampleData.getTransmitDtg(), "yyyy-MM-dd HH:mm:ss"));
|
||||
acquisition.setAcquisitionStartDate(DateUtils.formatDate(gardsSampleData.getAcquisitionStart(), "yyyy-MM-dd HH:mm:ss"));
|
||||
acquisition.setAcquisitionRealTime(gardsSampleData.getAcquisitionRealSec());
|
||||
acquisition.setAcquisitionLiveTime(gardsSampleData.getAcquisitionLiveSec());
|
||||
}
|
||||
if (Objects.nonNull(gardsSampleAux)){
|
||||
map.put("Sample Reference Identification", gardsSampleAux.getSampleRefId());
|
||||
map.put("Measurement Identification", gardsSampleAux.getMeasurementId());
|
||||
map.put("Detector Background Measurement Identification", gardsSampleAux.getBkgdMeasurementId());
|
||||
map.put("Gas Background Measurement Identification", gardsSampleAux.getGasBkgdMeasurementId());
|
||||
map.put("Date of Last Calibration", gardsSampleAux.getCalibrationDtg());
|
||||
generalInformation.setSampleReferenceIdentification(gardsSampleAux.getSampleRefId());
|
||||
generalInformation.setMeasurementIdentification(gardsSampleAux.getMeasurementId());
|
||||
generalInformation.setDetectorBackgroundMeasurementId(gardsSampleAux.getBkgdMeasurementId());
|
||||
generalInformation.setGasBackgroundMeasurementId(gardsSampleAux.getGasBkgdMeasurementId());
|
||||
calibration.setDateOfLastCalibration(DateUtils.formatDate(gardsSampleAux.getCalibrationDtg(), "yyyy-MM-dd HH:mm:ss"));
|
||||
}
|
||||
if (Objects.nonNull(gardsSampleDescription)){
|
||||
map.put("COMMENT", gardsSampleDescription.getDescription());
|
||||
comment.setText(gardsSampleDescription.getDescription());
|
||||
}
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
report.setHeaderBlock(generalInformation);
|
||||
report.setCommentBlock(comment);
|
||||
report.setAcquisitionBlock(acquisition);
|
||||
report.setCalibrationBlock(calibration);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Result findParticulateEnergy(Integer sampleId) {
|
||||
Result result = new Result();
|
||||
//map 封装三个数组
|
||||
Map<String, List<Double>> map = new HashMap<>();
|
||||
//封装存储 g_energy
|
||||
List<Double> GEnergyList = new LinkedList<>();
|
||||
//封装存储 Centroid channel
|
||||
List<Double> centroidChannelList = new LinkedList<>();
|
||||
//封装存储 Uncertainty
|
||||
List<Double> uncertaintyList = new LinkedList<>();
|
||||
private void findGEnergy(Integer sampleId, Report report) {
|
||||
List<GEnergy> gEnergySubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsCalibrationPairsOrig> calibrationPairsOrigQueryWrapper = new LambdaQueryWrapper<>();
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleType, "G");
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleId, sampleId);
|
||||
List<GardsCalibrationPairsOrig> gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigMapper.selectList(calibrationPairsOrigQueryWrapper);
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item-> item.getCaltype().trim().equals("energy")).collect(Collectors.toList());
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item->item.getCaltype().trim().equals("energy")).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(gardsCalibrationPairsOrigs)){
|
||||
for (GardsCalibrationPairsOrig orig:gardsCalibrationPairsOrigs) {
|
||||
// Xvalue 对应 centroid channel
|
||||
centroidChannelList.add(orig.getXvalue());
|
||||
// Yvalue 对应 g_energy
|
||||
GEnergyList.add(orig.getYvalue());
|
||||
// Uncyvalue 对应 Uncertainty
|
||||
uncertaintyList.add(orig.getUncyvalue());
|
||||
GEnergy gEnergy = new GEnergy();
|
||||
gEnergy.setEnergy(orig.getYvalue());
|
||||
gEnergy.setCentroid(orig.getXvalue());
|
||||
gEnergy.setUncertainty(orig.getUncyvalue());
|
||||
gEnergySubBlock.add(gEnergy);
|
||||
}
|
||||
}
|
||||
map.put("G_Energy", GEnergyList);
|
||||
map.put("Centroid channel", centroidChannelList);
|
||||
map.put("Uncertainty", uncertaintyList);
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
report.setGEnergyBlock(gEnergySubBlock);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Result findParticulateResolution(Integer sampleId) {
|
||||
Result result = new Result();
|
||||
//map 封装三个数组
|
||||
Map<String, List<Double>> map = new HashMap<>();
|
||||
//封装存储 g_energy
|
||||
List<Double> GEnergyList = new LinkedList<>();
|
||||
//封装存储 FWHM
|
||||
List<Double> FWHMList = new LinkedList<>();
|
||||
//封装存储 Uncertainty
|
||||
List<Double> uncertaintyList = new LinkedList<>();
|
||||
private void findBEnergy(Integer sampleId, Report report) {
|
||||
List<BEnergy> bEnergySubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsCalibrationPairsOrig> calibrationPairsOrigQueryWrapper = new LambdaQueryWrapper<>();
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleType, "B");
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleId, sampleId);
|
||||
List<GardsCalibrationPairsOrig> gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigMapper.selectList(calibrationPairsOrigQueryWrapper);
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item-> item.getCaltype().trim().equals("Resolution")).collect(Collectors.toList());
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item->item.getCaltype().trim().equals("energy")).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(gardsCalibrationPairsOrigs)){
|
||||
for (GardsCalibrationPairsOrig orig:gardsCalibrationPairsOrigs) {
|
||||
// Xvalue 对应 energy
|
||||
GEnergyList.add(orig.getXvalue());
|
||||
// YValue 对应 efficiency
|
||||
FWHMList.add(orig.getYvalue());
|
||||
// UncyValue 对应 Uncertainty
|
||||
uncertaintyList.add(orig.getUncyvalue());
|
||||
BEnergy bEnergy = new BEnergy();
|
||||
bEnergy.setElectronEnergy(orig.getYvalue());
|
||||
bEnergy.setMaximumChannel(orig.getXvalue());
|
||||
bEnergy.setUncertainty(orig.getUncyvalue());
|
||||
bEnergy.setDecayModeDescriptor(orig.getDecayMode());
|
||||
bEnergySubBlock.add(bEnergy);
|
||||
}
|
||||
}
|
||||
map.put("G_energy", GEnergyList);
|
||||
map.put("FWHM", FWHMList);
|
||||
map.put("Uncertainty", uncertaintyList);
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
report.setBEnergyBlock(bEnergySubBlock);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Result findParticulateEfficiency(Integer sampleId) {
|
||||
Result result = new Result();
|
||||
//map 封装三个数组
|
||||
Map<String, List<Double>> map = new HashMap<>();
|
||||
//封装存储 energy
|
||||
List<Double> energyList = new LinkedList<>();
|
||||
//封装存储 efficiency
|
||||
List<Double> efficiencyList = new LinkedList<>();
|
||||
//封装存储 Uncertainty
|
||||
List<Double> uncertaintyList = new LinkedList<>();
|
||||
private void findGResolution(Integer sampleId, Report report) {
|
||||
List<GResolution> gResolutionSubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsCalibrationPairsOrig> calibrationPairsOrigQueryWrapper = new LambdaQueryWrapper<>();
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleType, "G");
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleId, sampleId);
|
||||
List<GardsCalibrationPairsOrig> gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigMapper.selectList(calibrationPairsOrigQueryWrapper);
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item->item.getCaltype().trim().equals("Resolution")).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(gardsCalibrationPairsOrigs)){
|
||||
for (GardsCalibrationPairsOrig orig:gardsCalibrationPairsOrigs) {
|
||||
GResolution gResolution = new GResolution();
|
||||
gResolution.setEnergy(orig.getXvalue());
|
||||
gResolution.setFWHM(orig.getYvalue());
|
||||
gResolution.setUncertainty(orig.getUncyvalue());
|
||||
gResolutionSubBlock.add(gResolution);
|
||||
}
|
||||
}
|
||||
report.setGResolutionBlock(gResolutionSubBlock);
|
||||
}
|
||||
|
||||
private void findBResolution(Integer sampleId, Report report) {
|
||||
List<BResolution> bResolutionSubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsCalibrationPairsOrig> calibrationPairsOrigQueryWrapper = new LambdaQueryWrapper<>();
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleType, "B");
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleId, sampleId);
|
||||
List<GardsCalibrationPairsOrig> gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigMapper.selectList(calibrationPairsOrigQueryWrapper);
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item->item.getCaltype().trim().equals("Resolution")).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(gardsCalibrationPairsOrigs)){
|
||||
for (GardsCalibrationPairsOrig orig:gardsCalibrationPairsOrigs) {
|
||||
BResolution bResolution = new BResolution();
|
||||
bResolution.setElectronEnergy(orig.getXvalue());
|
||||
bResolution.setFWHM(orig.getYvalue());
|
||||
bResolution.setUncertainty(orig.getUncyvalue());
|
||||
bResolutionSubBlock.add(bResolution);
|
||||
}
|
||||
}
|
||||
report.setBResolutionBlock(bResolutionSubBlock);
|
||||
}
|
||||
|
||||
private void findGEfficiency(Integer sampleId, Report report) {
|
||||
List<GEfficiency> gEfficiencySubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsCalibrationPairsOrig> calibrationPairsOrigQueryWrapper = new LambdaQueryWrapper<>();
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleType, "G");
|
||||
calibrationPairsOrigQueryWrapper.eq(GardsCalibrationPairsOrig::getSampleId, sampleId);
|
||||
List<GardsCalibrationPairsOrig> gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigMapper.selectList(calibrationPairsOrigQueryWrapper);
|
||||
gardsCalibrationPairsOrigs = gardsCalibrationPairsOrigs.stream().filter(item->item.getCaltype().trim().equals("efficiency")).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(gardsCalibrationPairsOrigs)){
|
||||
for (GardsCalibrationPairsOrig orig:gardsCalibrationPairsOrigs) {
|
||||
// Xvalue 对应 energy
|
||||
energyList.add(orig.getXvalue());
|
||||
// YValue 对应 efficiency
|
||||
efficiencyList.add(orig.getYvalue());
|
||||
// UncyValue 对应 Uncertainty
|
||||
uncertaintyList.add(orig.getUncyvalue());
|
||||
GEfficiency gEfficiency = new GEfficiency();
|
||||
gEfficiency.setEnergy(orig.getXvalue());
|
||||
gEfficiency.setEfficiency(orig.getYvalue());
|
||||
gEfficiency.setUncertainty(orig.getUncyvalue());
|
||||
gEfficiencySubBlock.add(gEfficiency);
|
||||
}
|
||||
}
|
||||
map.put("Energy", energyList);
|
||||
map.put("Efficiency", efficiencyList);
|
||||
map.put("Uncertainty", uncertaintyList);
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
report.setGEfficiencyBlock(gEfficiencySubBlock);
|
||||
}
|
||||
|
||||
private void findBgEfficiency(Integer sampleId, Report report) {
|
||||
List<BEfficiency> bgEfficiencySubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsBgEfficiencyPairs> bgEfficiencyPairsQueryWrapper = new LambdaQueryWrapper<>();
|
||||
bgEfficiencyPairsQueryWrapper.eq(GardsBgEfficiencyPairs::getSampleId, sampleId);
|
||||
List<GardsBgEfficiencyPairs> gardsBgEfficiencyPairs = gardsBgEfficiencyPairsMapper.selectList(bgEfficiencyPairsQueryWrapper);
|
||||
if (CollectionUtils.isNotEmpty(gardsBgEfficiencyPairs)){
|
||||
for (GardsBgEfficiencyPairs pairs:gardsBgEfficiencyPairs) {
|
||||
BEfficiency bEfficiency = new BEfficiency();
|
||||
bEfficiency.setRoiNumber(pairs.getRoi());
|
||||
bEfficiency.setNuclideName(pairs.getNuclideName());
|
||||
bEfficiency.setCoincidenceEfficiency(pairs.getBgEfficiency());
|
||||
bEfficiency.setUncertainty(pairs.getBgEfficError());
|
||||
bgEfficiencySubBlock.add(bEfficiency);
|
||||
}
|
||||
}
|
||||
report.setBgEfficiencyBlock(bgEfficiencySubBlock);
|
||||
}
|
||||
|
||||
private void findRoiLimits(Integer sampleId, Report report) {
|
||||
List<Roi> roiLimitsSubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsRoiLimits> roiLimitsQueryWrapper = new LambdaQueryWrapper<>();
|
||||
roiLimitsQueryWrapper.eq(GardsRoiLimits::getSampleId, sampleId);
|
||||
List<GardsRoiLimits> gardsRoiLimitsList = gardsRoiLimitsMapper.selectList(roiLimitsQueryWrapper);
|
||||
if (CollectionUtils.isNotEmpty(gardsRoiLimitsList)){
|
||||
for (GardsRoiLimits roiLimits:gardsRoiLimitsList) {
|
||||
Roi roi = new Roi();
|
||||
roi.setRoiNumber(roiLimits.getRoi());
|
||||
roi.setRoiGRangeStart(roiLimits.getGEnergyStart());
|
||||
roi.setRoiGRangeStop(roiLimits.getGEnergyStop());
|
||||
roi.setRoiBRangeStart(roiLimits.getBEnergyStart());
|
||||
roi.setRoiBRangeStop(roiLimits.getBEnergyStop());
|
||||
roiLimitsSubBlock.add(roi);
|
||||
}
|
||||
}
|
||||
report.setRoiLimitsBlock(roiLimitsSubBlock);
|
||||
}
|
||||
|
||||
private void findRatios(Integer sampleId, Report report) {
|
||||
List<Ratios> ratiosSubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsSampleRatios> ratiosQueryWrapper = new LambdaQueryWrapper<>();
|
||||
ratiosQueryWrapper.eq(GardsSampleRatios::getSampleId, sampleId);
|
||||
List<GardsSampleRatios> sampleRatiosList = gardsSampleRatiosMapper.selectList(ratiosQueryWrapper);
|
||||
if (CollectionUtils.isNotEmpty(sampleRatiosList)){
|
||||
for (GardsSampleRatios sampleRatios:sampleRatiosList) {
|
||||
Ratios ratios = new Ratios();
|
||||
ratios.setCountRatio(sampleRatios.getCountRatio());
|
||||
ratios.setRatioId(sampleRatios.getRatioId());
|
||||
ratios.setCountRatioUncertainty(sampleRatios.getCountRatioErr());
|
||||
ratios.setRoiNumberLowerEnergy(sampleRatios.getLowerRoiNumber());
|
||||
ratios.setRoiNumberHigherEnergy(sampleRatios.getUpperRoiNumber());
|
||||
ratiosSubBlock.add(ratios);
|
||||
}
|
||||
}
|
||||
report.setRatiosBlock(ratiosSubBlock);
|
||||
}
|
||||
|
||||
private void findGSpectrum(Integer sampleId, Report report) {
|
||||
GammaSpectrum gSpectrumBlock = new GammaSpectrum();
|
||||
LambdaQueryWrapper<GardsSpectrum> spectrumQueryWrapper = new LambdaQueryWrapper<>();
|
||||
spectrumQueryWrapper.eq(GardsSpectrum::getSampleType, "G");
|
||||
spectrumQueryWrapper.eq(GardsSpectrum::getSampleId, sampleId);
|
||||
GardsSpectrum gardsSpectrum = gardsSpectrumMapper.selectOne(spectrumQueryWrapper);
|
||||
if (Objects.nonNull(gardsSpectrum)){
|
||||
List<Integer> gSpectrumSubBlock = readLineUtil.readLine(gardsSpectrum.getFileName());
|
||||
gSpectrumBlock.setGSpectrumSubBlock(gSpectrumSubBlock);
|
||||
gSpectrumBlock.setEnergySpan(gardsSpectrum.getEnergySpan());
|
||||
gSpectrumBlock.setNumberGChannels(gardsSpectrum.getChannels());
|
||||
}
|
||||
report.setGSpectrumBlock(gSpectrumBlock);
|
||||
}
|
||||
|
||||
private void findBSpectrum(Integer sampleId, Report report) {
|
||||
BetaSpectrum bSpectrumBlock = new BetaSpectrum();
|
||||
LambdaQueryWrapper<GardsSpectrum> spectrumQueryWrapper = new LambdaQueryWrapper<>();
|
||||
spectrumQueryWrapper.eq(GardsSpectrum::getSampleType, "B");
|
||||
spectrumQueryWrapper.eq(GardsSpectrum::getSampleId, sampleId);
|
||||
GardsSpectrum gardsSpectrum = gardsSpectrumMapper.selectOne(spectrumQueryWrapper);
|
||||
if (Objects.nonNull(gardsSpectrum)){
|
||||
List<Integer> bSpectrumSubBlock = readLineUtil.readLine(gardsSpectrum.getFileName());
|
||||
bSpectrumBlock.setBSpectrumSubBlock(bSpectrumSubBlock);
|
||||
bSpectrumBlock.setEnergySpan(gardsSpectrum.getEnergySpan());
|
||||
bSpectrumBlock.setNumberBChannels(gardsSpectrum.getChannels());
|
||||
}
|
||||
report.setBSpectrumBlock(bSpectrumBlock);
|
||||
}
|
||||
|
||||
private void findHistogram(Integer sampleId, Report report) {
|
||||
Histogram histogramBlock = new Histogram();
|
||||
LambdaQueryWrapper<GardsHistogram> histogramQueryWrapper = new LambdaQueryWrapper<>();
|
||||
histogramQueryWrapper.eq(GardsHistogram::getSampleId, sampleId);
|
||||
GardsHistogram gardsHistogram = gardsHistogramMapper.selectOne(histogramQueryWrapper);
|
||||
if (Objects.nonNull(gardsHistogram)){
|
||||
List<Integer> histogramSubBlock = readLineUtil.readLine(gardsHistogram.getFileName());
|
||||
histogramBlock.setHistogramSubBlock(histogramSubBlock);
|
||||
histogramBlock.setBChannels(gardsHistogram.getBChannels());
|
||||
histogramBlock.setBEnergySpan(gardsHistogram.getBEnergySpan());
|
||||
histogramBlock.setGChannels(gardsHistogram.getGChannels());
|
||||
histogramBlock.setGEnergySpan(gardsHistogram.getGEnergySpan());
|
||||
}
|
||||
report.setHistogramBlock(histogramBlock);
|
||||
}
|
||||
|
||||
private void findCertificate(Integer sampleId, Report report) {
|
||||
Certificate certificateBlock = new Certificate();
|
||||
List<CertificateLine> certificateSubBlock = new LinkedList<>();
|
||||
LambdaQueryWrapper<GardsSampleCert> sampleCertQueryWrapper = new LambdaQueryWrapper<>();
|
||||
sampleCertQueryWrapper.eq(GardsSampleCert::getSampleId, sampleId);
|
||||
GardsSampleCert gardsSampleCert = gardsSampleCertMapper.selectOne(sampleCertQueryWrapper);
|
||||
if (Objects.nonNull(gardsSampleCert)){
|
||||
certificateBlock.setTotalSourceActivity(gardsSampleCert.getQuantity());
|
||||
certificateBlock.setAssayDate(DateUtils.formatDate(gardsSampleCert.getAssayDate(), "yyyy-MM-dd HH:mm:ss"));
|
||||
certificateBlock.setUnitsOfActivity(gardsSampleCert.getUnit());
|
||||
}
|
||||
LambdaQueryWrapper<GardsSampleCertLine> sampleCertLineQueryWrapper = new LambdaQueryWrapper<>();
|
||||
sampleCertLineQueryWrapper.eq(GardsSampleCertLine::getSampleId, sampleId);
|
||||
List<GardsSampleCertLine> gardsSampleCertLines = gardsSampleCertLineMapper.selectList(sampleCertLineQueryWrapper);
|
||||
if (CollectionUtils.isNotEmpty(gardsSampleCertLines)){
|
||||
for (GardsSampleCertLine sampleCertLine:gardsSampleCertLines) {
|
||||
CertificateLine certificateLine = new CertificateLine();
|
||||
certificateLine.setNuclideName(sampleCertLine.getNuclName());
|
||||
certificateLine.setHalfLife(sampleCertLine.getHalflife());
|
||||
certificateLine.setNuclideActivity(sampleCertLine.getActivity());
|
||||
certificateLine.setUncertainty(sampleCertLine.getError());
|
||||
certificateLine.setGenergy(sampleCertLine.getEnergy());
|
||||
certificateLine.setIntensity(sampleCertLine.getAbundance());
|
||||
certificateLine.setElectronDecayModeDescriptor(sampleCertLine.getDecayMode());
|
||||
certificateLine.setMaxBParticleEnergy(sampleCertLine.getBEnergy());
|
||||
certificateLine.setParticleBIntensity(sampleCertLine.getBAbundance());
|
||||
certificateSubBlock.add(certificateLine);
|
||||
}
|
||||
}
|
||||
certificateBlock.setCertificateSubBlock(certificateSubBlock);
|
||||
report.setCertificateBlock(certificateBlock);
|
||||
}
|
||||
|
||||
@Transactional(propagation = Propagation.REQUIRES_NEW,rollbackFor = Exception.class)
|
||||
|
|
|
@ -54,6 +54,7 @@ public class GardsStations implements Serializable {
|
|||
|
||||
@TableField(value = "MODDATE")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
}
|
||||
|
|
|
@ -15,4 +15,4 @@ spring:
|
|||
config:
|
||||
import:
|
||||
- optional:nacos:jeecg.yaml
|
||||
- optional:nacos:jeecg-web-statistics-@profile.name@.yaml
|
||||
- optional:nacos:jeecg-@profile.name@.yaml
|
Loading…
Reference in New Issue
Block a user