Merge remote-tracking branch 'origin/station' into station
# Conflicts: # jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/ISpectrumAnalysisService.java # jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/SpectrumAnalysisServiceImpl.java
This commit is contained in:
commit
21a706a263
|
@ -32,10 +32,16 @@ public class AnalyseData implements Serializable {
|
|||
|
||||
private CalibrationParam b_calibration_param;
|
||||
|
||||
private String dbName;
|
||||
private List<String> dbNames;
|
||||
|
||||
private List<Integer> sampleIds;
|
||||
|
||||
private List<String> sampleFileNames;
|
||||
|
||||
private List<String> gasFileNames;
|
||||
|
||||
private List<String> detFileNames;
|
||||
|
||||
public AnalyseData(){
|
||||
sampleData = false;
|
||||
GasBgData = false;
|
||||
|
|
|
@ -13,6 +13,8 @@ public class StatisticsQueryData implements Serializable {
|
|||
|
||||
private String dbName;
|
||||
|
||||
private Integer detectorId;
|
||||
|
||||
private String detectorName;
|
||||
|
||||
private Integer stationId;
|
||||
|
@ -57,6 +59,6 @@ public class StatisticsQueryData implements Serializable {
|
|||
|
||||
private String endDate;
|
||||
|
||||
private List<String> detectorList;
|
||||
private List<Integer> detectorList;
|
||||
|
||||
}
|
||||
|
|
|
@ -65,6 +65,7 @@ public class GammaFileUtil {
|
|||
result.error500("ftp连接失败");
|
||||
return false;
|
||||
}
|
||||
InputStream inputStream = null;
|
||||
//加载dll工具库
|
||||
System.loadLibrary("ReadPHDFile");
|
||||
try {
|
||||
|
@ -83,7 +84,7 @@ public class GammaFileUtil {
|
|||
}
|
||||
FTPFile ftpFile = ftpFiles.get(0);
|
||||
if (Objects.nonNull(ftpFile)) {
|
||||
InputStream inputStream = ftpClient.retrieveFileStream(ftpFile.getName());
|
||||
inputStream = ftpClient.retrieveFileStream(ftpFile.getName());
|
||||
//声明一个临时文件
|
||||
File file = File.createTempFile("tmp", null);
|
||||
//将ftp文件的输入流复制给临时文件
|
||||
|
@ -242,8 +243,8 @@ public class GammaFileUtil {
|
|||
phd.getSetting().setECutAnalysis_Low(35.0);
|
||||
phd.getSetting().setBUpdateCal(true);
|
||||
}
|
||||
phd.getSetting().setRefTime_conc(DateUtils.parseDate(phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time().substring(0, phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss"));
|
||||
phd.getSetting().setRefTime_act(DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss"));
|
||||
phd.getSetting().setRefTime_conc(DateUtils.parseDate(phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time().substring(0, phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss"));
|
||||
phd.getSetting().setRefTime_act(DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss"));
|
||||
phd.setUsedSetting(phd.getSetting());
|
||||
|
||||
phd.setBAnalyed(false);
|
||||
|
@ -259,6 +260,9 @@ public class GammaFileUtil {
|
|||
if (Objects.nonNull(ftpClient)){
|
||||
ftpClient.disconnect();
|
||||
}
|
||||
if (Objects.nonNull(inputStream)){
|
||||
inputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
|
@ -271,7 +275,6 @@ public class GammaFileUtil {
|
|||
String fileName = phd.getFilename();
|
||||
//文件名称需要加上自动处理的前缀以及修改不同的文件后缀名
|
||||
String subFileName = fileName.substring(0, fileName.lastIndexOf(StringPool.DOT));
|
||||
pathName = StringPool.SLASH + spectrumPathProperties.getRootPath() + StringPool.SLASH + pathName;
|
||||
if(StringUtils.isNotBlank(subFileName)){
|
||||
//连接ftp
|
||||
FTPClient ftpClient = ftpUtil.LoginFTP();
|
||||
|
@ -406,7 +409,7 @@ public class GammaFileUtil {
|
|||
j++;
|
||||
line = readLines.get(j);
|
||||
if (!line.contains("#")){
|
||||
line1 += " " + line;
|
||||
line1 += StringPool.SPACE + line;
|
||||
}else {
|
||||
break;
|
||||
}
|
||||
|
@ -441,7 +444,7 @@ public class GammaFileUtil {
|
|||
j++;
|
||||
line = readLines.get(j);
|
||||
if (!line.contains("#")){
|
||||
block_data += " " + line;
|
||||
block_data += StringPool.SPACE + line;
|
||||
}else {
|
||||
break;
|
||||
}
|
||||
|
@ -792,12 +795,14 @@ public class GammaFileUtil {
|
|||
qcState.set(3, phd.getQcItems().get("samp_vol").isBPass()?"BLUE":"RED");
|
||||
|
||||
if(phd.getHeader().getSystem_type().equalsIgnoreCase("P")) {
|
||||
if(Objects.isNull(phd.getQcItems().get("Be7-FWHM"))) {
|
||||
if(Objects.nonNull(phd.getQcItems().get("Be7-FWHM"))) {
|
||||
qcState.set(4, phd.getQcItems().get("Be7-FWHM").isBPass()?"BLUE":"RED");
|
||||
}
|
||||
if(Objects.nonNull(phd.getQcItems().get("Ba140-MDC"))) {
|
||||
qcState.set(5, phd.getQcItems().get("Ba140-MDC").isBPass()?"BLUE":"RED");
|
||||
}
|
||||
} else if(phd.getHeader().getSystem_type().equalsIgnoreCase("G")) {
|
||||
if(Objects.isNull(phd.getQcItems().get("Xe133-MDC"))) {
|
||||
if(Objects.nonNull(phd.getQcItems().get("Xe133-MDC"))) {
|
||||
qcState.set(6, phd.getQcItems().get("Xe133-MDC").isBPass()?"BLUE":"RED");
|
||||
}
|
||||
}
|
||||
|
@ -807,13 +812,13 @@ public class GammaFileUtil {
|
|||
public void RunQC(PHDFile phd){
|
||||
System.loadLibrary("GammaAnaly");
|
||||
try {
|
||||
Date start = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time().substring(0, phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)),"yyyy/MM/dd HH:mm:ss");
|
||||
Date end = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time().substring(0, phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT)),"yyyy/MM/dd HH:mm:ss");
|
||||
Date acq = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)),"yyyy/MM/dd HH:mm:ss");
|
||||
Date start = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time());
|
||||
Date end = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time());
|
||||
Date acq = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time());
|
||||
|
||||
double collect_hour = (start.getTime()/1000 - end.getTime()/1000) / 3600.0;
|
||||
double collect_hour = (end.getTime()/1000 - start.getTime()/1000) / 3600.0;
|
||||
double acq_hour = phd.getAcq().getAcquisition_real_time() / 3600.0;
|
||||
double Decay_hour = (end.getTime()/1000 - acq.getTime()/1000) / 3600.0;
|
||||
double Decay_hour = (acq.getTime()/1000 - end.getTime()/1000) / 3600.0;
|
||||
|
||||
Double ener_Be7 = 0.0;
|
||||
Map<String, Double> vMdcInfoMap = new HashMap<>();
|
||||
|
@ -912,9 +917,9 @@ public class GammaFileUtil {
|
|||
if(vMdcInfo.size() < 3 || vMdcInfo.get(2) == 0) {
|
||||
return 0.0;
|
||||
}
|
||||
Date collectStart = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time().substring(0,phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStop = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time().substring(0,phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date acqStart = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time().substring(0,phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStart = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time().substring(0,phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStop = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time().substring(0,phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date acqStart = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time().substring(0,phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
double Ts = (collectStart.getTime()/1000 - collectStop.getTime()/1000); // 采样时间
|
||||
double Td = (collectStop.getTime()/1000 - acqStart.getTime()/1000); // 衰变时间
|
||||
double Ta = phd.getAcq().getAcquisition_real_time(); // 能谱获取实时间
|
||||
|
@ -1146,18 +1151,18 @@ public class GammaFileUtil {
|
|||
detailInfo.set(5, phd.getHeader().getSpectrum_quantity()); // Spectral_Qualifier
|
||||
detailInfo.set(6, phd.getHeader().getSample_ref_id()); // SRID
|
||||
detailInfo.set(7, phd.getStatus()); // Sample_Status
|
||||
String collect_stop = phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time().substring(0,phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT));
|
||||
String collect_stop = phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time().substring(0,phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT));
|
||||
Date collect_stop_dt = DateUtils.parseDate(collect_stop,"yyyy/MM/dd HH:mm:ss");
|
||||
detailInfo.set(8, phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time());
|
||||
Date date = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time().substring(0,phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)),"yyyy/MM/dd HH:mm:ss");
|
||||
detailInfo.set(8, phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time());
|
||||
Date date = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time().substring(0,phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)),"yyyy/MM/dd HH:mm:ss");
|
||||
double timeSpan = (collect_stop_dt.getTime()/1000 - date.getTime()/1000) / 3600.0;
|
||||
detailInfo.set(9, String.format("%.2f", timeSpan));// Sampling_Time
|
||||
detailInfo.set(10, String.format("%.2f", phd.getCollect().getAir_volume()));
|
||||
if(timeSpan != 0){
|
||||
detailInfo.set(11, String.format("%.2f", phd.getCollect().getAir_volume()/timeSpan));
|
||||
}
|
||||
detailInfo.set(12, phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time());
|
||||
String start_time = phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT));
|
||||
detailInfo.set(12, phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time());
|
||||
String start_time = phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT));
|
||||
Date start_date = DateUtils.parseDate(start_time, "yyyy/MM/dd HH:mm:ss");
|
||||
detailInfo.set(13, String.format("%.2f", phd.getAcq().getAcquisition_real_time()));
|
||||
detailInfo.set(14, String.format("%.2f", phd.getAcq().getAcquisition_live_time()));
|
||||
|
@ -1771,9 +1776,9 @@ public class GammaFileUtil {
|
|||
private boolean CalculateMDCs(PHDFile phd, NuclideActMda nucActMda, int mainPeakIdx, double lambda, double keyLineYield, double CCF){
|
||||
// 计算衰变校正因子——DCF
|
||||
try {
|
||||
Date collectStart = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time().substring(0, phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStop = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time().substring(0, phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date acqStart = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStart = DateUtils.parseDate(phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time().substring(0, phd.getCollect().getCollection_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date collectStop = DateUtils.parseDate(phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time().substring(0, phd.getCollect().getCollection_stop_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
Date acqStart = DateUtils.parseDate(phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time().substring(0, phd.getAcq().getAcquisition_start_time().indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
double Ts = collectStart.getTime()/1000 - collectStop.getTime()/1000; // 采样时间
|
||||
double Td = collectStop.getTime()/1000 - acqStart.getTime()/1000; // 衰变时间
|
||||
double Ta = phd.getAcq().getAcquisition_real_time(); // 能谱获取实时间
|
||||
|
@ -2015,7 +2020,7 @@ public class GammaFileUtil {
|
|||
// Polynomial: y=a0+a1*x+a2*x^2+a3*x^3
|
||||
equation +="Energy = "+m_curParam.getP().get(1)+" + C * "+m_curParam.getP().get(2);
|
||||
for(int i=3; i<=p_size; ++i) {
|
||||
equation += " + C<span style=\"vertical-align:super;\">" + (i-1) +"</span> * "+m_curParam.getP().get(i)+"";
|
||||
equation += " + C<sup style=\"vertical-align:super;\">" + (i-1) +"</sup> * "+m_curParam.getP().get(i)+"";
|
||||
}
|
||||
} else if(p_size == 1) {
|
||||
equation = "Energy = "+m_curParam.getP().get(1)+" * C";
|
||||
|
@ -2081,9 +2086,9 @@ public class GammaFileUtil {
|
|||
// Square root of polynomial: y = sqrt(a0+a1*x+a2*x^2+a3*x^3 )
|
||||
equation += "FWHM = ("+m_curParam.getP().get(1)+" + E * "+m_curParam.getP().get(2);
|
||||
for(int i=3; i<=p_size; ++i) {
|
||||
equation += " + E<span style=\"vertical-align:super;\">"+(i-1)+"</span> * "+m_curParam.getP().get(i);
|
||||
equation += " + E<sup style=\"vertical-align:super;\">"+(i-1)+"</sup> * "+m_curParam.getP().get(i);
|
||||
}
|
||||
equation += ")<span style=\"vertical-align:super;\">"+1+"/"+2+"</span>";
|
||||
equation += ")<sup style=\"vertical-align:super;\">"+1+"/"+2+"</sup>";
|
||||
}
|
||||
return equation;
|
||||
}
|
||||
|
@ -2177,15 +2182,15 @@ public class GammaFileUtil {
|
|||
for(int i=1; i<=p_size; ++i) {
|
||||
if(m_curParam.getP().get(i) <= 0) break;
|
||||
}
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<span style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</span>) * "+
|
||||
"(1-exp(-("+m_curParam.getP().get(4)+" / E)<span style=\"vertical-align:super;\">"+m_curParam.getP().get(5)+"</span>))";
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</sup>) * "+
|
||||
"(1-exp(-("+m_curParam.getP().get(4)+" / E)<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(5)+"</sup>))";
|
||||
}
|
||||
break;
|
||||
case 6: // Polynomial in log(y) against log(x): log(y) = a0 + a1*log(x) +a2*log(x)^2+ a3*log(x)^3
|
||||
if(p_size >= 2) {
|
||||
equation += "log(Efficiency) = "+m_curParam.getP().get(1)+" + "+m_curParam.getP().get(2)+" * log(E)";
|
||||
for(int i=3; i<=p_size; ++i) {
|
||||
equation += " + "+m_curParam.getP().get(i)+" * log(E)<span style=\"vertical-align:super;\">"+(i-1)+"</span>";
|
||||
equation += " + "+m_curParam.getP().get(i)+" * log(E)<sup style=\"vertical-align:super;\">"+(i-1)+"</sup>";
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -2193,27 +2198,27 @@ public class GammaFileUtil {
|
|||
if(p_size >= 3) {
|
||||
equation += "log(Efficiency) = "+m_curParam.getP().get(1)+" + "+m_curParam.getP().get(2)+" * log(C/E)";
|
||||
for(int i=3; i<=p_size; ++i) {
|
||||
equation += " + "+m_curParam.getP().get(i)+" * log(C/E)<span style=\"vertical-align:super;\">"+(i-1)+"</span>";
|
||||
equation += " + "+m_curParam.getP().get(i)+" * log(C/E)<sup style=\"vertical-align:super;\">"+(i-1)+"</sup>";
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 93: // HAE Efficiency (1-3): y=S*exp(-(E1/x)^k)*(1- exp(-(2*E3/(x-E3))^n))
|
||||
if(p_size == 5) {
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<span style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</span>) * "+
|
||||
"(1 - exp(-(2 * "+m_curParam.getP().get(4)+" / (E - "+m_curParam.getP().get(4)+"))<span style=\"vertical-align:super;\">"+m_curParam.getP().get(5)+"</span>))";
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</sup>) * "+
|
||||
"(1 - exp(-(2 * "+m_curParam.getP().get(4)+" / (E - "+m_curParam.getP().get(4)+"))<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(5)+"</sup>))";
|
||||
}
|
||||
break;
|
||||
case 94: // HAE Efficiency (1-2): y=S*exp(-(E1/x)^k)*(1- exp(-b*(1/(x-E2))^m))
|
||||
if(p_size == 6) {
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<span style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</span>) * "+
|
||||
"(1 - exp(-"+m_curParam.getP().get(4)+" * (1 / (E - "+m_curParam.getP().get(5)+"))<span style=\"vertical-align:super;\">"+m_curParam.getP().get(6)+"</span>))";
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</sup>) * "+
|
||||
"(1 - exp(-"+m_curParam.getP().get(4)+" * (1 / (E - "+m_curParam.getP().get(5)+"))<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(6)+"</sup>))";
|
||||
}
|
||||
break;
|
||||
case 95: // HAE Efficiency (1-2-3): y = S * exp(-(E1/x)^k) * (1- exp(-b*(1/(x-E2))^m)) *(1 - exp(-(2*E3/(E-E3))^n))
|
||||
if(p_size == 8) {
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<span style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</span>) * "+
|
||||
"(1 - exp(-"+m_curParam.getP().get(4)+" * (1 / (E - "+m_curParam.getP().get(5)+"))<span style=\"vertical-align:super;\">"+m_curParam.getP().get(6)+"</span>)) * "+
|
||||
"(1 - exp(-(2 * "+m_curParam.getP().get(7)+" / (E - "+m_curParam.getP().get(7)+"))<span style=\"vertical-align:super;\">"+m_curParam.getP().get(8)+"</span>))";
|
||||
equation += "Efficiency = "+m_curParam.getP().get(1)+" * exp(-("+m_curParam.getP().get(2)+" / E)<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(3)+"</sup>) * "+
|
||||
"(1 - exp(-"+m_curParam.getP().get(4)+" * (1 / (E - "+m_curParam.getP().get(5)+"))<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(6)+"</sup>)) * "+
|
||||
"(1 - exp(-(2 * "+m_curParam.getP().get(7)+" / (E - "+m_curParam.getP().get(7)+"))<sup style=\"vertical-align:super;\">"+m_curParam.getP().get(8)+"</sup>))";
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -2606,27 +2611,27 @@ public class GammaFileUtil {
|
|||
strBuffer.append(" \n");
|
||||
strBuffer.append(" Nuclide Halflife(s) Activity(Bq) RelErr% MDA(Bq) Conc(uBq/m^3) MDC\n");
|
||||
for (int i=0; i<middleData.nucl_ided_Nuclidename.size(); i++) {
|
||||
strBuffer.append(" " + middleData.nucl_ided_Nuclidename.get(i) + " " + middleData.nucl_ided_Halflife.get(i) + " " + String.format("%.3f", Double.valueOf(middleData.nucl_ided_activ_key.get(i)))+
|
||||
strBuffer.append(StringPool.SPACE + middleData.nucl_ided_Nuclidename.get(i) + " " + middleData.nucl_ided_Halflife.get(i) + " " + String.format("%.3f", Double.valueOf(middleData.nucl_ided_activ_key.get(i)))+
|
||||
" "+String.format("%.3f", Double.valueOf(middleData.nucl_ided_activ_key_err.get(i))/Double.valueOf(middleData.nucl_ided_activ_key.get(i))*100)+
|
||||
" "+middleData.nucl_ided_mda.get(i)+" "+middleData.nucl_ided_Concentration.get(i)+" "+middleData.nucl_ided_MDC.get(i)+"\n");
|
||||
}
|
||||
strBuffer.append(" \n");
|
||||
strBuffer.append("#PEAK SEARCH RESULTS\n");
|
||||
strBuffer.append(" "+middleData.peaks_idPeak.size()+" peaks reported\n");
|
||||
strBuffer.append(StringPool.SPACE+middleData.peaks_idPeak.size()+" peaks reported\n");
|
||||
double peaksUsed = 0;
|
||||
for(int m=0;m<middleData.peaks_Nuclide_name.size();m++) {
|
||||
if(StringUtils.isNotBlank(middleData.peaks_Nuclide_name.get(m))) {
|
||||
peaksUsed++;
|
||||
}
|
||||
}
|
||||
strBuffer.append(" "+peaksUsed+" peaks with ID ("+(peaksUsed/middleData.peaks_idPeak.size()*100)+"%)\n");
|
||||
strBuffer.append(" "+(middleData.peaks_idPeak.size()-peaksUsed)+" peaks without ID("+Double.valueOf(middleData.peaks_idPeak.size()-peaksUsed)/middleData.peaks_idPeak.size()*100+"%)\n");
|
||||
strBuffer.append(StringPool.SPACE+peaksUsed+" peaks with ID ("+(peaksUsed/middleData.peaks_idPeak.size()*100)+"%)\n");
|
||||
strBuffer.append(StringPool.SPACE+(middleData.peaks_idPeak.size()-peaksUsed)+" peaks without ID("+Double.valueOf(middleData.peaks_idPeak.size()-peaksUsed)/middleData.peaks_idPeak.size()*100+"%)\n");
|
||||
strBuffer.append(" \n");
|
||||
strBuffer.append(" \n");
|
||||
strBuffer.append(" \n");
|
||||
strBuffer.append(" PeakID Energy[kev] Centroid FWHM[kev] NetArea NAErr% Signif Sensit Nuclide\n");
|
||||
for (int i=0; i<middleData.peaks_idPeak.size(); i++){
|
||||
strBuffer.append(" "+middleData.peaks_idPeak.get(i)+" "+String.format("%.3f", Double.valueOf(middleData.peaks_Energy.get(i)))+" "+String.format("%.3f", Double.valueOf(middleData.peaks_peakCentroid.get(i)))+
|
||||
strBuffer.append(StringPool.SPACE+middleData.peaks_idPeak.get(i)+" "+String.format("%.3f", Double.valueOf(middleData.peaks_Energy.get(i)))+" "+String.format("%.3f", Double.valueOf(middleData.peaks_peakCentroid.get(i)))+
|
||||
" "+String.format("%.3f", Double.valueOf(middleData.peaks_Fwhm.get(i)))+" "+String.format("%.3f", Double.valueOf(middleData.peaks_Area.get(i)))+
|
||||
" "+String.format("%.3f", (Double.valueOf(middleData.peaks_areaErr.get(i))/Double.valueOf(middleData.peaks_Area.get(i))*100))+
|
||||
" "+String.format("%.3f", Double.valueOf(middleData.peaks_Significance.get(i)))+" "+String.format("%.3f", Double.valueOf(middleData.peaks_Sensitivity.get(i)))+" "+middleData.peaks_Nuclide_name+"\n");
|
||||
|
@ -2699,7 +2704,7 @@ public class GammaFileUtil {
|
|||
strBuffer.append("#DATA QUALITY FLAGS\n");
|
||||
strBuffer.append(" Name Pass/Fail Value Test\n");
|
||||
for (int i=0;i<middleData.QC_CHECK_QC_NAME.size(); i++){
|
||||
strBuffer.append(" "+middleData.QC_CHECK_QC_NAME.get(i)+" "+(middleData.QC_CHECK_QC_RESULT.get(i).equals("0")?"Fail":"Pass")+
|
||||
strBuffer.append(StringPool.SPACE+middleData.QC_CHECK_QC_NAME.get(i)+" "+(middleData.QC_CHECK_QC_RESULT.get(i).equals("0")?"Fail":"Pass")+
|
||||
" "+String.format("%.3f", Double.valueOf(middleData.QC_CHECK_QC_VALUE.get(i)))+" "+middleData.QC_CHECK_QC_STANDARD.get(i)+"\n");
|
||||
}
|
||||
return strBuffer.toString();
|
||||
|
@ -2777,7 +2782,6 @@ public class GammaFileUtil {
|
|||
|
||||
public boolean GetMiddleData(PHDFile fileAnlyse, String userName,Map<String, NuclideLines> nucline,GStoreMiddleProcessData middleData, String type) throws ParseException {
|
||||
boolean bRet=true;
|
||||
|
||||
//标准名称规范化
|
||||
String dataType = fileAnlyse.getMsgInfo().getData_type();
|
||||
String subDirSavePath = "";
|
||||
|
@ -3343,8 +3347,8 @@ public class GammaFileUtil {
|
|||
}
|
||||
|
||||
//sample info
|
||||
middleData.sample_collection_start = fileAnlyse.getCollect().getCollection_start_date()+" "+fileAnlyse.getCollect().getCollection_start_time();
|
||||
middleData.sample_collection_stop = fileAnlyse.getCollect().getCollection_stop_date()+" "+fileAnlyse.getCollect().getCollection_stop_time();
|
||||
middleData.sample_collection_start = fileAnlyse.getCollect().getCollection_start_date()+StringPool.SPACE+fileAnlyse.getCollect().getCollection_start_time();
|
||||
middleData.sample_collection_stop = fileAnlyse.getCollect().getCollection_stop_date()+StringPool.SPACE+fileAnlyse.getCollect().getCollection_stop_time();
|
||||
|
||||
if(Objects.nonNull(fileAnlyse.getQcItems().get("col_time"))) {
|
||||
middleData.sample_time = String.format("%.4f", fileAnlyse.getQcItems().get("col_time").getValue());
|
||||
|
@ -3359,7 +3363,7 @@ public class GammaFileUtil {
|
|||
middleData.sample_acquistion_time = String.format("%.5f", fileAnlyse.getQcItems().get("acq_time").getValue());
|
||||
}
|
||||
middleData.sample_quantity = String.format("%.4f", fileAnlyse.getCollect().getAir_volume());
|
||||
middleData.sample_acquisiton_start = fileAnlyse.getAcq().getAcquisition_start_date()+" "+fileAnlyse.getAcq().getAcquisition_start_time();
|
||||
middleData.sample_acquisiton_start = fileAnlyse.getAcq().getAcquisition_start_date()+StringPool.SPACE+fileAnlyse.getAcq().getAcquisition_start_time();
|
||||
String acquisition_start = middleData.sample_acquisiton_start;
|
||||
Date dataTime = DateUtils.parseDate(acquisition_start.substring(0, acquisition_start.indexOf(StringPool.DOT)), "yyyy/MM/dd HH:mm:ss");
|
||||
acquisition_start = DateUtils.formatDate(dataTime, "yyyy/MM/dd HH:mm:ss");
|
||||
|
@ -3408,7 +3412,7 @@ public class GammaFileUtil {
|
|||
halflife /= 3600;
|
||||
units = 'H';
|
||||
}
|
||||
tableNuclideActivity.setHalfLife(halflife+" "+units);
|
||||
tableNuclideActivity.setHalfLife(halflife+StringPool.SPACE+units);
|
||||
tableNuclideActivity.setEnergy(nuc.getVEnergy().get(nuc.getCalculateIdx()).toString());
|
||||
tableNuclideActivity.setYield(String.valueOf(nuc.getVYield().get(nuc.getCalculateIdx())*100));
|
||||
|
||||
|
@ -3436,7 +3440,7 @@ public class GammaFileUtil {
|
|||
}
|
||||
|
||||
public String RightFill(String str, int fieldWidth) {
|
||||
String fillChar = " ";
|
||||
String fillChar = StringPool.SPACE;
|
||||
int fillNum = fieldWidth - str.length();
|
||||
while(fillNum > 0) {
|
||||
str+=fillChar;
|
||||
|
@ -3450,11 +3454,11 @@ public class GammaFileUtil {
|
|||
|
||||
spectrum.append("BEGIN IMS2.0\r\n");
|
||||
spectrum.append("MSG_TYPE "+phd.getMsgInfo().getMsg_type()+"\r\n");
|
||||
spectrum.append("MSG_ID "+phd.getMsgInfo().getMsg_id()+" "+phd.getMsgInfo().getMsg_src_code()+"\r\n");
|
||||
spectrum.append("MSG_ID "+phd.getMsgInfo().getMsg_id()+StringPool.SPACE+phd.getMsgInfo().getMsg_src_code()+"\r\n");
|
||||
if(phd.getMsgInfo().isVerify_srid()) {
|
||||
spectrum.append("REF_ID\r\n");
|
||||
spectrum.append(phd.getMsgInfo().getRef_id_str()+" "+phd.getMsgInfo().getRef_src_code()+" "+phd.getMsgInfo().getSeq_num()+" "+phd.getMsgInfo().getTot_num()+"\r\n");
|
||||
spectrum.append("PROD_ID "+phd.getMsgInfo().getProduct_id()+" "+phd.getMsgInfo().getDelivery_id()+"\r\n");
|
||||
spectrum.append(phd.getMsgInfo().getRef_id_str()+StringPool.SPACE+phd.getMsgInfo().getRef_src_code()+StringPool.SPACE+phd.getMsgInfo().getSeq_num()+StringPool.SPACE+phd.getMsgInfo().getTot_num()+"\r\n");
|
||||
spectrum.append("PROD_ID "+phd.getMsgInfo().getProduct_id()+StringPool.SPACE+phd.getMsgInfo().getDelivery_id()+"\r\n");
|
||||
}
|
||||
spectrum.append("DATA_TYPE "+phd.getMsgInfo().getData_type()+"\r\n");
|
||||
|
||||
|
@ -3475,13 +3479,13 @@ public class GammaFileUtil {
|
|||
// #Header
|
||||
spectrum.append("#Header "+phd.getHeader().getDesignator()+"\r\n");
|
||||
spectrum.append(RightFill(phd.getHeader().getSite_code(), 5)+
|
||||
" "+RightFill(phd.getHeader().getDetector_code(), 9)+
|
||||
" "+RightFill(phd.getHeader().getSystem_type().toUpperCase(), 1)+
|
||||
" "+RightFill(phd.getHeader().getSample_geometry(), 17)+
|
||||
" "+RightFill(phd.getHeader().getSpectrum_quantity(), 4)+"\r\n");
|
||||
StringPool.SPACE+RightFill(phd.getHeader().getDetector_code(), 9)+
|
||||
StringPool.SPACE+RightFill(phd.getHeader().getSystem_type().toUpperCase(), 1)+
|
||||
StringPool.SPACE+RightFill(phd.getHeader().getSample_geometry(), 17)+
|
||||
StringPool.SPACE+RightFill(phd.getHeader().getSpectrum_quantity(), 4)+"\r\n");
|
||||
spectrum.append(phd.getHeader().getSample_ref_id() + "\r\n");
|
||||
spectrum.append(RightFill(phd.getHeader().getMeasurement_id(), 31)+" "+RightFill(phd.getHeader().getDetector_bk_measurement_id(), 31)+" "+phd.getHeader().getGas_bk_measurement_id()+"\r\n");
|
||||
spectrum.append(phd.getHeader().getTransmit_date()+" "+phd.getHeader().getTransmit_time()+"\r\n");
|
||||
spectrum.append(RightFill(phd.getHeader().getMeasurement_id(), 31)+StringPool.SPACE+RightFill(phd.getHeader().getDetector_bk_measurement_id(), 31)+StringPool.SPACE+phd.getHeader().getGas_bk_measurement_id()+"\r\n");
|
||||
spectrum.append(phd.getHeader().getTransmit_date()+StringPool.SPACE+phd.getHeader().getTransmit_time()+"\r\n");
|
||||
|
||||
// #Comment
|
||||
if(StringUtils.isNotBlank(phd.getOriTotalCmt())) {
|
||||
|
@ -3493,21 +3497,21 @@ public class GammaFileUtil {
|
|||
|
||||
// #Collection
|
||||
spectrum.append("#Collection\r\n");
|
||||
spectrum.append(phd.getCollect().getCollection_start_date()+" "+phd.getCollect().getCollection_start_time()+
|
||||
" "+phd.getCollect().getCollection_stop_date()+" "+phd.getCollect().getCollection_stop_time()+" "+phd.getCollect().getAir_volume()+"\r\n");
|
||||
spectrum.append(phd.getCollect().getCollection_start_date()+StringPool.SPACE+phd.getCollect().getCollection_start_time()+
|
||||
StringPool.SPACE+phd.getCollect().getCollection_stop_date()+StringPool.SPACE+phd.getCollect().getCollection_stop_time()+StringPool.SPACE+phd.getCollect().getAir_volume()+"\r\n");
|
||||
|
||||
// #Acquisition
|
||||
spectrum.append("#Acquisition\r\n");
|
||||
spectrum.append(phd.getAcq().getAcquisition_start_date()+" "+phd.getAcq().getAcquisition_start_time()+
|
||||
" "+RightFill(String.format("%.2f", phd.getAcq().getAcquisition_real_time()), 14)+
|
||||
" "+RightFill(String.format("%.2f", phd.getAcq().getAcquisition_live_time()), 14)+"\r\n");
|
||||
spectrum.append(phd.getAcq().getAcquisition_start_date()+StringPool.SPACE+phd.getAcq().getAcquisition_start_time()+
|
||||
StringPool.SPACE+RightFill(String.format("%.2f", phd.getAcq().getAcquisition_real_time()), 14)+
|
||||
StringPool.SPACE+RightFill(String.format("%.2f", phd.getAcq().getAcquisition_live_time()), 14)+"\r\n");
|
||||
|
||||
// #Processing
|
||||
if(phd.getProcess().getSample_volume_of_Xe() > 0) {
|
||||
spectrum.append("#Processing\r\n");
|
||||
spectrum.append(RightFill(String.valueOf(phd.getProcess().getSample_volume_of_Xe()), 8)+" "+RightFill(String.valueOf(phd.getProcess().getUncertainty_1()), 8)+"\r\n"+
|
||||
" "+RightFill(String.valueOf(phd.getProcess().getXe_collection_yield()), 8)+" "+RightFill(String.valueOf(phd.getProcess().getUncertainty_2()), 8)+"\r\n"+
|
||||
" "+phd.getProcess().getArchive_bottle_id()+"\r\n");
|
||||
spectrum.append(RightFill(String.valueOf(phd.getProcess().getSample_volume_of_Xe()), 8)+StringPool.SPACE+RightFill(String.valueOf(phd.getProcess().getUncertainty_1()), 8)+"\r\n"+
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getProcess().getXe_collection_yield()), 8)+StringPool.SPACE+RightFill(String.valueOf(phd.getProcess().getUncertainty_2()), 8)+"\r\n"+
|
||||
StringPool.SPACE+phd.getProcess().getArchive_bottle_id()+"\r\n");
|
||||
}
|
||||
|
||||
// #Sample
|
||||
|
@ -3525,22 +3529,22 @@ public class GammaFileUtil {
|
|||
int fieldWidth = 12;
|
||||
for(int i=0; i<phd.getCertificate().getG_energy().size(); ++i) {
|
||||
spectrum.append(phd.getCertificate().getNuclide_name().get(i)+
|
||||
" "+phd.getCertificate().getHalf_life_time().get(i)+
|
||||
" "+phd.getCertificate().getTime_unit().get(i)+
|
||||
" "+phd.getCertificate().getActivity_nuclide_time_assay().get(i)+
|
||||
" "+phd.getCertificate().getUncertainty().get(i)+
|
||||
" "+phd.getCertificate().getG_energy().get(i)+
|
||||
" "+phd.getCertificate().getG_intensity().get(i)+
|
||||
" "+phd.getCertificate().getElectron_decay_mode().get(i)+
|
||||
" "+phd.getCertificate().getMaximum_energy().get(i)+
|
||||
" "+phd.getCertificate().getIntensity_b_particle().get(i)+"\r\n");
|
||||
StringPool.SPACE+phd.getCertificate().getHalf_life_time().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getTime_unit().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getActivity_nuclide_time_assay().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getUncertainty().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getG_energy().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getG_intensity().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getElectron_decay_mode().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getMaximum_energy().get(i)+
|
||||
StringPool.SPACE+phd.getCertificate().getIntensity_b_particle().get(i)+"\r\n");
|
||||
}
|
||||
}
|
||||
|
||||
// #Calibration
|
||||
if(StringUtils.isNotBlank(phd.getCalibration().getDate_calibration())) {
|
||||
spectrum.append("#Calibration\r\n");
|
||||
spectrum.append(phd.getCalibration().getDate_calibration()+" "+phd.getCalibration().getTime_calibration()+"\r\n");
|
||||
spectrum.append(phd.getCalibration().getDate_calibration()+StringPool.SPACE+phd.getCalibration().getTime_calibration()+"\r\n");
|
||||
}
|
||||
|
||||
// #g_Energy
|
||||
|
@ -3548,8 +3552,8 @@ public class GammaFileUtil {
|
|||
GEnergyBlock g_ener = phd.getUsedEnerKD();
|
||||
for(int i=0; i<g_ener.getG_energy().size(); ++i) {
|
||||
spectrum.append(RightFill(String.format("%.9f", Double.valueOf(g_ener.getG_energy().get(i))), 16)+
|
||||
" "+RightFill(String.format("%.9f", Double.valueOf(g_ener.getCentroid_channel().get(i))), 16)+
|
||||
" "+RightFill((Objects.isNull(g_ener.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_ener.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
StringPool.SPACE+RightFill(String.format("%.9f", Double.valueOf(g_ener.getCentroid_channel().get(i))), 16)+
|
||||
StringPool.SPACE+RightFill((Objects.isNull(g_ener.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_ener.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
}
|
||||
|
||||
// #g_Resolution
|
||||
|
@ -3557,8 +3561,8 @@ public class GammaFileUtil {
|
|||
GResolutionBlock g_reso = phd.getUsedResoKD();
|
||||
for(int i=0; i<g_reso.getFWHM().size(); ++i) {
|
||||
spectrum.append(RightFill(String.format("%.9f", Double.valueOf(g_reso.getG_energy().get(i))), 16)+
|
||||
" "+RightFill(String.format("%.9f", Double.valueOf(g_reso.getFWHM().get(i))), 16)+
|
||||
" "+RightFill((Objects.isNull(g_reso.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_reso.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
StringPool.SPACE+RightFill(String.format("%.9f", Double.valueOf(g_reso.getFWHM().get(i))), 16)+
|
||||
StringPool.SPACE+RightFill((Objects.isNull(g_reso.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_reso.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
}
|
||||
|
||||
// #g_Efficiency
|
||||
|
@ -3566,8 +3570,8 @@ public class GammaFileUtil {
|
|||
GEfficiencyBlock g_effi = phd.getUsedEffiKD();
|
||||
for(int i=0; i<g_effi.getEfficiency().size(); ++i) {
|
||||
spectrum.append(RightFill(String.format("%.9f", Double.valueOf(g_effi.getG_energy().get(i))), 16)+
|
||||
" "+RightFill(String.format("%.9f", Double.valueOf(g_effi.getEfficiency().get(i))), 16)+
|
||||
" "+RightFill((Objects.isNull(g_effi.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_effi.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
StringPool.SPACE+RightFill(String.format("%.9f", Double.valueOf(g_effi.getEfficiency().get(i))), 16)+
|
||||
StringPool.SPACE+RightFill((Objects.isNull(g_effi.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_effi.getUncertainty().get(i)))), 16)+"\r\n");
|
||||
}
|
||||
|
||||
// #TotalEff
|
||||
|
@ -3576,29 +3580,29 @@ public class GammaFileUtil {
|
|||
TotaleffBlock g_totE = phd.getUsedTotEKD();
|
||||
for(int i=0; i<g_totE.getRecord_count(); ++i) {
|
||||
spectrum.append(RightFill(String.format("%.9f", Double.valueOf(g_totE.getG_energy().get(i))), 16)+
|
||||
" "+RightFill(String.format("%.9f", Double.valueOf(g_totE.getTotal_efficiency().get(i))), 16)+
|
||||
" "+RightFill((Objects.isNull(g_totE.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_totE.getUncertainty().get(i)))), 16));
|
||||
StringPool.SPACE+RightFill(String.format("%.9f", Double.valueOf(g_totE.getTotal_efficiency().get(i))), 16)+
|
||||
StringPool.SPACE+RightFill((Objects.isNull(g_totE.getUncertainty().get(i)) ? "0.5" : String.format("%.9f", Double.valueOf(g_totE.getUncertainty().get(i)))), 16));
|
||||
}
|
||||
}
|
||||
|
||||
// #g_Spectrum
|
||||
spectrum.append("#g_Spectrum\r\n");
|
||||
spectrum.append(RightFill(String.valueOf(phd.getSpec().getNum_g_channel()), 5)+" "+RightFill(String.valueOf(phd.getSpec().getG_energy_span()), 4)+"\r\n");
|
||||
spectrum.append(RightFill(String.valueOf(phd.getSpec().getNum_g_channel()), 5)+StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getG_energy_span()), 4)+"\r\n");
|
||||
int i=0;
|
||||
long j= phd.getSpec().getBegin_channel();
|
||||
int len = phd.getSpec().getCounts().size();
|
||||
for(; i<len-4; i+=5,j+=5) {
|
||||
spectrum.append(RightFill(String.valueOf(j), 5)+
|
||||
" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10)+
|
||||
" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+1)), 10)+
|
||||
" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+2)), 10)+
|
||||
" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+3)), 10)+
|
||||
" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+4)), 10)+"\r\n");
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10)+
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+1)), 10)+
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+2)), 10)+
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+3)), 10)+
|
||||
StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i+4)), 10)+"\r\n");
|
||||
}
|
||||
if(i < len) {
|
||||
spectrum.append(RightFill(String.valueOf(j), 5)+" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10));
|
||||
spectrum.append(RightFill(String.valueOf(j), 5)+StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10));
|
||||
for(i = i+1; i < phd.getSpec().getNum_g_channel(); ++i) {
|
||||
spectrum.append(" "+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10));
|
||||
spectrum.append(StringPool.SPACE+RightFill(String.valueOf(phd.getSpec().getCounts().get(i)), 10));
|
||||
}
|
||||
spectrum.append("\r\n");
|
||||
}
|
||||
|
|
|
@ -88,7 +88,11 @@ public class NameStandUtil {
|
|||
String rData = "";
|
||||
BigDecimal bd = new BigDecimal(LT);
|
||||
if(dataType.contains(DataType.SAMPLEPHD.getType())) {
|
||||
bd = bd.setScale(1, RoundingMode.HALF_UP);
|
||||
if (LT.indexOf(".0") > 0) {
|
||||
bd = bd.setScale(0, RoundingMode.HALF_UP);
|
||||
} else {
|
||||
bd = bd.setScale(1, RoundingMode.HALF_UP);
|
||||
}
|
||||
rData = "_S_"+Fulltype+"_"+bd+".PHD";
|
||||
} else if(dataType.contains(DataType.GASBKPHD.getType())){
|
||||
bd = bd.setScale(1, RoundingMode.HALF_UP);
|
||||
|
|
|
@ -8,10 +8,16 @@ import org.apache.commons.net.ftp.FTP;
|
|||
import org.apache.commons.net.ftp.FTPClient;
|
||||
import org.apache.commons.net.ftp.FTPFile;
|
||||
import org.jeecg.common.properties.SpectrumPathProperties;
|
||||
import org.jeecg.modules.base.enums.DataType;
|
||||
import org.jeecg.modules.base.enums.DataTypeAbbr;
|
||||
import org.jeecg.modules.base.enums.XeNuclideName;
|
||||
import org.jeecg.modules.entity.GardsCalibrationSpectrum;
|
||||
import org.jeecg.modules.entity.GardsROIChannelsSpectrum;
|
||||
import org.jeecg.modules.entity.GardsROIResultsSpectrum;
|
||||
import org.jeecg.modules.entity.GardsXeResultsSpectrum;
|
||||
import org.jeecg.modules.entity.vo.*;
|
||||
import org.jeecg.modules.native_jni.EnergySpectrumHandler;
|
||||
import org.jeecg.modules.native_jni.struct.BgAnalyseResult;
|
||||
import org.jeecg.modules.native_jni.struct.BgBoundary;
|
||||
import org.jeecg.modules.native_jni.struct.CalcBgBoundaryParam;
|
||||
import org.jeecg.modules.native_jni.struct.EnergySpectrumStruct;
|
||||
|
@ -507,7 +513,6 @@ public class PHDFileUtil {
|
|||
String measurementName = nameStandUtil.GetFileNameFromDateTime(measurementId, fileSuffix);
|
||||
String gasFileName = nameStandUtil.GetFileNameFromDateTime(gasBkMeasurementId, "_G.PHD");
|
||||
String detaFileName = nameStandUtil.GetFileNameFromDateTime(detectorBkMeasurementId, "_D.PHD");
|
||||
map.put("measurementName", measurementName);
|
||||
map.put("gasFileName", gasFileName);
|
||||
map.put("detaFileName", detaFileName);
|
||||
map.put("sampleSystemType", systemType);
|
||||
|
@ -740,5 +745,239 @@ public class PHDFileUtil {
|
|||
return rData;
|
||||
}
|
||||
|
||||
public File analyzeFile(String path, String fileName) {
|
||||
//连接ftp
|
||||
FTPClient ftpClient = ftpUtil.LoginFTP();
|
||||
InputStream inputStream = null;
|
||||
File file = null;
|
||||
try {
|
||||
//被动模式
|
||||
ftpClient.enterLocalPassiveMode();
|
||||
//设置文件类型--二进制文件
|
||||
ftpClient.setFileType(FTP.BINARY_FILE_TYPE);
|
||||
//
|
||||
ftpClient.setControlEncoding("UTF-8");
|
||||
ftpClient.setFileTransferMode(FTPClient.STREAM_TRANSFER_MODE);
|
||||
//切换文件路径
|
||||
ftpClient.changeWorkingDirectory(path);
|
||||
//获取路径下所有文件信息
|
||||
List<FTPFile> ftpFiles = Arrays.asList(ftpClient.listFiles());
|
||||
if (CollectionUtils.isNotEmpty(ftpFiles)){
|
||||
//根据文件名称 分别获取 sample gas det文件
|
||||
List<FTPFile> files = ftpFiles.stream().filter(item -> item.getName().equals(fileName)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(files)){
|
||||
FTPFile ftpFile = files.get(0);
|
||||
inputStream = ftpClient.retrieveFileStream(ftpFile.getName());
|
||||
file = File.createTempFile("tmp", null);
|
||||
//将ftp文件的输入流复制给临时文件
|
||||
FileUtils.copyInputStreamToFile(inputStream, file);
|
||||
}
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
} finally {
|
||||
try {
|
||||
if (Objects.nonNull(ftpClient)){
|
||||
ftpClient.disconnect();
|
||||
}
|
||||
if (Objects.nonNull(inputStream)){
|
||||
inputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
return file;
|
||||
}
|
||||
|
||||
public BgDataAnlyseResultIn analyzeSpectrum(File sampleTmp, File gasTmp, File detTmp, Map<String, Object> map) {
|
||||
//加载dll工具库
|
||||
System.loadLibrary("ReadPHDFile");
|
||||
//调用动态库解析文件
|
||||
BgAnalyseResult bgAnalyseResult = EnergySpectrumHandler.bgAnalyse(sampleTmp.getAbsolutePath(), gasTmp.getAbsolutePath(), detTmp.getAbsolutePath());
|
||||
BgDataAnlyseResultIn resultIn = new BgDataAnlyseResultIn();
|
||||
resultIn.setXe131m_con(bgAnalyseResult.Xe131m_con);
|
||||
resultIn.setXe131m_uncer(bgAnalyseResult.Xe131m_uncer);
|
||||
resultIn.setMDC_Xe131m(bgAnalyseResult.MDC_Xe131m);
|
||||
resultIn.setLC_Xe131m(bgAnalyseResult.LC_Xe131m);
|
||||
resultIn.setXe131mFlag(bgAnalyseResult.XE_131m_NID_FLAG);
|
||||
resultIn.setXe133_con(bgAnalyseResult.Xe133_con);
|
||||
resultIn.setXe133_uncer(bgAnalyseResult.Xe133_uncer);
|
||||
resultIn.setMDC_Xe133(bgAnalyseResult.MDC_Xe133);
|
||||
resultIn.setLC_Xe133(bgAnalyseResult.LC_Xe133);
|
||||
resultIn.setXe133Flag(bgAnalyseResult.XE_133_NID_FLAG);
|
||||
resultIn.setXe133m_con(bgAnalyseResult.Xe133m_con);
|
||||
resultIn.setXe133m_uncer(bgAnalyseResult.Xe133m_uncer);
|
||||
resultIn.setMDC_Xe133m(bgAnalyseResult.MDC_Xe133m);
|
||||
resultIn.setLC_Xe133m(bgAnalyseResult.LC_Xe133m);
|
||||
resultIn.setXe133mFlag(bgAnalyseResult.XE_133m_NID_FLAG);
|
||||
resultIn.setXe135_con(bgAnalyseResult.Xe135_con);
|
||||
resultIn.setXe135_uncer(bgAnalyseResult.Xe135_uncer);
|
||||
resultIn.setMDC_Xe135(bgAnalyseResult.MDC_Xe135);
|
||||
resultIn.setLC_Xe135(bgAnalyseResult.LC_Xe135);
|
||||
resultIn.setXe135Flag(bgAnalyseResult.XE_135_NID_FLAG);
|
||||
|
||||
List<GardsCalibrationSpectrum> gammaCalibrationSpectrumList = new LinkedList<>();
|
||||
GardsCalibrationSpectrum gammaCalibrationS = new GardsCalibrationSpectrum();
|
||||
gammaCalibrationS.setDataType(DataTypeAbbr.SAMPLEPHD.getType());
|
||||
gammaCalibrationS.setCoeff1(bgAnalyseResult.s_g_fitting_e_c.get(0));
|
||||
gammaCalibrationS.setCoeff2(bgAnalyseResult.s_g_fitting_e_c.get(1));
|
||||
gammaCalibrationS.setCoeff3(bgAnalyseResult.s_g_fitting_e_c.get(2));
|
||||
gammaCalibrationSpectrumList.add(gammaCalibrationS);
|
||||
GardsCalibrationSpectrum gammaCalibrationG = new GardsCalibrationSpectrum();
|
||||
gammaCalibrationG.setDataType(DataTypeAbbr.GASBKPHD.getType());
|
||||
gammaCalibrationG.setCoeff1(bgAnalyseResult.g_g_fitting_e_c.get(0));
|
||||
gammaCalibrationG.setCoeff2(bgAnalyseResult.g_g_fitting_e_c.get(1));
|
||||
gammaCalibrationG.setCoeff3(bgAnalyseResult.g_g_fitting_e_c.get(2));
|
||||
gammaCalibrationSpectrumList.add(gammaCalibrationG);
|
||||
GardsCalibrationSpectrum gammaCalibrationD = new GardsCalibrationSpectrum();
|
||||
gammaCalibrationD.setDataType(DataTypeAbbr.DETBKPHD.getType());
|
||||
gammaCalibrationD.setCoeff1(bgAnalyseResult.d_g_fitting_e_c.get(0));
|
||||
gammaCalibrationD.setCoeff2(bgAnalyseResult.d_g_fitting_e_c.get(1));
|
||||
gammaCalibrationD.setCoeff3(bgAnalyseResult.d_g_fitting_e_c.get(2));
|
||||
gammaCalibrationSpectrumList.add(gammaCalibrationD);
|
||||
List<GardsCalibrationSpectrum> betaCalibrationSpectrumList = new LinkedList<>();
|
||||
// GardsCalibrationSpectrum betaCalibrationS = new GardsCalibrationSpectrum();
|
||||
// betaCalibrationS.setDataType(DataTypeAbbr.SAMPLEPHD.getType());
|
||||
// betaCalibrationS.setCoeff1(bgAnalyseResult.s_b_fitting_c_e.get(0));
|
||||
// betaCalibrationS.setCoeff2(bgAnalyseResult.s_b_fitting_c_e.get(1));
|
||||
// betaCalibrationS.setCoeff3(bgAnalyseResult.s_b_fitting_c_e.get(2));
|
||||
// betaCalibrationSpectrumList.add(betaCalibrationS);
|
||||
// GardsCalibrationSpectrum betaCalibrationG = new GardsCalibrationSpectrum();
|
||||
// betaCalibrationG.setDataType(DataTypeAbbr.GASBKPHD.getType());
|
||||
// betaCalibrationG.setCoeff1(bgAnalyseResult.g_b_fitting_c_e.get(0));
|
||||
// betaCalibrationG.setCoeff2(bgAnalyseResult.g_b_fitting_c_e.get(1));
|
||||
// betaCalibrationG.setCoeff3(bgAnalyseResult.g_b_fitting_c_e.get(2));
|
||||
// betaCalibrationSpectrumList.add(betaCalibrationG);
|
||||
// GardsCalibrationSpectrum betaCalibrationD = new GardsCalibrationSpectrum();
|
||||
// betaCalibrationD.setDataType(DataTypeAbbr.DETBKPHD.getType());
|
||||
// betaCalibrationD.setCoeff1(bgAnalyseResult.d_b_fitting_c_e.get(0));
|
||||
// betaCalibrationD.setCoeff2(bgAnalyseResult.d_b_fitting_c_e.get(1));
|
||||
// betaCalibrationD.setCoeff3(bgAnalyseResult.d_b_fitting_c_e.get(2));
|
||||
// betaCalibrationSpectrumList.add(betaCalibrationD);
|
||||
List<GardsROIChannelsSpectrum> roiChannelsSpectrumList = new LinkedList<>();
|
||||
for (int i=0; i<bgAnalyseResult.S_ROI_B_Boundary_start.size(); i++) {
|
||||
GardsROIChannelsSpectrum roiChannels = new GardsROIChannelsSpectrum();
|
||||
roiChannels.setRoi(i+1);
|
||||
roiChannels.setBChanStart(bgAnalyseResult.S_ROI_B_Boundary_start.get(i));
|
||||
roiChannels.setBChanStop(bgAnalyseResult.S_ROI_B_Boundary_stop.get(i));
|
||||
roiChannels.setGChanStart(bgAnalyseResult.S_ROI_G_Boundary_start.get(i));
|
||||
roiChannels.setGChanStop(bgAnalyseResult.S_ROI_G_Boundary_stop.get(i));
|
||||
roiChannelsSpectrumList.add(roiChannels);
|
||||
}
|
||||
List<GardsROIResultsSpectrum> roiResultsSpectrumList = new LinkedList<>();
|
||||
for (int i=0; i<bgAnalyseResult.s_roi_cts.size(); i++) {
|
||||
GardsROIResultsSpectrum roiResults = new GardsROIResultsSpectrum();
|
||||
roiResults.setRoi(i+1);
|
||||
if (i==0) {
|
||||
roiResults.setLc(0.0);
|
||||
} else {
|
||||
roiResults.setLc(bgAnalyseResult.LC.get(i-1));
|
||||
}
|
||||
roiResults.setSGross(bgAnalyseResult.s_roi_cts.get(i));
|
||||
roiResults.setGGross(bgAnalyseResult.g_roi_cts.get(i));
|
||||
roiResults.setBGross(bgAnalyseResult.d_roi_cts.get(i));
|
||||
roiResults.setSNet(bgAnalyseResult.s_deduct_d_cts.get((i+1)*3));
|
||||
roiResults.setGNet(bgAnalyseResult.g_deduct_d_cts.get((i+1)*3));
|
||||
roiResults.setNet(bgAnalyseResult.ROI_net_coutns.get(i));
|
||||
roiResults.setNetErr(bgAnalyseResult.ROI_net_coutns_err.get(i));
|
||||
roiResults.setConc(bgAnalyseResult.ROI_con_uncer.get(i));
|
||||
roiResults.setConcErr(bgAnalyseResult.ROI_con_uncer_err.get(i));
|
||||
// roiResults.setMdc(bgAnalyseResult.MDC.get(i));
|
||||
// if(bgAnalyseResult.ROI_con_uncer.get(i)>bgAnalyseResult.MDC.get(i)) {
|
||||
// roiResults.setNidFlag(1);
|
||||
// } else {
|
||||
// roiResults.setNidFlag(0);
|
||||
// }
|
||||
roiResultsSpectrumList.add(roiResults);
|
||||
}
|
||||
map.put("gammaCalibrationSpectrumList", gammaCalibrationSpectrumList);
|
||||
map.put("betaCalibrationSpectrumList", betaCalibrationSpectrumList);
|
||||
map.put("roiChannelsSpectrumList", roiChannelsSpectrumList);
|
||||
map.put("roiResultsSpectrumList", roiResultsSpectrumList);
|
||||
map.put("bProcessed", true);
|
||||
return resultIn;
|
||||
}
|
||||
|
||||
public EnergySpectrumStruct analyzeFileSourceData(String filePath, String fileName) {
|
||||
//加载dll工具库
|
||||
System.loadLibrary("ReadPHDFile");
|
||||
EnergySpectrumStruct struct = new EnergySpectrumStruct();
|
||||
FTPClient ftpClient = ftpUtil.LoginFTP();
|
||||
InputStream inputStream = null;
|
||||
try {
|
||||
//切换被动模式
|
||||
ftpClient.enterLocalPassiveMode();
|
||||
ftpClient.setFileType(FTPClient.BINARY_FILE_TYPE);
|
||||
// 设置编码,当文件中存在中文且上传后文件乱码时可使用此配置项
|
||||
ftpClient.setControlEncoding("UTF-8");
|
||||
ftpClient.setFileTransferMode(FTPClient.STREAM_TRANSFER_MODE);
|
||||
ftpClient.changeWorkingDirectory(filePath);
|
||||
List<FTPFile> ftpFiles = Arrays.asList(ftpClient.listFiles());
|
||||
ftpFiles = ftpFiles.stream().filter(item -> item.getName().equals(fileName)).collect(Collectors.toList());
|
||||
if (CollectionUtils.isNotEmpty(ftpFiles)){
|
||||
FTPFile ftpFile = ftpFiles.get(0);
|
||||
if (Objects.nonNull(ftpFile)){
|
||||
inputStream = ftpClient.retrieveFileStream(ftpFile.getName());
|
||||
//声明一个临时文件
|
||||
File file = File.createTempFile("tmp", null);
|
||||
//将ftp文件的输入流复制给临时文件
|
||||
FileUtils.copyInputStreamToFile(inputStream, file);
|
||||
struct = EnergySpectrumHandler.getSourceData(file.getAbsolutePath());
|
||||
}
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
} finally {
|
||||
try {
|
||||
if (Objects.nonNull(ftpClient)){
|
||||
ftpClient.disconnect();
|
||||
}
|
||||
if (Objects.nonNull(inputStream)){
|
||||
inputStream.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
return struct;
|
||||
}
|
||||
|
||||
public List<GardsXeResultsSpectrum> analyzeQCResultXe(File sampleTmp, File gasTmp, File detTmp){
|
||||
//加载dll工具库
|
||||
System.loadLibrary("ReadPHDFile");
|
||||
//调用动态库解析文件
|
||||
BgAnalyseResult bgAnalyseResult = EnergySpectrumHandler.bgAnalyse(sampleTmp.getAbsolutePath(), gasTmp.getAbsolutePath(), detTmp.getAbsolutePath());
|
||||
List<GardsXeResultsSpectrum> xeResultsSpectrumList = new LinkedList<>();
|
||||
GardsXeResultsSpectrum Xe131m = new GardsXeResultsSpectrum();
|
||||
Xe131m.setNuclideName(XeNuclideName.XE_131m.getType());
|
||||
Xe131m.setMdc(bgAnalyseResult.MDC_Xe131m);
|
||||
Xe131m.setConc(bgAnalyseResult.Xe131m_con);
|
||||
Xe131m.setConcErr(bgAnalyseResult.Xe131m_uncer);
|
||||
Xe131m.setLc(bgAnalyseResult.LC_Xe131m);
|
||||
xeResultsSpectrumList.add(Xe131m);
|
||||
GardsXeResultsSpectrum Xe133 = new GardsXeResultsSpectrum();
|
||||
Xe133.setNuclideName(XeNuclideName.XE_133.getType());
|
||||
Xe133.setMdc(bgAnalyseResult.MDC_Xe133);
|
||||
Xe133.setConc(bgAnalyseResult.Xe133_con);
|
||||
Xe133.setConcErr(bgAnalyseResult.Xe133_uncer);
|
||||
Xe133.setLc(bgAnalyseResult.LC_Xe133);
|
||||
xeResultsSpectrumList.add(Xe133);
|
||||
GardsXeResultsSpectrum Xe133m = new GardsXeResultsSpectrum();
|
||||
Xe133m.setNuclideName(XeNuclideName.XE_133m.getType());
|
||||
Xe133m.setMdc(bgAnalyseResult.MDC_Xe133m);
|
||||
Xe133m.setConc(bgAnalyseResult.Xe133m_con);
|
||||
Xe133m.setConcErr(bgAnalyseResult.Xe133m_uncer);
|
||||
Xe133m.setLc(bgAnalyseResult.LC_Xe133m);
|
||||
xeResultsSpectrumList.add(Xe133m);
|
||||
GardsXeResultsSpectrum Xe135 = new GardsXeResultsSpectrum();
|
||||
Xe135.setNuclideName(XeNuclideName.XE_135.getType());
|
||||
Xe135.setMdc(bgAnalyseResult.MDC_Xe135);
|
||||
Xe135.setConc(bgAnalyseResult.Xe135_con);
|
||||
Xe135.setConcErr(bgAnalyseResult.Xe135_uncer);
|
||||
Xe135.setLc(bgAnalyseResult.LC_Xe135);
|
||||
xeResultsSpectrumList.add(Xe135);
|
||||
return xeResultsSpectrumList;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@ public class UserTaskUtil {
|
|||
* 根据用户名称查询当前用户是否有权限操作当前台站的信息
|
||||
* @return
|
||||
*/
|
||||
public boolean checkUserStation(Integer stationId, String userName){
|
||||
public boolean checkUserStation(Integer stationId, String userName) {
|
||||
boolean flag = false;
|
||||
//根据用户名称查询用户id
|
||||
SysUser user = userTaskService.findUserByName(userName);
|
||||
|
|
|
@ -42,6 +42,12 @@ public class GammaController {
|
|||
@Autowired
|
||||
private IGammaService gammaService;
|
||||
|
||||
@GetMapping("initValue")
|
||||
@ApiOperation(value = "初始化gamma数据", notes = "初始化gamma数据")
|
||||
public Result initValue(Integer sampleId, String dbName) {
|
||||
return gammaService.initValue(sampleId, dbName);
|
||||
}
|
||||
|
||||
@GetMapping("gammaByDB")
|
||||
public Result gammaByDB(@RequestParam Integer sampleId, @RequestParam String dbName){
|
||||
return gammaService.gammaByDB(dbName, sampleId);
|
||||
|
@ -119,10 +125,10 @@ public class GammaController {
|
|||
return gammaService.addPeakComment(commentsInfo.getFileName(), commentsInfo.getCurRow(), commentsInfo.getComments());
|
||||
}
|
||||
|
||||
@GetMapping("viewGenralComment")
|
||||
@GetMapping("viewGeneralComment")
|
||||
@ApiOperation(value = "InteractiveTool页面查看备注信息接口", notes = "InteractiveTool页面查看备注信息接口")
|
||||
public Result viewGenralComment(String fileName) {
|
||||
return gammaService.viewGenralComment(fileName);
|
||||
public Result viewGeneralComment(String fileName) {
|
||||
return gammaService.viewGeneralComment(fileName);
|
||||
}
|
||||
|
||||
@PostMapping("addGeneralComment")
|
||||
|
@ -179,8 +185,8 @@ public class GammaController {
|
|||
|
||||
@GetMapping("energyCalibration")
|
||||
@ApiOperation(value = "查看Energy Calibration数据", notes = "查看Energy Calibration数据")
|
||||
public Result energyCalibration(@RequestParam Integer sampleId, String fileName) {
|
||||
return gammaService.energyCalibration(sampleId, fileName);
|
||||
public Result energyCalibration(@RequestParam Integer sampleId, String fileName, String currentText) {
|
||||
return gammaService.energyCalibration(sampleId, fileName, currentText);
|
||||
}
|
||||
|
||||
@PostMapping("changeDataEnergy")
|
||||
|
@ -197,8 +203,8 @@ public class GammaController {
|
|||
|
||||
@GetMapping("resolutionCalibration")
|
||||
@ApiOperation(value = "查看Resolution Calibration数据", notes = "查看Resolution Calibration数据")
|
||||
public Result resolutionCalibration(@RequestParam Integer sampleId, String fileName) {
|
||||
return gammaService.resolutionCalibration(sampleId, fileName);
|
||||
public Result resolutionCalibration(@RequestParam Integer sampleId, String fileName, String currentText) {
|
||||
return gammaService.resolutionCalibration(sampleId, fileName, currentText);
|
||||
}
|
||||
|
||||
@PostMapping("changeDataResolution")
|
||||
|
@ -215,8 +221,8 @@ public class GammaController {
|
|||
|
||||
@GetMapping("EfficiencyCalibration")
|
||||
@ApiOperation(value = "查看Efficiency Calibration数据", notes = "查看Efficiency Calibration数据")
|
||||
public Result EfficiencyCalibration(@RequestParam Integer sampleId, String fileName) {
|
||||
return gammaService.EfficiencyCalibration(sampleId, fileName);
|
||||
public Result EfficiencyCalibration(@RequestParam Integer sampleId, String fileName, String currentText) {
|
||||
return gammaService.EfficiencyCalibration(sampleId, fileName, currentText);
|
||||
}
|
||||
|
||||
@PostMapping("changeDataEfficiency")
|
||||
|
|
|
@ -76,8 +76,8 @@ public class SpectrumAnalysesController {
|
|||
|
||||
@GetMapping("viewComment")
|
||||
@ApiOperation(value = "查看comment数据", notes = "查看comment数据")
|
||||
public Result viewComment(Integer sampleId, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewComment(sampleId, request);
|
||||
public Result viewComment(Integer sampleId, String sampleFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewComment(sampleId, sampleFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewARR")
|
||||
|
@ -86,46 +86,46 @@ public class SpectrumAnalysesController {
|
|||
spectrumAnalysisService.viewARR(sampleId, response);
|
||||
}
|
||||
|
||||
@GetMapping("viewRRR")
|
||||
@PostMapping("viewRRR")
|
||||
@ApiOperation(value = "查看RRR报告", notes = "查看RRR报告")
|
||||
public Result viewRRR(String dbName, Integer sampleId, boolean sampleData, boolean GasBgData, boolean DetBgData, boolean QCData, boolean bGammaEnergyValid, boolean bBetaEnergyValid) {
|
||||
return spectrumAnalysisService.viewRRR(dbName, sampleId, sampleData, GasBgData, DetBgData, QCData, bGammaEnergyValid, bBetaEnergyValid);
|
||||
public Result viewRRR(@RequestBody RRRLogInfo rrrLogInfo, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewRRR(rrrLogInfo, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewSpectrum")
|
||||
@ApiOperation(value = "查看Spectrum数据", notes = "查看Spectrum数据")
|
||||
public Result viewSpectrum(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewSpectrum(sampleId);
|
||||
public Result viewSpectrum(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, String qcFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewSpectrum(sampleId, dbName, sampleFileName, gasFileName, detFileName, qcFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewSampleInformation")
|
||||
@ApiOperation(value = "查看SampleInformation数据", notes = "查看SampleInformation数据")
|
||||
public Result<?> viewSampleInformation(Integer sampleId){
|
||||
return spectrumAnalysisService.viewSampleInformation(sampleId);
|
||||
public Result viewSampleInformation(Integer sampleId, String sampleFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewSampleInformation(sampleId, sampleFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("exportSampleInformation")
|
||||
@ApiOperation(value = "导出SampleInformation数据", notes = "导出SampleInformation数据")
|
||||
public void exportSampleInformation(Integer sampleId, HttpServletResponse response){
|
||||
spectrumAnalysisService.exportSampleInformation(sampleId,response);
|
||||
public void exportSampleInformation(Integer sampleId, String sampleFileName, HttpServletRequest request, HttpServletResponse response){
|
||||
spectrumAnalysisService.exportSampleInformation(sampleId, sampleFileName, request,response);
|
||||
}
|
||||
|
||||
@GetMapping("viewQCResult")
|
||||
@ApiOperation(value = "查看QC Result数据", notes = "查看QC Result数据")
|
||||
public Result<?> viewQCResult(Integer sampleId){
|
||||
return spectrumAnalysisService.viewQCResult(sampleId);
|
||||
public Result viewQCResult(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewQCResult(sampleId, dbName, sampleFileName, gasFileName ,detFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("exportQCResult")
|
||||
@ApiOperation(value = "导出QC Result数据", notes = "导出QC Result数据")
|
||||
public void exportQCResult(Integer sampleId,HttpServletResponse response){
|
||||
spectrumAnalysisService.exportQCResult(sampleId,response);
|
||||
public void exportQCResult(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request, HttpServletResponse response){
|
||||
spectrumAnalysisService.exportQCResult(sampleId, dbName, sampleFileName, gasFileName ,detFileName, request,response);
|
||||
}
|
||||
|
||||
@GetMapping("viewRLR")
|
||||
@ApiOperation(value = "查看RLR数据", notes = "查看RLR数据")
|
||||
public Result viewRLR(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewRLR(sampleId);
|
||||
public Result viewRLR(Integer sampleId, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewRLR(sampleId, sampleFileName, gasFileName, detFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("exportRLR")
|
||||
|
@ -136,26 +136,26 @@ public class SpectrumAnalysesController {
|
|||
|
||||
@GetMapping("viewGammaDetectorCalibration")
|
||||
@ApiOperation(value = "查询GammaDetectorCalibration数据", notes = "查询GammaDetectorCalibration数据")
|
||||
public Result viewGammaDetectorCalibration(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewGammaDetectorCalibration(sampleId);
|
||||
public Result viewGammaDetectorCalibration(Integer sampleId, String qcFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewGammaDetectorCalibration(sampleId, qcFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewBetaDetectorCalibration")
|
||||
@ApiOperation(value = "查询BetaDetectorCalibration数据", notes = "查询BetaDetectorCalibration数据")
|
||||
public Result viewBetaDetectorCalibration(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewBetaDetectorCalibration(sampleId);
|
||||
public Result viewBetaDetectorCalibration(Integer sampleId, String qcFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewBetaDetectorCalibration(sampleId, qcFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewExtrapolation")
|
||||
@ApiOperation(value = "查询Extrapolation数据", notes = "查询Extrapolation数据")
|
||||
public Result viewExtrapolation(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewExtrapolation(sampleId);
|
||||
public Result viewExtrapolation(Integer sampleId, String sampleFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewExtrapolation(sampleId, sampleFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("viewMDC")
|
||||
@ApiOperation(value = "查看MDC数据", notes = "查看MDC数据")
|
||||
public Result viewMDC(Integer sampleId) {
|
||||
return spectrumAnalysisService.viewMDC(sampleId);
|
||||
public Result viewMDC(Integer sampleId, String sampleFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.viewMDC(sampleId, sampleFileName, request);
|
||||
}
|
||||
|
||||
@GetMapping("changeDetector")
|
||||
|
@ -172,8 +172,8 @@ public class SpectrumAnalysesController {
|
|||
|
||||
@GetMapping("statisticsQueryBtn")
|
||||
@ApiOperation(value = "报警按钮分析数据", notes = "报警按钮分析数据")
|
||||
public Result statisticsQueryBtn(String detectorName, Integer stationId, String statisticsType, @DateTimeFormat(pattern = "yyyy-MM-dd") Date startTime, @DateTimeFormat(pattern = "yyyy-MM-dd") Date endTime) {
|
||||
return spectrumAnalysisService.statisticsQueryBtn(detectorName, stationId, statisticsType, startTime, endTime);
|
||||
public Result statisticsQueryBtn(Integer detectorId, String detectorName, Integer stationId, String statisticsType, @DateTimeFormat(pattern = "yyyy-MM-dd") Date startTime, @DateTimeFormat(pattern = "yyyy-MM-dd") Date endTime) {
|
||||
return spectrumAnalysisService.statisticsQueryBtn(detectorId, detectorName, stationId, statisticsType, startTime, endTime);
|
||||
}
|
||||
|
||||
@PostMapping("fitting")
|
||||
|
@ -184,8 +184,8 @@ public class SpectrumAnalysesController {
|
|||
|
||||
@GetMapping("getGammaGated")
|
||||
@ApiOperation(value = "获取gamma对应count数据", notes = "获取gamma对应count数据")
|
||||
public Result getGammaGated(Integer chartHeight, Integer channelWidth, Integer gammaChannel, Integer sampleId) {
|
||||
return spectrumAnalysisService.getGammaGated(chartHeight, channelWidth, gammaChannel, sampleId);
|
||||
public Result getGammaGated(Integer chartHeight, Integer channelWidth, Integer gammaChannel, Integer sampleId, String qcFileName, HttpServletRequest request) {
|
||||
return spectrumAnalysisService.getGammaGated(chartHeight, channelWidth, gammaChannel, sampleId, qcFileName, request);
|
||||
}
|
||||
|
||||
@PostMapping("ReAnalyse")
|
||||
|
|
|
@ -58,4 +58,9 @@ public class GardsCalibrationPairsSpectrum implements Serializable {
|
|||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
/**
|
||||
* 数据类型
|
||||
*/
|
||||
private String dataType;
|
||||
|
||||
}
|
||||
|
|
|
@ -104,4 +104,9 @@ public class GardsCalibrationSpectrum implements Serializable {
|
|||
|
||||
private String coeffString;
|
||||
|
||||
/**
|
||||
* 数据类型
|
||||
*/
|
||||
private String dataType;
|
||||
|
||||
}
|
||||
|
|
|
@ -50,4 +50,6 @@ public class GardsROIChannelsSpectrum implements Serializable {
|
|||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date moddate;
|
||||
|
||||
private String dataType;
|
||||
|
||||
}
|
||||
|
|
|
@ -13,6 +13,11 @@ public class BgDataAnlyseResultIn implements Serializable {
|
|||
*/
|
||||
private String comment;
|
||||
|
||||
/**
|
||||
* 标识本次操作是否进行过解析
|
||||
*/
|
||||
private boolean bProcessed;
|
||||
|
||||
/**
|
||||
* 分析员名称
|
||||
*/
|
||||
|
@ -200,5 +205,24 @@ public class BgDataAnlyseResultIn implements Serializable {
|
|||
|
||||
private int Xe135Flag;
|
||||
|
||||
private List<Double> s_roi_cts;
|
||||
|
||||
private List<Double> LC;
|
||||
|
||||
private List<Double> g_roi_cts;
|
||||
|
||||
private List<Double> d_roi_cts;
|
||||
|
||||
private List<Double> s_deduct_d_cts;
|
||||
|
||||
private List<Double> g_deduct_d_cts;
|
||||
|
||||
private List<Double> ROI_net_coutns;
|
||||
|
||||
private List<Double> ROI_net_err;
|
||||
|
||||
private List<Double> ROI_con_uncer;
|
||||
|
||||
private List<Double> MDC;
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,47 @@
|
|||
package org.jeecg.modules.entity.vo;
|
||||
|
||||
import lombok.Data;
|
||||
import org.jeecg.modules.entity.GardsCalibrationSpectrum;
|
||||
import org.jeecg.modules.entity.GardsROIChannelsSpectrum;
|
||||
import org.jeecg.modules.entity.GardsROIResultsSpectrum;
|
||||
import org.jeecg.modules.entity.GardsXeResultsSpectrum;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class RRRLogInfo implements Serializable {
|
||||
|
||||
private String dbName;
|
||||
|
||||
private Integer sampleId;
|
||||
|
||||
private boolean sampleData;
|
||||
|
||||
private boolean gasBgData;
|
||||
|
||||
private boolean detBgData;
|
||||
|
||||
private boolean qcData;
|
||||
|
||||
private boolean bGammaEnergyValid;
|
||||
|
||||
private boolean bBetaEnergyValid;
|
||||
|
||||
private String sampleFileName;
|
||||
|
||||
private String gasFileName;
|
||||
|
||||
private String detFileName;
|
||||
|
||||
private List<GardsROIChannelsSpectrum> roiChannelsSpectrumList;
|
||||
|
||||
private List<GardsROIResultsSpectrum> roiResultsSpectrumList;
|
||||
|
||||
private List<GardsXeResultsSpectrum> xeResultsSpectrumList;
|
||||
|
||||
private List<GardsCalibrationSpectrum> gammaCalibrationParamList;
|
||||
|
||||
private List<GardsCalibrationSpectrum> betaCalibrationParamList;
|
||||
|
||||
}
|
|
@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
|||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.jeecg.modules.base.entity.configuration.GardsDetectors;
|
||||
import org.jeecg.modules.base.entity.configuration.GardsNuclLib;
|
||||
import org.jeecg.modules.base.entity.configuration.GardsNuclLinesLib;
|
||||
import org.jeecg.modules.base.entity.rnman.GardsAnalySetting;
|
||||
|
@ -39,17 +40,17 @@ public interface SpectrumAnalysisMapper {
|
|||
|
||||
GardsSampleDataSpectrum findSampleByFilePath(@Param(value = "filePath") String filePath);
|
||||
|
||||
List<String> getDetectorList(@Param(value = "stationId") Integer stationId);
|
||||
List<GardsDetectors> getDetectorList(@Param(value = "stationId") Integer stationId);
|
||||
|
||||
List<StatisticsData> statisticsQueryNuclides(@Param(value = "statisticsQueryData") StatisticsQueryData statisticsQueryData);
|
||||
|
||||
List<StatisticsData> statisticsQueryCollection(String startDate, String endDate, List<String> detectorList);
|
||||
List<StatisticsData> statisticsQueryCollection(String startDate, String endDate, List<Integer> detectorList);
|
||||
|
||||
List<StatisticsData> statisticsQueryAcquisition(String startDate, String endDate, List<String> detectorList);
|
||||
List<StatisticsData> statisticsQueryAcquisition(String startDate, String endDate, List<Integer> detectorList);
|
||||
|
||||
List<StatisticsData> statisticsQueryXeVolumn(String startDate, String endDate, List<String> detectorList);
|
||||
List<StatisticsData> statisticsQueryXeVolumn(String startDate, String endDate, List<Integer> detectorList);
|
||||
|
||||
List<StatisticsData> statisticsQuerySampleVolumn(String startDate, String endDate, List<String> detectorList);
|
||||
List<StatisticsData> statisticsQuerySampleVolumn(String startDate, String endDate, List<Integer> detectorList);
|
||||
|
||||
String getStatus(@Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
|
@ -77,9 +78,13 @@ public interface SpectrumAnalysisMapper {
|
|||
|
||||
Integer getAnalysisID(@Param(value = "dbName") String dbName, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
GardsCalibrationSpectrum ReadGammaCalibrationParam(@Param(value = "dbName") String dbName, @Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
List<GardsCalibrationPairsSpectrum> ReadGammaFitChannelEnergy(@Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
GardsCalibrationSpectrum ReadBetaCalibrationParam(@Param(value = "dbName") String dbName, @Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
List<GardsCalibrationSpectrum> ReadGammaCalibrationParam(@Param(value = "dbName") String dbName, @Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
List<GardsCalibrationPairsSpectrum> ReadBetaFitChannelEnergy(@Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
List<GardsCalibrationSpectrum> ReadBetaCalibrationParam(@Param(value = "dbName") String dbName, @Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
List<GardsROIChannelsSpectrum> ReadROIChannels(@Param(value = "dbName") String dbName, @Param(value = "idAnalysis") Integer idAnalysis, @Param(value = "sampleId") Integer sampleId);
|
||||
|
||||
|
@ -139,6 +144,8 @@ public interface SpectrumAnalysisMapper {
|
|||
|
||||
void insertXeResult(List<GardsXeResultsSpectrum> xeResults);
|
||||
|
||||
void deleteROIResults(Integer idAnalysis);
|
||||
|
||||
String getIdAnalysisByIdAnalyst(@Param(value = "sampleId") String sampleId, @Param(value = "userName") String userName);
|
||||
|
||||
void deletePeaks(Integer idAnalysis);
|
||||
|
|
|
@ -120,7 +120,7 @@
|
|||
TRIM(org_sample.SITE_DET_CODE) siteDetCode,
|
||||
org_sample.COLLECT_START collectStart
|
||||
FROM ORIGINAL.GARDS_SAMPLE_DATA org_sample,
|
||||
${dbName} analyses
|
||||
${dbName}.GARDS_ANALYSES analyses
|
||||
<where>
|
||||
analyses.SAMPLE_ID = #{sampleId}
|
||||
AND org_sample.SAMPLE_ID=analyses.SAMPLE_ID
|
||||
|
@ -218,8 +218,8 @@
|
|||
|
||||
</select>
|
||||
|
||||
<select id="getDetectorList" resultType="java.lang.String">
|
||||
SELECT DETECTOR_CODE FROM CONFIGURATION.GARDS_DETECTORS WHERE STATION_ID = #{stationId}
|
||||
<select id="getDetectorList" resultType="org.jeecg.modules.base.entity.configuration.GardsDetectors">
|
||||
SELECT DETECTOR_ID,DETECTOR_CODE FROM CONFIGURATION.GARDS_DETECTORS WHERE STATION_ID = #{stationId}
|
||||
</select>
|
||||
|
||||
<select id="statisticsQueryNuclides" resultType="org.jeecg.modules.entity.vo.StatisticsData">
|
||||
|
@ -261,9 +261,9 @@
|
|||
and gsd.SITE_DET_CODE IN ('')
|
||||
</if>
|
||||
<if test="statisticsQueryData.detectorList.size >0 and statisticsQueryData.detectorList!=null">
|
||||
and gsd.SITE_DET_CODE IN
|
||||
and gsd.DETECTOR_ID IN
|
||||
<foreach collection="statisticsQueryData.detectorList" item="detector" open="(" separator="," close=")">
|
||||
'${detector}'
|
||||
#{detector}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
|
@ -283,9 +283,9 @@
|
|||
and gsd.SITE_DET_CODE IN ('')
|
||||
</if>
|
||||
<if test="detectorList.size >0 and detectorList!=null">
|
||||
and gsd.SITE_DET_CODE IN
|
||||
and gsd.DETECTOR_ID IN
|
||||
<foreach collection="detectorList" item="detector" open="(" close=")" separator=",">
|
||||
'${detector}'
|
||||
#{detector}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
|
@ -306,9 +306,9 @@
|
|||
and gsd.SITE_DET_CODE IN ('')
|
||||
</if>
|
||||
<if test="detectorList.size >0 and detectorList!=null">
|
||||
and gsd.SITE_DET_CODE IN
|
||||
and gsd.DETECTOR_ID IN
|
||||
<foreach collection="detectorList" item="detector" open="(" close=")" separator=",">
|
||||
'${detector}'
|
||||
#{detector}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
|
@ -330,9 +330,9 @@
|
|||
and gsd.SITE_DET_CODE IN ('')
|
||||
</if>
|
||||
<if test="detectorList.size >0 and detectorList!=null">
|
||||
and gsd.SITE_DET_CODE IN
|
||||
and gsd.DETECTOR_ID IN
|
||||
<foreach collection="detectorList" item="detector" open="(" close=")" separator=",">
|
||||
'${detector}'
|
||||
#{detector}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
|
@ -352,9 +352,9 @@
|
|||
and gsd.SITE_DET_CODE IN ('')
|
||||
</if>
|
||||
<if test="detectorList.size >0 and detectorList!=null">
|
||||
and gsd.SITE_DET_CODE IN
|
||||
and gsd.DETECTOR_ID IN
|
||||
<foreach collection="detectorList" item="detector" open="(" close=")" separator=",">
|
||||
'${detector}'
|
||||
#{detector}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
|
@ -495,6 +495,23 @@
|
|||
SELECT ANALYSIS_DB.IDANALYSIS FROM ${dbName}.GARDS_ANALYSES ANALYSIS_DB WHERE ANALYSIS_DB.SAMPLE_ID = #{sampleId}
|
||||
</select>
|
||||
|
||||
<select id="ReadGammaFitChannelEnergy" resultType="org.jeecg.modules.entity.GardsCalibrationPairsSpectrum">
|
||||
SELECT DISTINCT
|
||||
SMAPLE_DATA.DATA_TYPE,
|
||||
CALIBRATION_PAIRS.IDCALPOINT,
|
||||
CALIBRATION_PAIRS.XVALUE,
|
||||
CALIBRATION_PAIRS.YVALUE
|
||||
FROM
|
||||
RNMAN.GARDS_CALIBRATION_PAIRS CALIBRATION_PAIRS,
|
||||
ORIGINAL.GARDS_SAMPLE_DATA SMAPLE_DATA
|
||||
WHERE
|
||||
CALIBRATION_PAIRS.SAMPLE_ID = SMAPLE_DATA.SAMPLE_ID
|
||||
AND CALIBRATION_PAIRS.SAMPLE_TYPE = 'G'
|
||||
AND CALIBRATION_PAIRS.IDANALYSIS = #{idAnalysis}
|
||||
AND CALIBRATION_PAIRS.SAMPLE_ID = #{sampleId}
|
||||
ORDER BY CALIBRATION_PAIRS.IDCALPOINT ASC
|
||||
</select>
|
||||
|
||||
<select id="ReadGammaCalibrationParam" resultType="org.jeecg.modules.entity.GardsCalibrationSpectrum">
|
||||
SELECT
|
||||
SAMPLE_DATA.DATA_TYPE,
|
||||
|
@ -508,7 +525,22 @@
|
|||
SAMPLE_DATA.SAMPLE_ID = CALIBRATION.SAMPLE_ID
|
||||
AND CALIBRATION.SAMPLE_TYPE = 'G'
|
||||
AND CALIBRATION.IDANALYSIS = #{idAnalysis}
|
||||
AND CALIBRATION.SAMPLE_ID = #{sampleId}
|
||||
</select>
|
||||
|
||||
<select id="ReadBetaFitChannelEnergy" resultType="org.jeecg.modules.entity.GardsCalibrationPairsSpectrum">
|
||||
SELECT DISTINCT
|
||||
SMAPLE_DATA.DATA_TYPE,
|
||||
CALIBRATION_PAIRS.IDCALPOINT,
|
||||
CALIBRATION_PAIRS.XVALUE,
|
||||
CALIBRATION_PAIRS.YVALUE
|
||||
FROM
|
||||
RNMAN.GARDS_CALIBRATION_PAIRS CALIBRATION_PAIRS,
|
||||
ORIGINAL.GARDS_SAMPLE_DATA SMAPLE_DATA
|
||||
WHERE
|
||||
CALIBRATION_PAIRS.SAMPLE_ID = SMAPLE_DATA.SAMPLE_ID
|
||||
AND CALIBRATION_PAIRS.SAMPLE_TYPE = 'B'
|
||||
AND CALIBRATION_PAIRS.IDANALYSIS = #{idAnalysis}
|
||||
ORDER BY CALIBRATION_PAIRS.IDCALPOINT ASC
|
||||
</select>
|
||||
|
||||
<select id="ReadBetaCalibrationParam" resultType="org.jeecg.modules.entity.GardsCalibrationSpectrum">
|
||||
|
@ -524,7 +556,6 @@
|
|||
SAMPLE_DATA.SAMPLE_ID = CALIBRATION.SAMPLE_ID
|
||||
AND CALIBRATION.SAMPLE_TYPE = 'B'
|
||||
AND CALIBRATION.IDANALYSIS = #{idAnalysis}
|
||||
AND CALIBRATION.SAMPLE_ID = #{sampleId}
|
||||
</select>
|
||||
|
||||
<select id="ReadROIChannels" resultType="org.jeecg.modules.entity.GardsROIChannelsSpectrum">
|
||||
|
@ -542,7 +573,6 @@
|
|||
WHERE
|
||||
ROI_CHANNELS.SAMPLE_ID = SAMPLE_DATA.SAMPLE_ID
|
||||
AND ROI_CHANNELS.IDANALYSIS = #{idAnalysis}
|
||||
AND ROI_CHANNELS.SAMPLE_ID = #{sampleId}
|
||||
ORDER BY ROI_CHANNELS.ROI ASC
|
||||
</select>
|
||||
|
||||
|
@ -566,7 +596,6 @@
|
|||
${dbName}.GARDS_ROI_RESULTS ROI_RESULTS
|
||||
WHERE
|
||||
ROI_RESULTS.IDANALYSIS = #{idAnalysis}
|
||||
AND ROI_RESULTS.SAMPLE_ID = #{sampleId}
|
||||
ORDER BY ROI_RESULTS.ROI ASC
|
||||
</select>
|
||||
|
||||
|
@ -582,7 +611,6 @@
|
|||
${dbName}.GARDS_XE_RESULTS XE_RESULTS
|
||||
WHERE
|
||||
XE_RESULTS.IDANALYSIS = #{idAnalysis}
|
||||
AND XE_RESULTS.SAMPLE_ID = #{sampleId}
|
||||
</select>
|
||||
|
||||
<select id="getFULLNuclideNames" resultType="java.lang.String">
|
||||
|
@ -899,6 +927,10 @@
|
|||
</foreach>
|
||||
</insert>
|
||||
|
||||
<delete id="deleteROIResults">
|
||||
DELETE FROM RNMAN.GARDS_ROI_RESULTS WHERE IDANALYSIS=#{idAnalysis}
|
||||
</delete>
|
||||
|
||||
<select id="getIdAnalysisByIdAnalyst" resultType="java.lang.String">
|
||||
SELECT IDANALYSIS FROM RNMAN.GARDS_ANALYSES WHERE SAMPLE_ID = #{sampleId} AND ANALYST = #{userName}
|
||||
</select>
|
||||
|
|
|
@ -3,6 +3,7 @@ package org.jeecg.modules.native_jni.struct;
|
|||
import java.util.List;
|
||||
|
||||
public class BgAnalyseResult {
|
||||
|
||||
/************************** GARDS_XE_RESULTS START**************************/
|
||||
/************************** XE_131m **************************/
|
||||
public double Xe131m_con;
|
||||
|
@ -44,36 +45,39 @@ public class BgAnalyseResult {
|
|||
public List<Double> ROI_net_coutns_err;
|
||||
public List<Double> ROI_con_uncer;
|
||||
public List<Double> ROI_con_uncer_err;
|
||||
|
||||
public List<Integer> MDC;
|
||||
public List<Double> MDC;
|
||||
public List<Integer> dNidFlag;
|
||||
|
||||
/************************** GARDS_ROI_RESULTS end **************************/
|
||||
|
||||
/************************** GARDS_ROI_RESULTS START**************************/
|
||||
/************************** GARDS_CALIBRATION START**************************/
|
||||
public List<Double> s_b_fitting_c_e;
|
||||
public List<Double> s_b_fitting_e_c;
|
||||
public int s_b_fitting_type;
|
||||
public String s_b_fitting_type_def;
|
||||
public List<Double> s_g_fitting_c_e;
|
||||
public List<Double> s_g_fitting_e_c;
|
||||
public int s_g_fitting_type;
|
||||
public String s_g_fitting_type_def;
|
||||
|
||||
public List<Double> g_b_fitting_c_e;
|
||||
public List<Double> g_b_fitting_e_c;
|
||||
public int g_b_fitting_type;
|
||||
public String g_b_fitting_type_def;
|
||||
public List<Double> g_g_fitting_c_e;
|
||||
public List<Double> g_g_fitting_e_c;
|
||||
public int g_g_fitting_type;
|
||||
public String g_g_fitting_type_def;
|
||||
|
||||
public List<Double> d_b_fitting_c_e;
|
||||
public List<Double> d_b_fitting_e_c;
|
||||
public int d_b_fitting_type;
|
||||
public String d_b_fitting_type_def;
|
||||
public List<Double> d_g_fitting_c_e;
|
||||
public List<Double> d_g_fitting_e_c;
|
||||
public int d_g_fitting_type;
|
||||
public String d_g_fitting_type_def;
|
||||
/************************** GARDS_CALIBRATION end **************************/
|
||||
|
||||
/************************** GARDS_CALIBRATION START**************************/
|
||||
/************************** GARDS_ROI_CHANNELS START**************************/
|
||||
public List<Integer> S_ROI;
|
||||
public List<Integer> S_ROI_B_Boundary_start;
|
||||
public List<Integer> S_ROI_B_Boundary_stop;
|
||||
|
@ -174,4 +178,5 @@ public class BgAnalyseResult {
|
|||
", error_log='" + error_log + '\'' +
|
||||
'}';
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -39,7 +39,7 @@ public interface IGammaService{
|
|||
|
||||
Result addPeakComment(String fileName, int curRow, String comments);
|
||||
|
||||
Result viewGenralComment(String fileName);
|
||||
Result viewGeneralComment(String fileName);
|
||||
|
||||
Result addGeneralComment(String fileName, String comments);
|
||||
|
||||
|
@ -57,19 +57,19 @@ public interface IGammaService{
|
|||
|
||||
List<InputData> KorSumInput(CoeffData coeffData);
|
||||
|
||||
Result energyCalibration(Integer sampleId, String fileName);
|
||||
Result energyCalibration(Integer sampleId, String fileName, String currentText);
|
||||
|
||||
Result changeDataEnergy(List<Double> m_vCurCentroid, List<Double> m_vCurEnergy, List<Double> m_vCurUncert, ParameterInfo m_curParam, Integer sampleId, String fileName);
|
||||
|
||||
Result applyDataEnergy(List<Double> m_vCurCentroid, List<Double> m_vCurEnergy, List<Double> m_vCurUncert, ParameterInfo m_curParam, String curCalName, Integer sampleId, String fileName);
|
||||
|
||||
Result resolutionCalibration(Integer sampleId, String fileName);
|
||||
Result resolutionCalibration(Integer sampleId, String fileName, String currentText);
|
||||
|
||||
Result changeDataResolution(List<Double> m_vCurReso, List<Double> m_vCurEnergy, List<Double> m_vCurUncert, ParameterInfo m_curParam, Integer sampleId, String fileName);
|
||||
|
||||
Result applyDataResolution(List<Double> m_vCurReso, List<Double> m_vCurEnergy, List<Double> m_vCurUncert, ParameterInfo m_curParam, String curCalName, Integer sampleId, String fileName);
|
||||
|
||||
Result EfficiencyCalibration(Integer sampleId, String fileName);
|
||||
Result EfficiencyCalibration(Integer sampleId, String fileName, String currentText);
|
||||
|
||||
Result changeDataEfficiency(List<Double> m_vCurEffi, List<Double> m_vCurEnergy, List<Double> m_vCurUncert, ParameterInfo m_curParam, Integer funcId, Integer sampleId, String fileName);
|
||||
|
||||
|
|
|
@ -27,43 +27,43 @@ public interface ISpectrumAnalysisService {
|
|||
|
||||
Result deleteDBSpectrumChartData(Integer[] sampleIds);
|
||||
|
||||
Result viewComment(Integer sampleId, HttpServletRequest request);
|
||||
Result viewComment(Integer sampleId, String sampleFileName, HttpServletRequest request);
|
||||
|
||||
void viewARR(Integer sampleId, HttpServletResponse response);
|
||||
|
||||
Result viewRRR(String dbName, Integer sampleId, boolean sampleData, boolean GasBgData, boolean DetBgData, boolean QCData, boolean bGammaEnergyValid, boolean bBetaEnergyValid);
|
||||
Result viewRRR(RRRLogInfo rrrLogInfo, HttpServletRequest request);
|
||||
|
||||
Result viewSpectrum(Integer sampleId);
|
||||
Result viewSpectrum(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, String qcFileName, HttpServletRequest request);
|
||||
|
||||
Result<?> viewSampleInformation(Integer sampleId);
|
||||
Result viewSampleInformation(Integer sampleId, String sampleFileName, HttpServletRequest request);
|
||||
|
||||
void exportSampleInformation(Integer sampleId, HttpServletResponse response);
|
||||
void exportSampleInformation(Integer sampleId, String sampleFileName, HttpServletRequest request, HttpServletResponse response);
|
||||
|
||||
Result<?> viewQCResult(Integer sampleId);
|
||||
Result viewQCResult(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request);
|
||||
|
||||
void exportQCResult(Integer sampleId, HttpServletResponse response);
|
||||
void exportQCResult(Integer sampleId, String dbName, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request, HttpServletResponse response);
|
||||
|
||||
Result viewRLR(Integer sampleId);
|
||||
Result viewRLR(Integer sampleId, String sampleFileName, String gasFileName, String detFileName, HttpServletRequest request);
|
||||
|
||||
void exportRLR(Integer sampleId, HttpServletResponse response);
|
||||
|
||||
Result viewGammaDetectorCalibration(Integer sampleId);
|
||||
Result viewGammaDetectorCalibration(Integer sampleId, String qcFileName, HttpServletRequest request);
|
||||
|
||||
Result viewBetaDetectorCalibration(Integer sampleId);
|
||||
Result viewBetaDetectorCalibration(Integer sampleId, String qcFileName, HttpServletRequest request);
|
||||
|
||||
Result viewExtrapolation(Integer sampleId);
|
||||
Result viewExtrapolation(Integer sampleId, String sampleFileName, HttpServletRequest request);
|
||||
|
||||
Result viewMDC(Integer sampleId);
|
||||
Result viewMDC(Integer sampleId, String sampleFileName, HttpServletRequest request);
|
||||
|
||||
Result changeDetector(String stationName);
|
||||
|
||||
Result statisticsQuery(StatisticsQueryData statisticsQueryData);
|
||||
|
||||
Result statisticsQueryBtn(String detectorName, Integer stationId, String statisticsType, Date startTime, Date endTime);
|
||||
Result statisticsQueryBtn(Integer detectorId, String detectorName, Integer stationId, String statisticsType, Date startTime, Date endTime);
|
||||
|
||||
Result fitting(Double paramA, Double paramB, Double paramC, List<SeriseData> tempPointsArray, Integer count);
|
||||
|
||||
Result getGammaGated(Integer chartHeight, Integer channelWidth, Integer gammaChannel, Integer sampleId);
|
||||
Result getGammaGated(Integer chartHeight, Integer channelWidth, Integer gammaChannel, Integer sampleId, String qcFileName, HttpServletRequest request);
|
||||
|
||||
Result ReAnalyse(AnalyseData analyseData, HttpServletRequest request);
|
||||
|
||||
|
|
|
@ -340,6 +340,8 @@ public class GammaServiceImpl implements IGammaService {
|
|||
map.put("barChart", differance);
|
||||
//赋值energy
|
||||
map.put("energy", phd.getVEnergy());
|
||||
//赋值BaseCtrls
|
||||
map.put("BaseCtrls", phd.getBaseCtrls());
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
|
@ -672,7 +674,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
return result;
|
||||
}
|
||||
int index = list_identify.indexOf(nuclideName);
|
||||
if(index>0) {
|
||||
if(index>=0) {
|
||||
// 如果所选的行下标小于0 或者 超出界限 则不进行处理
|
||||
if(curRow < 0 || curRow >= phd.getVPeak().size()) {
|
||||
return result;
|
||||
|
@ -734,7 +736,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result viewGenralComment(String fileName) {
|
||||
public Result viewGeneralComment(String fileName) {
|
||||
Result result = new Result();
|
||||
Cache<String, PHDFile> phdCache = localCache.getPHDCache();
|
||||
PHDFile phd = phdCache.getIfPresent(fileName);
|
||||
|
@ -948,7 +950,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
|
||||
// date of Zero Time
|
||||
Date datetime = DateUtils.parseDate(date + " " + time, "yyyy-MM-dd HH:mm:ss");
|
||||
Date datetime = DateUtils.parseDate(date + StringPool.SPACE + time);
|
||||
Date oriDate = DateUtils.parseDate("1970-01-01 00:00:00", "yyyy-MM-dd HH:mm:ss");
|
||||
double second = (datetime.getTime()/1000 - oriDate.getTime()/1000) - t - 8*60*60;
|
||||
|
||||
|
@ -1061,7 +1063,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result energyCalibration(Integer sampleId, String fileName) {
|
||||
public Result energyCalibration(Integer sampleId, String fileName, String currentText) {
|
||||
Result result = new Result();
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
System.loadLibrary("GammaAnaly");
|
||||
|
@ -1071,14 +1073,16 @@ public class GammaServiceImpl implements IGammaService {
|
|||
result.error500("请先选择解析文件!");
|
||||
return result;
|
||||
}
|
||||
String usedEner = phd.getUsedEner();
|
||||
if (StringUtils.isBlank(currentText)) {
|
||||
currentText = phd.getUsedEner();
|
||||
}
|
||||
List<String> dataSourceList = phd.getMapEnerKD().keySet().stream().collect(Collectors.toList());
|
||||
map.put("list_dataSource", dataSourceList);
|
||||
List<Double> m_vCurCentroid = phd.getMapEnerKD().get(usedEner).getCentroid_channel();
|
||||
List<Double> m_vCurEnergy = phd.getMapEnerKD().get(usedEner).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapEnerKD().get(usedEner).getUncertainty();
|
||||
List<Double> m_vCurCentroid = phd.getMapEnerKD().get(currentText).getCentroid_channel();
|
||||
List<Double> m_vCurEnergy = phd.getMapEnerKD().get(currentText).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapEnerKD().get(currentText).getUncertainty();
|
||||
map.put("uncert", m_vCurUncert);
|
||||
ParameterInfo m_curParam = phd.getMapEnerPara().get(usedEner);
|
||||
ParameterInfo m_curParam = phd.getMapEnerPara().get(currentText);
|
||||
map.put("param", m_curParam);
|
||||
int num = m_vCurEnergy.size();
|
||||
if(num < 1){
|
||||
|
@ -1099,6 +1103,8 @@ public class GammaServiceImpl implements IGammaService {
|
|||
String equation = gammaFileUtil.UpdateEquationEnergy(m_curParam);
|
||||
map.put("equation", equation);
|
||||
gammaFileUtil.UpdateChartEnergy(m_vCurEnergy, m_curParam, m_vCurCentroid, phd, map);
|
||||
map.put("rg_low", phd.getBaseCtrls().getRg_low());
|
||||
map.put("rg_high", phd.getBaseCtrls().getRg_high());
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
|
@ -1193,7 +1199,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result resolutionCalibration(Integer sampleId, String fileName) {
|
||||
public Result resolutionCalibration(Integer sampleId, String fileName, String currentText) {
|
||||
Result result = new Result();
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
System.loadLibrary("GammaAnaly");
|
||||
|
@ -1203,20 +1209,21 @@ public class GammaServiceImpl implements IGammaService {
|
|||
result.error500("请先选择解析文件!");
|
||||
return result;
|
||||
}
|
||||
String usedReso = phd.getUsedReso();
|
||||
if (StringUtils.isBlank(currentText)) {
|
||||
currentText = phd.getUsedReso();
|
||||
}
|
||||
List<String> dataSourceList = phd.getMapResoKD().keySet().stream().collect(Collectors.toList());
|
||||
map.put("list_dataSource", dataSourceList);
|
||||
List<Double> m_vCurReso = phd.getMapResoKD().get(usedReso).getFWHM();
|
||||
List<Double> m_vCurEnergy = phd.getMapResoKD().get(usedReso).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapResoKD().get(usedReso).getUncertainty();
|
||||
List<Double> m_vCurReso = phd.getMapResoKD().get(currentText).getFWHM();
|
||||
List<Double> m_vCurEnergy = phd.getMapResoKD().get(currentText).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapResoKD().get(currentText).getUncertainty();
|
||||
map.put("uncert", m_vCurUncert);
|
||||
ParameterInfo m_curParam = phd.getMapResoPara().get(usedReso);
|
||||
ParameterInfo m_curParam = phd.getMapResoPara().get(currentText);
|
||||
map.put("param", m_curParam);
|
||||
int num = m_vCurEnergy.size();
|
||||
if(num < 1){
|
||||
return result;
|
||||
}
|
||||
|
||||
List<Double> vFit = CalValuesHandler.calFcnEval(m_vCurEnergy, m_curParam.getP()).counts;
|
||||
List<ResolutionData> resolutionDataList = new LinkedList<>();
|
||||
for(int i=0; i<num; ++i) {
|
||||
|
@ -1232,6 +1239,8 @@ public class GammaServiceImpl implements IGammaService {
|
|||
String equation = gammaFileUtil.UpdateEquationResolution(m_curParam);
|
||||
map.put("equation", equation);
|
||||
gammaFileUtil.UpdateChartResolution(m_vCurEnergy, m_curParam, m_vCurReso, phd, map);
|
||||
map.put("ECutAnalysis_Low", phd.getSetting().getECutAnalysis_Low());
|
||||
map.put("G_energy_span", phd.getSpec().getG_energy_span());
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
|
@ -1316,7 +1325,7 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result EfficiencyCalibration(Integer sampleId, String fileName) {
|
||||
public Result EfficiencyCalibration(Integer sampleId, String fileName, String currentText) {
|
||||
Result result = new Result();
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
List<String> m_vFuncName = new LinkedList<>();
|
||||
|
@ -1335,20 +1344,21 @@ public class GammaServiceImpl implements IGammaService {
|
|||
result.error500("请先选择解析文件!");
|
||||
return result;
|
||||
}
|
||||
String usedEffi = phd.getUsedEffi();
|
||||
if (StringUtils.isBlank(currentText)) {
|
||||
currentText = phd.getUsedEffi();
|
||||
}
|
||||
List<String> dataSourceList = phd.getMapEffiKD().keySet().stream().collect(Collectors.toList());
|
||||
map.put("list_dataSource", dataSourceList);
|
||||
List<Double> m_vCurEffi = phd.getMapEffiKD().get(usedEffi).getEfficiency();
|
||||
List<Double> m_vCurEnergy = phd.getMapEffiKD().get(usedEffi).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapEffiKD().get(usedEffi).getUncertainty();
|
||||
List<Double> m_vCurEffi = phd.getMapEffiKD().get(currentText).getEfficiency();
|
||||
List<Double> m_vCurEnergy = phd.getMapEffiKD().get(currentText).getG_energy();
|
||||
List<Double> m_vCurUncert = phd.getMapEffiKD().get(currentText).getUncertainty();
|
||||
map.put("uncert", m_vCurUncert);
|
||||
ParameterInfo m_curParam = phd.getMapEffiPara().get(usedEffi);
|
||||
ParameterInfo m_curParam = phd.getMapEffiPara().get(currentText);
|
||||
map.put("param", m_curParam);
|
||||
int num = m_vCurEnergy.size();
|
||||
if(num < 1){
|
||||
return result;
|
||||
}
|
||||
|
||||
List<Double> vFit = CalValuesHandler.calFcnEval(m_vCurEnergy, m_curParam.getP()).counts;
|
||||
List<EfficiencyData> efficiencyDataList = new LinkedList<>();
|
||||
for(int i=0; i<num; ++i) {
|
||||
|
@ -1364,6 +1374,8 @@ public class GammaServiceImpl implements IGammaService {
|
|||
String equation = gammaFileUtil.UpdateEquationEfficiency(m_vCurEnergy, m_curParam);
|
||||
map.put("equation", equation);
|
||||
gammaFileUtil.UpdateChartEfficiency(m_vCurEnergy, m_curParam, m_vCurEffi, phd, map);
|
||||
map.put("ECutAnalysis_Low", phd.getSetting().getECutAnalysis_Low());
|
||||
map.put("G_energy_span", phd.getSpec().getG_energy_span());
|
||||
result.setSuccess(true);
|
||||
result.setResult(map);
|
||||
return result;
|
||||
|
@ -1769,9 +1781,9 @@ public class GammaServiceImpl implements IGammaService {
|
|||
}
|
||||
Map<String, String> map = new HashMap<>();
|
||||
try {
|
||||
String collect_start = phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time();
|
||||
String collect_stop = phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time();
|
||||
String acq_start = phd.getAcq().getAcquisition_start_date() + " " + phd.getAcq().getAcquisition_start_time();
|
||||
String collect_start = phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time();
|
||||
String collect_stop = phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time();
|
||||
String acq_start = phd.getAcq().getAcquisition_start_date() + StringPool.SPACE + phd.getAcq().getAcquisition_start_time();
|
||||
Date collect_stop_dt = DateUtils.parseDate(collect_stop);
|
||||
Date collect_start_dt = DateUtils.parseDate(collect_start);
|
||||
double Sampling_Time = (collect_stop_dt.getTime()/1000 - collect_start_dt.getTime()/1000) / 3600.0;
|
||||
|
@ -1935,8 +1947,8 @@ public class GammaServiceImpl implements IGammaService {
|
|||
map.put("Obj_authorized", "High-resolution non-destructive gamma spectroscopy.");
|
||||
map.put("Obj_instruction", "`0");
|
||||
// Init #Collection
|
||||
String col_start = phd.getCollect().getCollection_start_date() + " " + phd.getCollect().getCollection_start_time();
|
||||
String col_stop = phd.getCollect().getCollection_stop_date() + " " + phd.getCollect().getCollection_stop_time();
|
||||
String col_start = phd.getCollect().getCollection_start_date() + StringPool.SPACE + phd.getCollect().getCollection_start_time();
|
||||
String col_stop = phd.getCollect().getCollection_stop_date() + StringPool.SPACE + phd.getCollect().getCollection_stop_time();
|
||||
map.put("collect_start", col_start);
|
||||
map.put("collect_stop", col_stop);
|
||||
map.put("collect_airVolume", phd.getCollect().getAir_volume());
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -5,6 +5,7 @@ import cn.hutool.core.collection.ListUtil;
|
|||
import cn.hutool.core.io.FileUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.baomidou.mybatisplus.core.toolkit.StringPool;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import org.apache.commons.net.ftp.FTPClient;
|
||||
import org.apache.commons.net.ftp.FTPFile;
|
||||
|
@ -177,6 +178,6 @@ public class SpectrumFileServiceImpl implements ISpectrumFileService {
|
|||
fileSize /= 1024;
|
||||
index++;
|
||||
}
|
||||
return String.format("%.2f", fileSize) + " " + units[index];
|
||||
return String.format("%.2f", fileSize) + StringPool.SPACE + units[index];
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user