feat:自建台站增加Configure接口
This commit is contained in:
parent
3c02c89ae5
commit
b5d4b23f3c
|
@ -4,6 +4,7 @@ import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.modules.entity.vo.ChangeData;
|
import org.jeecg.modules.entity.vo.ChangeData;
|
||||||
|
import org.jeecg.modules.entity.vo.ConfigureData;
|
||||||
import org.jeecg.modules.entity.vo.FittingBody;
|
import org.jeecg.modules.entity.vo.FittingBody;
|
||||||
import org.jeecg.modules.entity.vo.UserLibraryInfo;
|
import org.jeecg.modules.entity.vo.UserLibraryInfo;
|
||||||
import org.jeecg.modules.service.ISelfStationService;
|
import org.jeecg.modules.service.ISelfStationService;
|
||||||
|
@ -202,4 +203,16 @@ public class SelfStationController {
|
||||||
public Result saveUserLibrary(@RequestBody UserLibraryInfo userLibraryInfo, HttpServletRequest request) {
|
public Result saveUserLibrary(@RequestBody UserLibraryInfo userLibraryInfo, HttpServletRequest request) {
|
||||||
return selfStationService.saveUserLibrary(userLibraryInfo.getUserLibraryName(), userLibraryInfo.getFileName(), request);
|
return selfStationService.saveUserLibrary(userLibraryInfo.getUserLibraryName(), userLibraryInfo.getFileName(), request);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("configure")
|
||||||
|
@ApiOperation(value = "analyze菜单下configure页面数据", notes = "analyze菜单下configure页面数据")
|
||||||
|
public Result configure(String fileName, HttpServletRequest request) {
|
||||||
|
return selfStationService.configure(fileName, request);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("configureSave")
|
||||||
|
@ApiOperation(value = "analyze菜单下configure页面数据保存按钮", notes = "analyze菜单下configure页面数据保存按钮")
|
||||||
|
public Result configureSave(@RequestBody ConfigureData configureData, HttpServletRequest request) {
|
||||||
|
return selfStationService.configureSave(configureData, request);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -142,6 +142,11 @@ public class SelfStationVueData implements Serializable {
|
||||||
mapEnerPara = new HashMap<>();
|
mapEnerPara = new HashMap<>();
|
||||||
mapResoPara = new HashMap<>();
|
mapResoPara = new HashMap<>();
|
||||||
mapEffiPara = new HashMap<>();
|
mapEffiPara = new HashMap<>();
|
||||||
|
|
||||||
|
ROIOnePHDFile = new PHDFile();
|
||||||
|
ROITwoPHDFile = new PHDFile();
|
||||||
|
ROIThreePHDFile = new PHDFile();
|
||||||
|
ROIFourPHDFile = new PHDFile();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
package org.jeecg.modules.service;
|
package org.jeecg.modules.service;
|
||||||
|
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.modules.entity.vo.ConfigureData;
|
||||||
import org.jeecg.modules.entity.vo.ParameterInfo;
|
import org.jeecg.modules.entity.vo.ParameterInfo;
|
||||||
import org.jeecg.modules.entity.vo.SeriseData;
|
import org.jeecg.modules.entity.vo.SeriseData;
|
||||||
import org.springframework.web.multipart.MultipartFile;
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
@ -72,4 +73,8 @@ public interface ISelfStationService {
|
||||||
Result configUserLibrary(Integer sampleId, String fileName, HttpServletRequest request);
|
Result configUserLibrary(Integer sampleId, String fileName, HttpServletRequest request);
|
||||||
|
|
||||||
Result saveUserLibrary(List<String> userLibraryName, String fileName, HttpServletRequest request);
|
Result saveUserLibrary(List<String> userLibraryName, String fileName, HttpServletRequest request);
|
||||||
|
|
||||||
|
Result configure(String fileName, HttpServletRequest request);
|
||||||
|
|
||||||
|
Result configureSave(ConfigureData configureData, HttpServletRequest request);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
package org.jeecg.modules.service.impl;
|
package org.jeecg.modules.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.ListUtil;
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||||
|
@ -12,6 +14,7 @@ import org.apache.commons.io.FileUtils;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.cache.LocalCache;
|
import org.jeecg.common.cache.LocalCache;
|
||||||
import org.jeecg.common.cache.SelfCache;
|
import org.jeecg.common.cache.SelfCache;
|
||||||
|
import org.jeecg.common.constant.DateConstant;
|
||||||
import org.jeecg.common.properties.ParameterProperties;
|
import org.jeecg.common.properties.ParameterProperties;
|
||||||
import org.jeecg.common.properties.SpectrumPathProperties;
|
import org.jeecg.common.properties.SpectrumPathProperties;
|
||||||
import org.jeecg.common.system.util.JwtUtil;
|
import org.jeecg.common.system.util.JwtUtil;
|
||||||
|
@ -19,6 +22,7 @@ import org.jeecg.common.util.*;
|
||||||
import org.jeecg.modules.base.entity.configuration.GardsNuclLib;
|
import org.jeecg.modules.base.entity.configuration.GardsNuclLib;
|
||||||
import org.jeecg.modules.base.entity.configuration.GardsNuclLinesLib;
|
import org.jeecg.modules.base.entity.configuration.GardsNuclLinesLib;
|
||||||
import org.jeecg.modules.base.entity.original.GardsSampleData;
|
import org.jeecg.modules.base.entity.original.GardsSampleData;
|
||||||
|
import org.jeecg.modules.base.entity.rnman.GardsAnalySetting;
|
||||||
import org.jeecg.modules.entity.vo.*;
|
import org.jeecg.modules.entity.vo.*;
|
||||||
import org.jeecg.modules.mapper.SpectrumAnalysisMapper;
|
import org.jeecg.modules.mapper.SpectrumAnalysisMapper;
|
||||||
import org.jeecg.modules.native_jni.CalValuesHandler;
|
import org.jeecg.modules.native_jni.CalValuesHandler;
|
||||||
|
@ -27,6 +31,7 @@ import org.jeecg.modules.native_jni.struct.EnergySpectrumStruct;
|
||||||
import org.jeecg.modules.service.ISelfStationService;
|
import org.jeecg.modules.service.ISelfStationService;
|
||||||
import org.jeecg.modules.service.ISysDefaultNuclideSpectrumService;
|
import org.jeecg.modules.service.ISysDefaultNuclideSpectrumService;
|
||||||
import org.jeecg.modules.service.ISysUserColorService;
|
import org.jeecg.modules.service.ISysUserColorService;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.web.multipart.MultipartFile;
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
@ -37,6 +42,9 @@ import java.io.*;
|
||||||
import java.net.URLEncoder;
|
import java.net.URLEncoder;
|
||||||
import java.text.DecimalFormat;
|
import java.text.DecimalFormat;
|
||||||
import java.text.NumberFormat;
|
import java.text.NumberFormat;
|
||||||
|
import java.text.ParseException;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.format.DateTimeFormatter;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
@ -153,6 +161,9 @@ public class SelfStationServiceImpl implements ISelfStationService {
|
||||||
resultMap.put("det", map);
|
resultMap.put("det", map);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 初始化自建台站Configure信息
|
||||||
|
if (!StrUtil.equals(dbName, "RNAUTO")) initConfigure(analysisID, selfStationData);
|
||||||
|
// 初始化自建台站用户核素库信息
|
||||||
if (ObjectUtil.isNotNull(selfStationData.getSampleStruct())){
|
if (ObjectUtil.isNotNull(selfStationData.getSampleStruct())){
|
||||||
String systemType = selfStationData.getSampleStruct().getSystem_type();
|
String systemType = selfStationData.getSampleStruct().getSystem_type();
|
||||||
if (!redisUtil.hasKey(userName+StringPool.DASH+systemType + "-self")
|
if (!redisUtil.hasKey(userName+StringPool.DASH+systemType + "-self")
|
||||||
|
@ -230,6 +241,8 @@ public class SelfStationServiceImpl implements ISelfStationService {
|
||||||
selfStationData.setSampleTmpPath(sampleFilePath);
|
selfStationData.setSampleTmpPath(sampleFilePath);
|
||||||
selfStationUtil.loadFile(selfStationData, null, null, "sample", map);
|
selfStationUtil.loadFile(selfStationData, null, null, "sample", map);
|
||||||
resultMap.put("sample", map);
|
resultMap.put("sample", map);
|
||||||
|
// 初始化Configure
|
||||||
|
initConfigure(struct, selfStationData);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//判断det文件名是否为空
|
//判断det文件名是否为空
|
||||||
|
@ -310,6 +323,100 @@ public class SelfStationServiceImpl implements ISelfStationService {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void initConfigure(EnergySpectrumStruct struct, SelfStationData selfStationData){
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
PHDFile roiTwoPHDFile = selfStationData.getSampleVueData().getROITwoPHDFile();
|
||||||
|
PHDFile roiThreePHDFile = selfStationData.getSampleVueData().getROIThreePHDFile();
|
||||||
|
PHDFile roiFourPHDFile = selfStationData.getSampleVueData().getROIFourPHDFile();
|
||||||
|
if(StrUtil.equalsIgnoreCase(struct.system_type, "P")) {
|
||||||
|
roiOnePHDFile.getSetting().setECutAnalysis_Low(35.0);
|
||||||
|
roiTwoPHDFile.getSetting().setECutAnalysis_Low(35.0);
|
||||||
|
roiThreePHDFile.getSetting().setECutAnalysis_Low(35.0);
|
||||||
|
roiFourPHDFile.getSetting().setECutAnalysis_Low(35.0);
|
||||||
|
roiOnePHDFile.getSetting().setBUpdateCal(true);
|
||||||
|
roiTwoPHDFile.getSetting().setBUpdateCal(true);
|
||||||
|
roiThreePHDFile.getSetting().setBUpdateCal(true);
|
||||||
|
roiFourPHDFile.getSetting().setBUpdateCal(true);
|
||||||
|
}
|
||||||
|
String collectionStartDate = struct.collection_start_date;
|
||||||
|
String collectionStartTime = struct.collection_start_time;
|
||||||
|
if (StrUtil.isNotBlank(collectionStartDate) && StrUtil.isNotBlank(collectionStartTime)) {
|
||||||
|
String str = collectionStartDate + StringPool.SPACE + collectionStartTime;
|
||||||
|
Date refTimeConc = null;
|
||||||
|
try {
|
||||||
|
refTimeConc = DateUtils.parseDate(str);
|
||||||
|
} catch (ParseException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
roiOnePHDFile.getSetting().setRefTime_conc(refTimeConc);
|
||||||
|
roiTwoPHDFile.getSetting().setRefTime_conc(refTimeConc);
|
||||||
|
roiThreePHDFile.getSetting().setRefTime_conc(refTimeConc);
|
||||||
|
roiFourPHDFile.getSetting().setRefTime_conc(refTimeConc);
|
||||||
|
}
|
||||||
|
String acquisitionStartDate = struct.acquisition_start_date;
|
||||||
|
String acquisitionStartTime = struct.acquisition_start_time;
|
||||||
|
if (StrUtil.isNotBlank(acquisitionStartDate) && StrUtil.isNotBlank(acquisitionStartTime)) {
|
||||||
|
String str = acquisitionStartDate + StringPool.SPACE + acquisitionStartTime;
|
||||||
|
Date refTimeAct = null;
|
||||||
|
try {
|
||||||
|
refTimeAct = DateUtils.parseDate(str);
|
||||||
|
} catch (ParseException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
roiOnePHDFile.getSetting().setRefTime_act(refTimeAct);
|
||||||
|
roiTwoPHDFile.getSetting().setRefTime_act(refTimeAct);
|
||||||
|
roiThreePHDFile.getSetting().setRefTime_act(refTimeAct);
|
||||||
|
roiFourPHDFile.getSetting().setRefTime_act(refTimeAct);
|
||||||
|
}
|
||||||
|
SpecSetup usedSetting = new SpecSetup();
|
||||||
|
BeanUtils.copyProperties(roiOnePHDFile.getSetting(), usedSetting);
|
||||||
|
roiOnePHDFile.setUsedSetting(usedSetting);
|
||||||
|
roiTwoPHDFile.setUsedSetting(usedSetting);
|
||||||
|
roiThreePHDFile.setUsedSetting(usedSetting);
|
||||||
|
roiFourPHDFile.setUsedSetting(usedSetting);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DS("ora")
|
||||||
|
public void initConfigure(Integer idAnalysis, SelfStationData selfStationData){
|
||||||
|
GardsAnalySetting analySetting = spectrumAnalysisMapper.getAnalySetting(idAnalysis);
|
||||||
|
if (Objects.nonNull(analySetting)) {
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
PHDFile roiTwoPHDFile = selfStationData.getSampleVueData().getROITwoPHDFile();
|
||||||
|
PHDFile roiThreePHDFile = selfStationData.getSampleVueData().getROIThreePHDFile();
|
||||||
|
PHDFile roiFourPHDFile = selfStationData.getSampleVueData().getROIFourPHDFile();
|
||||||
|
List<PHDFile> phdList = ListUtil.toList(roiOnePHDFile, roiTwoPHDFile, roiThreePHDFile, roiFourPHDFile);
|
||||||
|
for (PHDFile phd : phdList) {
|
||||||
|
phd.getUsedSetting().setECutAnalysis_Low(analySetting.getEcutanalysisLow());
|
||||||
|
phd.getUsedSetting().setECutAnalysis_High((Objects.nonNull(analySetting.getEcutanalysisHigh())?(analySetting.getEcutanalysisHigh() <= phd.getUsedSetting().getECutAnalysis_Low()?-9999:analySetting.getEcutanalysisHigh()):-9999));
|
||||||
|
phd.getUsedSetting().setEnergyTolerance(analySetting.getEnergytolerance());
|
||||||
|
phd.getUsedSetting().setCalibrationPSS_high(analySetting.getCalibrationpssHigh());
|
||||||
|
phd.getUsedSetting().setCalibrationPSS_low(analySetting.getCalibrationpssLow());
|
||||||
|
phd.getUsedSetting().setBaseImprovePSS(analySetting.getBaseimprovepss());
|
||||||
|
phd.getUsedSetting().setPss_low(analySetting.getPssLow());
|
||||||
|
phd.getUsedSetting().setK_back(analySetting.getKBack());
|
||||||
|
phd.getUsedSetting().setK_alpha(analySetting.getKAlpha());
|
||||||
|
phd.getUsedSetting().setK_beta(analySetting.getKBeta());
|
||||||
|
phd.getUsedSetting().setRiskLevelK(analySetting.getRisklevelk());
|
||||||
|
phd.getUsedSetting().setBUpdateCal(analySetting.getBupdatecal() == 1);
|
||||||
|
phd.getUsedSetting().setKeepCalPeakSearchPeaks(analySetting.getKeepcalpeakserchpeaks() == 1);
|
||||||
|
}
|
||||||
|
Date reftimeAct = analySetting.getReftimeAct();
|
||||||
|
if (Objects.nonNull(reftimeAct)) {
|
||||||
|
roiOnePHDFile.getUsedSetting().setRefTime_act(reftimeAct);
|
||||||
|
roiTwoPHDFile.getUsedSetting().setRefTime_act(reftimeAct);
|
||||||
|
roiThreePHDFile.getUsedSetting().setRefTime_act(reftimeAct);
|
||||||
|
roiFourPHDFile.getUsedSetting().setRefTime_act(reftimeAct);
|
||||||
|
}
|
||||||
|
Date reftimeConc = analySetting.getReftimeConc();
|
||||||
|
if (Objects.nonNull(reftimeConc)) {
|
||||||
|
roiOnePHDFile.getUsedSetting().setRefTime_conc(reftimeConc);
|
||||||
|
roiTwoPHDFile.getUsedSetting().setRefTime_conc(reftimeConc);
|
||||||
|
roiThreePHDFile.getUsedSetting().setRefTime_conc(reftimeConc);
|
||||||
|
roiFourPHDFile.getUsedSetting().setRefTime_conc(reftimeConc);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void deleteSelfStationCache(String sampleFileName, HttpServletRequest request) {
|
public void deleteSelfStationCache(String sampleFileName, HttpServletRequest request) {
|
||||||
String userName = JwtUtil.getUserNameByToken(request);
|
String userName = JwtUtil.getUserNameByToken(request);
|
||||||
|
@ -2225,6 +2332,121 @@ public class SelfStationServiceImpl implements ISelfStationService {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Result configure(String fileName, HttpServletRequest request) {
|
||||||
|
Result result = new Result();
|
||||||
|
String userName = JwtUtil.getUserNameByToken(request);
|
||||||
|
Cache<String, SelfStationData> selfCache = selfStationCache.getSelfCache();
|
||||||
|
SelfStationData selfStationData = selfCache.getIfPresent(fileName + StringPool.DASH + userName);
|
||||||
|
if (Objects.isNull(selfStationData)) {
|
||||||
|
result.error500("Please select the parse file first!");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
// 用当前谱使用的设置初始化界面控件
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
SpecSetup setup = roiOnePHDFile.getUsedSetting();
|
||||||
|
map.put("edit_ps_low", setup.getECutAnalysis_Low());
|
||||||
|
map.put("edit_ps_high", setup.getECutAnalysis_High());
|
||||||
|
map.put("edit_energy", setup.getEnergyTolerance());
|
||||||
|
map.put("edit_pss_low", setup.getPss_low());
|
||||||
|
map.put("edit_cal_low", setup.getCalibrationPSS_low());
|
||||||
|
map.put("edit_cal_high", setup.getCalibrationPSS_high());
|
||||||
|
map.put("checkBox_updateCal", setup.isBUpdateCal());
|
||||||
|
map.put("checkBox_keepPeak", setup.isKeepCalPeakSearchPeaks());
|
||||||
|
map.put("edit_bi_pss", setup.getBaseImprovePSS());
|
||||||
|
map.put("edit_riskLevelK", setup.getRiskLevelK());
|
||||||
|
map.put("edit_k_back", setup.getK_back());
|
||||||
|
map.put("edit_k_alpha", setup.getK_alpha());
|
||||||
|
map.put("edit_k_beta", setup.getK_beta());
|
||||||
|
map.put("dateTime_Act", setup.getRefTime_act());
|
||||||
|
map.put("dateTime_Conc", setup.getRefTime_conc());
|
||||||
|
|
||||||
|
// 当前谱文件为非 “P” 类型时禁用“刻度更新”模块
|
||||||
|
String systemType = selfStationData.getSampleStruct().system_type;
|
||||||
|
if (!StrUtil.equalsIgnoreCase(systemType, "P"))
|
||||||
|
map.put("group_calPS", false);
|
||||||
|
result.setSuccess(true);
|
||||||
|
result.setResult(map);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Result configureSave(ConfigureData configureData, HttpServletRequest request) {
|
||||||
|
Result result = new Result();
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
String userName = JwtUtil.getUserNameByToken(request);
|
||||||
|
String fileName = configureData.getFileName();
|
||||||
|
Cache<String, SelfStationData> selfCache = selfStationCache.getSelfCache();
|
||||||
|
if (configureData.isApplyAll()) {
|
||||||
|
for (String key: selfCache.asMap().keySet()) {
|
||||||
|
SelfStationData selfStationData = selfCache.getIfPresent(key);
|
||||||
|
if (Objects.isNull(selfStationData)) {
|
||||||
|
result.error500("Please select the parse file first!");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
PHDFile roiTwoPHDFile = selfStationData.getSampleVueData().getROITwoPHDFile();
|
||||||
|
PHDFile roiThreePHDFile = selfStationData.getSampleVueData().getROIThreePHDFile();
|
||||||
|
PHDFile roiFourPHDFile = selfStationData.getSampleVueData().getROIFourPHDFile();
|
||||||
|
|
||||||
|
List<PHDFile> phdList = ListUtil.toList(roiOnePHDFile, roiTwoPHDFile,
|
||||||
|
roiThreePHDFile, roiFourPHDFile);
|
||||||
|
for (PHDFile phd : phdList) {
|
||||||
|
SpecSetup phdSetting = phd.getSetting();
|
||||||
|
phdSetting.setECutAnalysis_Low(configureData.getECutAnalysis_Low());
|
||||||
|
phdSetting.setECutAnalysis_High(configureData.getECutAnalysis_High());
|
||||||
|
phdSetting.setEnergyTolerance(configureData.getEnergyTolerance());
|
||||||
|
phdSetting.setPss_low(configureData.getPss_low());
|
||||||
|
phdSetting.setBaseImprovePSS(configureData.getBaseImprovePSS());
|
||||||
|
phdSetting.setK_back(configureData.getK_back());
|
||||||
|
phdSetting.setK_alpha(configureData.getK_alpha());
|
||||||
|
phdSetting.setK_beta(configureData.getK_beta());
|
||||||
|
phdSetting.setRiskLevelK(configureData.getRiskLevelK());
|
||||||
|
phdSetting.setBUpdateCal(configureData.isUpdateCalibration());
|
||||||
|
phdSetting.setKeepCalPeakSearchPeaks(configureData.isKeepCalPeakSearchPeaks());
|
||||||
|
phdSetting.setRefTime_act(configureData.getRefTime_act());
|
||||||
|
phdSetting.setRefTime_conc(configureData.getRefTime_conc());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
SelfStationData selfStationData = selfCache.getIfPresent(fileName + StringPool.DASH + userName);
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
map.put("checkBox_updateCal", roiOnePHDFile.getSetting().isBUpdateCal());
|
||||||
|
} else {
|
||||||
|
SelfStationData selfStationData = selfCache.getIfPresent(fileName + StringPool.DASH + userName);
|
||||||
|
if (Objects.isNull(selfStationData)) {
|
||||||
|
result.error500("Please select the parse file first!");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
PHDFile roiOnePHDFile = selfStationData.getSampleVueData().getROIOnePHDFile();
|
||||||
|
PHDFile roiTwoPHDFile = selfStationData.getSampleVueData().getROITwoPHDFile();
|
||||||
|
PHDFile roiThreePHDFile = selfStationData.getSampleVueData().getROIThreePHDFile();
|
||||||
|
PHDFile roiFourPHDFile = selfStationData.getSampleVueData().getROIFourPHDFile();
|
||||||
|
|
||||||
|
List<PHDFile> phdList = ListUtil.toList(roiOnePHDFile, roiTwoPHDFile,
|
||||||
|
roiThreePHDFile, roiFourPHDFile);
|
||||||
|
for (PHDFile phd : phdList) {
|
||||||
|
SpecSetup phdSetting = phd.getSetting();
|
||||||
|
phdSetting.setECutAnalysis_Low(configureData.getECutAnalysis_Low());
|
||||||
|
phdSetting.setECutAnalysis_High(configureData.getECutAnalysis_High());
|
||||||
|
phdSetting.setEnergyTolerance(configureData.getEnergyTolerance());
|
||||||
|
phdSetting.setPss_low(configureData.getPss_low());
|
||||||
|
phdSetting.setBaseImprovePSS(configureData.getBaseImprovePSS());
|
||||||
|
phdSetting.setK_back(configureData.getK_back());
|
||||||
|
phdSetting.setK_alpha(configureData.getK_alpha());
|
||||||
|
phdSetting.setK_beta(configureData.getK_beta());
|
||||||
|
phdSetting.setRiskLevelK(configureData.getRiskLevelK());
|
||||||
|
phdSetting.setBUpdateCal(configureData.isUpdateCalibration());
|
||||||
|
phdSetting.setKeepCalPeakSearchPeaks(configureData.isKeepCalPeakSearchPeaks());
|
||||||
|
phdSetting.setRefTime_act(configureData.getRefTime_act());
|
||||||
|
phdSetting.setRefTime_conc(configureData.getRefTime_conc());
|
||||||
|
}
|
||||||
|
map.put("checkBox_updateCal", roiOnePHDFile.getSetting().isBUpdateCal());
|
||||||
|
}
|
||||||
|
result.success("Save successfully");
|
||||||
|
result.setResult(map);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
private Map<String, Object> gammaAnalyse(PHDFile phd, Map<String, NuclideLines> nuclideLinesMap,
|
private Map<String, Object> gammaAnalyse(PHDFile phd, Map<String, NuclideLines> nuclideLinesMap,
|
||||||
Map<String, String> colorMap) throws RuntimeException{
|
Map<String, String> colorMap) throws RuntimeException{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user