Compare commits

...

184 Commits

Author SHA1 Message Date
xiaoguangbin
5719c210ca fix:自建台站beta分析 2024-08-22 11:19:29 +08:00
xiaoguangbin
356bd94a26 fix:修复新beta的保存接口执行非常慢的问题 2024-08-20 18:25:05 +08:00
nieziyan
af71f40b1c fix:格式化 2024-08-19 14:51:37 +08:00
nieziyan
0718701788 fix:分析工具核素弹窗 2024-08-15 14:18:24 +08:00
nieziyan
2693294331 fix:bug 2024-08-15 09:36:25 +08:00
nieziyan
6d2ec53b4c feat:comment接口 loadFromDB 2024-08-14 15:15:50 +08:00
xiaoguangbin
c0ba24aae4 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-08-09 15:54:58 +08:00
xiaoguangbin
a2e48e5b84 fix:修复新beta的保存接口执行非常慢的问题 2024-08-09 15:54:47 +08:00
nieziyan
8aeebe3047 feat:自建台站pekaInfomation 2024-08-09 09:17:55 +08:00
nieziyan
56e7c6adc5 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-08-08 09:41:19 +08:00
nieziyan
02083f93f5 feat:自建台站自动处理完善 2024-08-08 09:41:12 +08:00
xiaoguangbin
e266148da1 fix:修复新beta的分析接口,增加对roiParams的处理 2024-08-07 17:24:37 +08:00
xiaoguangbin
cd3d19db70 fix:修复新beta的分析接口,增加对roiParams的处理 2024-08-07 11:56:08 +08:00
xiaoguangbin
9a7cdbe1ed fix:修复新beta 保存到数据库失败问题 2024-08-06 18:46:46 +08:00
nieziyan
979f24a10c feat:自建台站view log 2024-08-06 18:23:21 +08:00
nieziyan
4ddf2f2b46 fix:自建台站viewRRR 2024-08-06 09:16:53 +08:00
nieziyan
f214f9fc97 fix:自建台站viewRRR 2024-08-06 09:11:31 +08:00
nieziyan
b7ae380fb1 fix:自建台站saveToDB报错 2024-08-05 09:25:01 +08:00
nieziyan
219b644669 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-08-02 16:36:09 +08:00
xiaoguangbin
aef513794b fix:修复新beta 保存到数据库失败问题 2024-08-02 16:35:25 +08:00
nieziyan
bead8100e7 Merge remote-tracking branch 'origin/SelfStation' into SelfStation
# Conflicts:
#	jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/SelfStationServiceImpl.java
2024-08-02 15:43:42 +08:00
nieziyan
69e668a9a7 feat:自建台站报告 2024-08-02 15:37:30 +08:00
xiaoguangbin
441a4ee6f6 fix:修改 updateROI 更改其他谱失败问题 2024-08-01 19:02:58 +08:00
xiaoguangbin
8cac8a6099 feat:完善新beta savetodb接口 2024-08-01 17:34:33 +08:00
nieziyan
0aeb76d959 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-08-01 14:44:05 +08:00
nieziyan
ba17537b44 fix:betaEnergyData null 2024-08-01 14:43:57 +08:00
xiaoguangbin
135f4ebd21 fix: 新beta谱 savetodb接口修改返回结果 2024-08-01 11:04:41 +08:00
nieziyan
dc3375a5ab Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-08-01 10:41:40 +08:00
nieziyan
6f9e33e48b feat:自建台站saveToDB 2024-08-01 10:41:31 +08:00
xiaoguangbin
ddbb632492 fix: 新beta谱 savetodb接口修改返回结果 2024-07-31 18:54:54 +08:00
nieziyan
164e44d086 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-31 18:23:38 +08:00
nieziyan
b48cf5a991 feat:自建台站loadFromDB 2024-07-31 18:23:32 +08:00
xiaoguangbin
19c9bae348 feat:补充beta 分析部分接口 2024-07-31 17:29:39 +08:00
nieziyan
40e94299a7 fix:自建台站saveToDB 2024-07-31 10:38:20 +08:00
nieziyan
b19f5087ed Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-30 13:58:33 +08:00
nieziyan
6bb4cb67a1 fix:自建台站分析参数 2024-07-30 13:58:16 +08:00
xiaoguangbin
c6ea38f2d3 feat:viewBeta calibration补充gamma energy 转化 channel公式 2024-07-30 10:44:29 +08:00
xiaoguangbin
7c5ffb4cf2 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-29 19:34:44 +08:00
xiaoguangbin
f905f9951d feat:beta energy calibration通过b_energy数据重新拟合一条初始beta曲线 2024-07-29 19:34:25 +08:00
nieziyan
bc74b2e32e feat:自建台站SaveToDB 2024-07-29 19:30:17 +08:00
nieziyan
48fc1b30e5 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-26 19:16:00 +08:00
nieziyan
01ea4f8c63 feat:自建台站交互分析 2024-07-26 19:15:46 +08:00
xiaoguangbin
cf369218da fix: self:1.nuclideReview弹窗多个接口;2.解决分析之后 gamma三个calibration弹窗无数据问题 2024-07-26 10:49:18 +08:00
xiaoguangbin
0cd2e0f29c Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 17:06:44 +08:00
xiaoguangbin
c83aff08bd feat:selfStationController 增加 replotBaseLine、acceptBaseLine 接口 2024-07-25 17:06:23 +08:00
xiaoguangbin
da269b1da1 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 17:05:40 +08:00
xiaoguangbin
9726c51710 feat:selfStationController 增加 replotBaseLine、acceptBaseLine 接口 2024-07-25 17:05:14 +08:00
xiaoguangbin
71411c8d4c Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 14:35:52 +08:00
xiaoguangbin
511afb8677 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 14:35:13 +08:00
xiaoguangbin
50c70d7026 feat:selfStationController 增加 resetButton 接口 2024-07-25 14:34:44 +08:00
nieziyan
82ebe1009e Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 14:28:59 +08:00
nieziyan
2e0814fa14 feat:自建台站自动处理分析结果存库 2024-07-25 14:28:50 +08:00
xiaoguangbin
e11eee19f7 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-25 14:26:28 +08:00
xiaoguangbin
566657c339 fix:beta calibration table数据 2024-07-25 14:24:51 +08:00
xiaoguangbin
2e08948302 fix:如何初始时获取beta calibration table数据 2024-07-25 11:13:29 +08:00
xiaoguangbin
79063e235a Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-24 17:16:24 +08:00
xiaoguangbin
d64a0be200 fix:修改updateROI接口参数 2024-07-24 17:15:56 +08:00
xiaoguangbin
9f7295673d Revert "fix:修改updateROI接口参数"
This reverts commit aa99d7214b.
2024-07-24 17:13:16 +08:00
xiaoguangbin
aa99d7214b fix:修改updateROI接口参数 2024-07-24 17:12:44 +08:00
xiaoguangbin
73286710e0 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-24 16:47:04 +08:00
xiaoguangbin
1f94e14a70 fix:修改updateROI接口参数;2 增加/selfStation/getGammaGated接口 2024-07-24 16:46:44 +08:00
xiaoguangbin
48a03b6d6f fix:修改updateROI接口参数;2 增加/selfStation/getGammaGated接口 2024-07-24 16:46:30 +08:00
xiaoguangbin
f4aef9bdee Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-24 15:42:21 +08:00
nieziyan
970d4f3027 feat:自建台站谱解析 2024-07-23 16:49:11 +08:00
xiaoguangbin
8869735270 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-23 09:33:30 +08:00
nieziyan
dee89d28b5 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-23 09:17:06 +08:00
xiaoguangbin
1e830b0392 fix:修改updateROI接口参数 2024-07-23 08:45:32 +08:00
nieziyan
61ecc0ea5c Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-22 19:09:17 +08:00
nieziyan
95116338ad feat:自建台站谱解析类 2024-07-22 19:09:04 +08:00
xiaoguangbin
755f36d012 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-22 18:37:39 +08:00
xiaoguangbin
0af17e0601 fix:修改updateROI接口参数 2024-07-22 18:36:05 +08:00
nieziyan
7cd16a77c2 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-22 15:59:11 +08:00
nieziyan
7daebd98b8 feat:自建台站谱解析类 2024-07-22 15:59:04 +08:00
xiaoguangbin
567b64a34e fix:增加mdcInfoMap-C 2024-07-22 15:56:38 +08:00
xiaoguangbin
793d767313 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-22 14:10:01 +08:00
xiaoguangbin
cb74fb5a9e Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-19 17:15:00 +08:00
xiaoguangbin
2a6a38c286 fix:修改新beta谱的gamma reprocessing接口 2024-07-19 17:14:47 +08:00
nieziyan
108f2db587 feat:自建台站AUX表增加GPS信息 2024-07-19 16:11:10 +08:00
xiaoguangbin
90ecbfe99b Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-19 15:34:23 +08:00
nieziyan
55b14e66b6 feat:自建台站新增viewSpectrum接口 2024-07-19 11:21:32 +08:00
xiaoguangbin
fa79e380dd Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-19 09:44:11 +08:00
xiaoguangbin
f2d211b2b2 fix:beta energy calibration 中qc谱散点数据调整 2024-07-19 09:20:32 +08:00
nieziyan
5849612a3b feat:bgSpectrum数据 2024-07-18 19:43:26 +08:00
xiaoguangbin
3d97ffb539 fix:增加interactive弹窗内的接口 2024-07-18 18:45:05 +08:00
nieziyan
b5d4b23f3c feat:自建台站增加Configure接口 2024-07-18 18:16:59 +08:00
nieziyan
3c02c89ae5 feat:自建台站增加用户核素库配置接口 2024-07-18 09:06:49 +08:00
xiaoguangbin
16a1407216 fix:新beta 增加fitting接口 2024-07-17 14:33:04 +08:00
xiaoguangbin
143e1b1092 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-17 10:32:22 +08:00
xiaoguangbin
5b94121112 fix: 2024-07-17 10:31:58 +08:00
xiaoguangbin
5c0f09c616 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-07-17 10:28:59 +08:00
xiaoguangbin
03d92b7889 fix:1。增加qc文件;2.增加交互分析(gamma) 2024-07-17 09:53:43 +08:00
xiaoguangbin
9bbdd5eb5d fix:FileNameByStandardForm使用ftp改为本地目录 2024-07-17 09:49:56 +08:00
xiaoguangbin
277485ddda Merge remote-tracking branch 'origin/SelfStation' into SelfStation
# Conflicts:
#	jeecg-boot-base-core/src/main/java/org/jeecg/common/email/EmailServiceManager.java
2024-07-16 14:35:57 +08:00
xiaoguangbin
2e10465bfe fix:1.修改roi卡gamma数据代码,改为两个x点卡数据;
2.点击分析按钮根据卡出来的数据生成gammaPHD文件
2024-07-16 14:34:34 +08:00
xiaoguangbin
5a8f20362a fix:from file 读取ftp功能改为直接访问ftp文件夹目录获取文件 2024-07-16 14:30:36 +08:00
xiaoguangbin
c64079e1f1 Merge remote-tracking branch 'origin/noFtp-seflStation' into SelfStation
# Conflicts:
#	jeecg-boot-base-core/src/main/java/org/jeecg/common/email/EmailServiceManager.java
2024-07-16 12:02:26 +08:00
xiaoguangbin
f4b05e2da1 fix:修改ftp切换的目录 2024-07-16 11:55:10 +08:00
nieziyan
3f22b0edba fix:Bugs 2024-07-08 10:03:25 +08:00
xiaoguangbin
ebdf8d863a fix:增加海水系统和自建台站beta的系统类型 2024-06-26 15:42:08 +08:00
xiaoguangbin
80985a74d7 Merge remote-tracking branch 'refs/remotes/origin/SelfStation' into noFtp-seflStation
# Conflicts:
#	jeecg-boot-base-core/src/main/java/org/jeecg/common/constant/DictConstant.java
#	jeecg-boot-base-core/src/main/java/org/jeecg/common/email/EmailServiceManager.java
#	jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/controller/CalculateConcController.java
#	jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/redisStream/AnalysisConsumer.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/EmailParsingActuator.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/spectrum/AbstractSpectrumHandler.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/spectrum/SpectrumParsingActuator.java
#	jeecg-module-beta-gamma-analyser/src/main/java/org/jeecg/common/util/GammaFileUtil.java
#	jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/GammaServiceImpl.java
#	jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/SpectrumAnalysisServiceImpl.java
#	jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/SpectrumFileServiceImpl.java
#	jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/system/controller/LoginController.java
#	jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/system/service/impl/GardsSampleDataServiceImpl.java
2024-06-26 10:43:45 +08:00
xiaoguangbin
0a560452bf Merge remote-tracking branch 'refs/remotes/origin/sleepDownload' into noFtp-seflStation
# Conflicts:
#	jeecg-boot-base-core/src/main/java/org/jeecg/common/email/EmailServiceManager.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/EmailParsingActuator.java
2024-06-26 10:06:41 +08:00
xiaoguangbin
f6b963145f fix:增加catch中exception写入log日志 2024-06-25 11:03:09 +08:00
nieziyan
8b40646076 feat:Application异常结束退出 2024-06-19 16:33:55 +08:00
nieziyan
cf0751109d feat:添加IDC数据源控制访问 2024-06-18 14:52:44 +08:00
nieziyan
64a98bd4ea fix:邮件接收超时时间 2024-06-12 15:33:23 +08:00
nieziyan
f1410028fa fix:不删除saveFile下谱文件 2024-06-06 16:51:24 +08:00
nieziyan
d5dce1c3fc feat:探测器报警信息 2024-06-04 09:52:58 +08:00
nieziyan
e83c1d6199 feat:探测器报警信息 2024-06-04 09:47:58 +08:00
nieziyan
86968e383b fix:删除多余文件 2024-05-13 14:58:41 +08:00
qiaoqinzheng
9fffd2436c 自动处理模块模块同步代码 2024-05-13 14:14:01 +08:00
qiaoqinzheng
2407b65a06 自动处理模块下载邮件代码修改 2024-05-13 14:09:42 +08:00
qiaoqinzheng
6c5a0bf546 人工交互模块BetaDataFile实体类增加detectorId字段用于报警使用 2024-05-13 09:24:25 +08:00
qiaoqinzheng
caf47a58d5 人工交互模块增加判断如果不是正常谱提示异常信息内容 2024-05-10 16:12:26 +08:00
qiaoqinzheng
600c5235ec 自建台站分支同步代码 2024-04-30 11:51:54 +08:00
qiaoqinzheng
3a1567f853 自建台站分支初始化数据返回值关键字改为void 2024-04-26 11:25:27 +08:00
nieziyan
18b495d1d0 Merge remote-tracking branch 'origin/noFtp' into noFtp 2024-04-25 15:05:45 +08:00
nieziyan
6335a3f588 fix:修改FTP为本地文件 2024-04-24 09:34:59 +08:00
nieziyan
d5b18e57b5 fix:增加排序 2024-04-11 14:51:57 +08:00
nieziyan
14e64306b2 Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-04-10 19:10:14 +08:00
nieziyan
0c8019ad15 feat:修改是否对文件内容解码逻辑 2024-04-10 19:09:32 +08:00
qiaoqinzheng
d92d55befc 自动处理模块GPS谱流程代码修改 2024-04-10 12:40:14 +08:00
qiaoqinzheng
fc4623e584 自动处理模块GPS谱流程代码修改 2024-04-10 11:31:27 +08:00
qiaoqinzheng
8d3b380837 自动处理模块service配置类增加GPS基础数据相关service实体 2024-04-10 09:13:56 +08:00
nieziyan
eedcd67113 feat:报警编码内容替换 2024-04-09 18:19:37 +08:00
nieziyan
4c16d4527d feat:报警编码信息管理 2024-04-08 18:35:24 +08:00
nieziyan
2d840bcd8b feat:解码Base64邮件内容保存为可处理.eml文件 2024-04-03 16:46:34 +08:00
qiaoqinzheng
5c181d60b1 同步mdc分支代码 2024-03-21 10:29:47 +08:00
qiaoqinzheng
bde5eed237 同步mdc分支代码 2024-03-21 10:28:04 +08:00
qiaoqinzheng
1c34f3dde1 app端代码同步 2024-02-29 10:50:41 +08:00
qiaoqinzheng
8b9882842f 人工交互模块beta存储公式参数问题修改 2024-02-02 17:04:58 +08:00
qiaoqinzheng
19b0366ace 存储谱数据到数据库时,生成的临时日志,报告文件进行删除 2024-02-02 09:31:01 +08:00
qiaoqinzheng
b6bad77274 消息推送OPPO,VIVO增加厂商配置参数 2024-01-31 17:51:11 +08:00
qiaoqinzheng
c892a339e0 增加客户绑定的客户端id去重,避免同一个用户发送多条的情况 2024-01-31 16:00:28 +08:00
qiaoqinzheng
9e8935c9d4 新增推送通知基础配置类MyApiHelper
新增推送通知工具类PushAppUtil
增加在线,离线推送消息相关方法
消息推送根据报警规则组id,获取绑定用户id,根据用户id查询绑定的客户端id推送消息
新增表绑定用户以及客户端信息
app登陆增加新的redisKey存储当前用户名对应的token信息,在别处登陆时清除上一个登陆token退出用户登陆
新增接口用户在app端登陆时,新增或修改当前用户id绑定的客户端id
定时任务增加推送通知工具类声明
分析结果消费者代码增加推送通知工具类
2024-01-31 15:25:15 +08:00
nieziyan
9107cdf13e Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-01-30 11:52:16 +08:00
nieziyan
01eb8d22c2 fix:send message 2024-01-30 11:51:34 +08:00
qiaoqinzheng
412d7e74d9 拼接文件路径,在ftp目录路径及ftp文件夹路径间多拼接路径符号问题修改
同步mdc修改
2024-01-29 14:21:21 +08:00
qiaoqinzheng
6a65d9cdd6 上传文件重命名内容修改 2024-01-29 13:41:28 +08:00
nieziyan
7af7fafc86 Merge branch 'mdc' into SelfStation
# Conflicts:
#	jeecg-module-auto-process/src/main/java/org/jeecg/modules/spectrum/SpectrumServiceQuotes.java
#	jeecg-module-beta-gamma-analyser/src/main/java/org/jeecg/modules/mapper/GardsNuclLibMapper.java
#	jeecg-module-spectrum-analysis/src/main/java/org/jeecg/modules/service/impl/SpectrumAnalysisServiceImpl.java
#	jeecg-module-station-operation/src/main/java/org/jeecg/DataReceivingStatusManager.java
2024-01-26 17:00:07 +08:00
qiaoqinzheng
dac0736e72 查询统计核素信息接口增加对数据是inf,nan的数据赋值空值处理 2024-01-26 16:48:46 +08:00
qiaoqinzheng
c62b55913a 数据库加载增加判断analysisId条件 2024-01-26 15:27:10 +08:00
qiaoqinzheng
071e9690c6 自建台站新增initValue方法
自建台站新增暂时数据库加载数据方法
2024-01-26 15:21:34 +08:00
qiaoqinzheng
a730178204 新增加GPS谱数据的内容解析及保存 2024-01-26 10:39:59 +08:00
qiaoqinzheng
cf2fe9dd8e 自动处理错误谱文件修改名称方法内容修改 2024-01-26 10:38:55 +08:00
qiaoqinzheng
39348f16f3 自动处理文件名称重命名错误问题修改 2024-01-25 14:15:04 +08:00
qiaoqinzheng
8c5f85b499 查询统计核素方法新增标识判断是否已经存储过当前日期
查询统计核素方法返回内容移除全日期数据
2024-01-24 18:06:02 +08:00
qiaoqinzheng
e3e8a52344 台站运行管理台站接收状态线程台站id数组获取内容修改 2024-01-24 16:45:08 +08:00
qiaoqinzheng
a2ff824fc7 台站运行管理启动时增加查询所有用户最大缓存时间的方法
台站运行管理查询台站的运行状态接口根据用户设置的缓存时间进行结果切割返回
系统启动类新增加缓存台站id及台站id关联的探测器数组方法
台站运行管理数据状态线程向redis缓存过于频繁导致触发redis序列化错误问题修改
2024-01-24 14:12:14 +08:00
qiaoqinzheng
1aa68d4974 采集时间日期截取下标位置错误导致匹配失败问题修改 2024-01-23 19:42:56 +08:00
qiaoqinzheng
a6deb7c53f 新增获取时间范围内年月日小时的方法
统计横坐标根据时间范围内的年月日小时填充数据并回显
2024-01-23 19:24:23 +08:00
qiaoqinzheng
229d1980dd 台站运行管理初始化台站运行状态,台站运行效率新增过滤台站状态条件 2024-01-23 15:33:41 +08:00
qiaoqinzheng
f7677e56e2 同步mdc 2024-01-23 15:13:57 +08:00
qiaoqinzheng
35ac1ebf0c Merge remote-tracking branch 'origin/SelfStation' into SelfStation 2024-01-23 15:03:29 +08:00
qiaoqinzheng
5498e0e433 同步mdc 2024-01-23 15:03:21 +08:00
nieziyan
cc3c056bcf fix:findAutoPage增加参数sampleType 2024-01-23 14:20:45 +08:00
qiaoqinzheng
630bc4ee4f 探测器状态判断改为调用枚举类内容 2024-01-23 09:02:26 +08:00
qiaoqinzheng
d611bf1ff1 人工交互beta,gamma上传文件后删除本地文件操作移除 2024-01-23 08:55:08 +08:00
qiaoqinzheng
49dee87eed 同步mdc 2024-01-22 14:08:37 +08:00
qiaoqinzheng
d8e980fdb2 统计分析导出核素对比统计数据功能实现 2024-01-22 13:47:12 +08:00
qiaoqinzheng
680c263033 人工交互分析gamma部分baseline,lc,scac文件上传到ftp代码实现 2024-01-18 18:58:00 +08:00
qiaoqinzheng
90684089a1 人工交互存储gamma分析结果mdc数据如果已经存在数据需要删除对应的mdc结果后重新插入 2024-01-18 18:37:39 +08:00
qiaoqinzheng
df15a907e9 同步分支mdc 2024-01-18 17:50:52 +08:00
qiaoqinzheng
2f1f658d33 新增动态生成excel内容方法 2024-01-18 17:44:43 +08:00
qiaoqinzheng
b7c0553239 人工交互分析报告存放地址改为Rrr文件夹与Arr区分开 2024-01-18 14:06:19 +08:00
qiaoqinzheng
0d4deaf403 人工交互分析beta日志文件没有创建导致无法上传的问题修改 2024-01-18 11:43:23 +08:00
qiaoqinzheng
e159740d76 人工交互模块增加beta部分日志文件的存在情况判断,上传后的日志文件不进行删除 2024-01-18 10:35:56 +08:00
qiaoqinzheng
82713a8795 自建台站新增实体类存储公用的数据内容
自建台站返回内容增加det相关数据
web模块增加查询系统类型对应的配置核素信息
web模块增加查询系统类型对应的核素统计信息
人工交互模块增加beta部分日志文件的存在情况判断,上传后的日志文件不进行删除
2024-01-18 10:33:07 +08:00
qiaoqinzheng
ee2dd272d1 自建台站折线图ROI范围计算结果取值下标计算公式参数问题修改 2024-01-17 16:24:17 +08:00
qiaoqinzheng
9f8e79226e 台站运行管理查询台站,核设施列表排序问题修改,台站内容放置在核设施前并分别排序 2024-01-17 14:02:09 +08:00
qiaoqinzheng
1452be8f31 MDC分析结果存储改为字符串格式与数据库格式匹配 2024-01-16 19:01:08 +08:00
qiaoqinzheng
e33fc8df83 自建台站修改ROI返回接口改为put请求
自建台站实体类去掉多余参数
2024-01-16 17:08:50 +08:00
qiaoqinzheng
d1de32433e 自建台站已经加载过的数据再次加载页面数据丢失问题修改
人工交互beta保存日志路径,报告路径sql代码
2024-01-16 09:35:30 +08:00
qiaoqinzheng
eb3605d9e8 名称格式化文件增加beta使用的名称格式化方法 2024-01-15 19:32:39 +08:00
qiaoqinzheng
55f9cd49e1 人工交互beta,gamma存储并上传日志,报告文件 2024-01-15 19:30:07 +08:00
qiaoqinzheng
76acc20a7d 新增加自建台站系统类型判断,根据sample文件名称可以通过系统类型查询到关联的det文件类型
新增加查询台站运行轨迹方法
2024-01-15 19:23:43 +08:00
qiaoqinzheng
84d6c4a5a2 自动处理SOH,MET文件存储内容中如果是占位数据-999999存储时数据内容超出精度范围问题修改 2024-01-15 10:44:03 +08:00
qiaoqinzheng
16f59f0273 人工交互,自动处理启动时查询全核素信息方法修改 2024-01-12 15:56:16 +08:00
qiaoqinzheng
63576edde8 探测器新增代码同步 2024-01-11 18:26:12 +08:00
qiaoqinzheng
03955c3691 自建台站散点图G,B横纵坐标取值修改 2024-01-11 09:34:58 +08:00
qiaoqinzheng
8faa97d8f1 gamma分析部分生成报告内容中关于version描述区分颗粒物和气体
增加人工交互,自动处理启动时加载全核素信息方法
人工交互,自动处理启动时加载全核素信息方法调用接口类方法修改
2024-01-11 09:00:48 +08:00
qiaoqinzheng
3c4aae44e0 散点图B,G位置颠倒问题修改 2024-01-10 18:30:24 +08:00
qiaoqinzheng
ee3a04af2f 新增删除自建台站缓存接口 2024-01-10 15:47:15 +08:00
qiaoqinzheng
941c6c0685 ftp路径前多拼接了/导致文件找不到 2024-01-10 15:32:16 +08:00
qiaoqinzheng
cadbdb3ba9 人工交互新增自建台站相关实体类对象
人工交互新增自建台站管理代码
人工交互新增自建台站数据缓存对象
人工交互新增自建台站工具类
2024-01-10 11:40:50 +08:00
184 changed files with 16548 additions and 254 deletions

View File

@ -13,4 +13,7 @@ public interface DictConstant {
String NOBLE_GAS_BETAGAMMA = "Noble Gas Beta-Gamma";
String NOBLE_GAS_HPGE = "Noble Gas HPGe";
// todo 补充
String ALERT_SYSTEM_CODE = "Noble Gas HPGe";
}

View File

@ -41,4 +41,6 @@ public interface RedisConstant {
String EMAIL_MSG_ID = "email_msg_id";
String UNDEAL_FILE = "Undeal:";
String SELF_PARAMETER = "self_parameter";
}

View File

@ -0,0 +1,8 @@
package org.jeecg.common.constant;
public class SelfStationConstant {
public static final String ROI1 = "ROI1";
public static final String ROI2 = "ROI2";
public static final String ROI3 = "ROI3";
public static final String ROI4 = "ROI4";
}

View File

@ -126,4 +126,8 @@ public class SymbolConstant {
public static final String LINE = "\n";
public static final String AT = "@";
public static final String VERTICAL = "|";
public static final char VERTICAL_CHAR = '|';
}

View File

@ -1,8 +1,6 @@
package org.jeecg.common.email;
import cn.hutool.core.util.ArrayUtil;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.RandomUtil;
import cn.hutool.core.util.StrUtil;
import com.google.common.collect.Lists;
import com.sun.mail.imap.IMAPStore;
@ -32,7 +30,6 @@ import java.io.*;
import java.net.InetSocketAddress;
import java.net.Socket;
import java.util.*;
import java.util.concurrent.*;
import java.util.concurrent.atomic.AtomicReference;
import java.util.concurrent.locks.ReentrantLock;
import java.util.stream.Collectors;
@ -127,7 +124,7 @@ public class EmailServiceManager {
/**
* 接收邮件
*/
public Message[] receiveMail() throws MessagingException {
public Message[] receiveMail() throws Exception {
String status = EmailLogManager.STATUS_SUCCESS;
try{
//配置邮件服务属性
@ -135,6 +132,8 @@ public class EmailServiceManager {
properties.put("mail.store.protocol", "imap");
properties.put("mail.imap.host", email.getEmailServerAddress());
properties.put("mail.imap.port",email.getPort());
properties.put("mail.imap.connectiontimeout", "3000"); // 设置连接超时时间为3秒
properties.put("mail.imap.timeout", "3000"); // 设置读取超时时间为3秒
if (email.getIsQiye() == 1) {
properties.put("mail.imap.ssl.enable", "true");
} else {
@ -177,6 +176,7 @@ public class EmailServiceManager {
return o1.getReceivedDate().compareTo(o2.getReceivedDate());
} catch (MessagingException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
}
return 0;
});
@ -186,7 +186,7 @@ public class EmailServiceManager {
return Arrays.copyOfRange(messages,0,this.receiveNum-1);
}
}
} catch (MessagingException e){
} catch (Exception e){
status = EmailLogManager.STATUS_ERROR;
log.error("Email connection is abnormal, account is {}, service is {},the reason is {}.",email.getName(),email.getEmailServerAddress(),e.getMessage());
throw e;
@ -727,6 +727,7 @@ public class EmailServiceManager {
status = EmailLogManager.STATUS_ERROR;
log.error("Email deletion failed, the subject of the email is :{}, the reason is :{}.",subject,e.getMessage());
e.printStackTrace();
log.error(e.getMessage(), e);
}finally {
EmailLogEvent removeEvent = new EmailLogEvent(batchesCounter,Thread.currentThread().getId(),EmailLogManager.GS_TYPE_GET,status,EmailLogManager.DELETEID,subject,DateUtils.formatDate(receivedDate,"yyyy-MM-dd HH:mm:ss:SSS"));
EmailLogManager.getInstance().offer(Thread.currentThread().getId(),removeEvent);
@ -748,7 +749,7 @@ public class EmailServiceManager {
if(null != store){
store.close();
}
log.info("EmailServiceManage资源关闭完成.");
log.info(Thread.currentThread().getName() + ",EmailServiceManage资源关闭完成.");
// for(String messageId : messageIds){
// String key = RedisConstant.EMAIL_MSG_ID+StringConstant.COLON+messageId;
// redisUtil.del(key);
@ -756,6 +757,7 @@ public class EmailServiceManager {
} catch (MessagingException e) {
log.error("Email closure failed, email address is: {}, reason is: {}",email.getUsername(),e.getMessage());
e.printStackTrace();
log.error(e.getMessage(), e);
}
}

View File

@ -0,0 +1,99 @@
package org.jeecg.common.parameter;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import org.jeecg.common.constant.RedisConstant;
import org.jeecg.common.properties.ParameterProperties;
import org.jeecg.common.util.RedisUtil;
import org.jeecg.modules.entity.vo.NuclideLine;
import org.jeecg.modules.entity.vo.SelfParameter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.w3c.dom.*;
import org.xml.sax.SAXException;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import java.io.File;
import java.io.IOException;
import java.util.Objects;
@Configuration
public class SelfParameterInit {
@Autowired
private ParameterProperties parameterProperties;
@Autowired
private RedisUtil redisUtil;
@Bean
public void readSelfMDCParameter() {
//配置文件路径
String filePath = parameterProperties.getFilePath()+ File.separator + parameterProperties.getSelfParameterFile();
SelfParameter selfParameter = new SelfParameter();
try {
//创建一个文档解析器工厂
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
//创建文档解析器
DocumentBuilder documentBuilder = factory.newDocumentBuilder();
//读取xml文件生成一个文档
Document document = documentBuilder.parse(filePath);
if (Objects.nonNull(document)){
//获取文档的根元素
Element element = document.getDocumentElement();
//获取根元素的子节点
NodeList docChildNodes = element.getChildNodes();
//判断文件内的节点是否大于0
if (Objects.nonNull(docChildNodes) && docChildNodes.getLength() > 0) {
//遍历文件节点读取内容
for (int i=0; i<docChildNodes.getLength(); i++) {
//获取节点信息
Node node = docChildNodes.item(i);
//判断节点名称是否是 P
if (node.getNodeName().equalsIgnoreCase("nuclide")) {
//获取节点下的子节点信息
NodeList childNodes = node.getChildNodes();
//如果子节点不为空
if (Objects.nonNull(childNodes) && childNodes.getLength() > 0) {
//遍历子节点信息 将核素信息封存到缓存中
for (int j=0; j<childNodes.getLength(); j++) {
Node childNode = childNodes.item(j);
//获取节点属性信息
NamedNodeMap attributes = childNode.getAttributes();
//判断节点属性信息是否为空
if (Objects.nonNull(attributes)) {
NuclideLine nuclide = new NuclideLine();
//遍历属性信息
for (int k=0; k<attributes.getLength(); k++) {
//根据顺序读取属性
Node attribute = attributes.item(k);
if (attribute.getNodeName().equalsIgnoreCase("nuclide_name")) {
nuclide.setName(attribute.getNodeValue());
} else if (attribute.getNodeName().equalsIgnoreCase("yield")) {
nuclide.setYield(Double.valueOf(attribute.getNodeValue()));
} else if (attribute.getNodeName().equalsIgnoreCase("energy")) {
nuclide.setEnergy(Double.valueOf(attribute.getNodeValue()));
}
}
if (StrUtil.isNotBlank(nuclide.getName()) && Objects.nonNull(nuclide.getEnergy())) {
selfParameter.getNuclideMap().put(nuclide.getName(), nuclide);
}
}
}
}
}
}
}
}
redisUtil.set(RedisConstant.SELF_PARAMETER, selfParameter);
} catch (ParserConfigurationException e) {
throw new RuntimeException(e);
} catch (SAXException e) {
throw new RuntimeException(e);
} catch (IOException e) {
throw new RuntimeException(e);
}
}
}

View File

@ -26,4 +26,12 @@ public class ParameterProperties implements Serializable {
*/
private String dbPath;
private String SelfParameterFile;
private String MDCParameterFile;
private String SystemManagerFile;
private String parameterFile;
}

View File

@ -805,4 +805,51 @@ public class DateUtils extends PropertyEditorSupport {
return days;
}
/**
* 获取开始时间和结束时间之间的全部小时信息
* @param beginDay
* @param endDay
* @return
*/
public static List<String> getAllDayTime(String beginDay, String endDay){
List<String> dayTimes = new ArrayList<>();
try {
//开始日期
Calendar begin = Calendar.getInstance();
begin.setTime(DateUtils.parseDate(beginDay, "yyyy-MM-dd"));
//将开始日期的24个小时放入集合中
for (int i=0; i< 24; i++) {
String dayTime = beginDay;
if (i < 10) {
dayTime+=" 0"+i;
} else {
dayTime+=" "+i;
}
dayTime+=":00:00";
dayTimes.add(dayTime);
}
//结束日期
Calendar end = Calendar.getInstance();
end.setTime(DateUtils.parseDate(endDay, "yyyy-MM-dd"));
//判断 如果结束日期的时间在开始日期的时间之后
while(end.getTime().after(begin.getTime())){
//开始日期需要+1天
begin.add(Calendar.DAY_OF_MONTH, 1);
for (int i=0; i< 24; i++) {
String dayTime = DateUtils.formatDate(begin.getTime(),"yyyy-MM-dd");
if (i < 10) {
dayTime+=" 0"+i;
} else {
dayTime+=" "+i;
}
dayTime+=":00:00";
dayTimes.add(dayTime);
}
}
} catch (ParseException e) {
throw new RuntimeException(e);
}
return dayTimes;
}
}

View File

@ -13,6 +13,7 @@ import org.apache.poi.ss.usermodel.Workbook;
import org.jeecgframework.poi.excel.ExcelExportUtil;
import org.jeecgframework.poi.excel.entity.ExportParams;
import org.jeecgframework.poi.excel.entity.TemplateExportParams;
import org.jeecgframework.poi.excel.entity.enmus.ExcelType;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.DefaultResourceLoader;
import org.springframework.core.io.Resource;
@ -104,6 +105,29 @@ public class ExportUtil {
}
}
public static <T> void exportXls(HttpServletResponse response, List<Map<String, Object>> dataList, String fileName){
Workbook workbook = null;
OutputStream outputStream = null;
try {
// 设置文件名Excel类型(xls|xlsx)
outputStream = ExportUtil.xls(response,fileName);
workbook = ExcelExportUtil.
exportExcel(dataList, ExcelType.HSSF);
workbook.write(outputStream);
} catch (IOException e) {
e.printStackTrace();
}finally {
try {
if (ObjectUtil.isNotNull(outputStream))
outputStream.close();
if (ObjectUtil.isNotNull(workbook))
workbook.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
public static <T> void exportXls(HttpServletResponse response, Class<T> target, List<T> data){
exportXls(response, target, data, "file.xls");
}

View File

@ -74,6 +74,27 @@ public class FTPUtil {
return this.ftpRootPath;
}
public static void main(String[] args) {
try {
FTPClient ftp = new FTPClient();
//连接
ftp.connect("172.21.170.122", 21);
//登录
ftp.login("rmsops", "cnndc010");
// 切换为本地被动模式可以解决FTP上传后文件为空的问题但需要服务器将FTP服务添加至防火墙白名单
ftp.enterLocalPassiveMode();
//切换工作路径
ftp.changeWorkingDirectory("/SpectrumFile/admin");
//判断是否连接成功
int reply = ftp.getReplyCode();
if (!FTPReply.isPositiveCompletion(reply)) {
ftp.disconnect();
System.out.printf(reply+"");
}
} catch (IOException e) {
throw new RuntimeException(e);
}
}
/**
* 登录ftp
* @return
@ -89,7 +110,7 @@ public class FTPUtil {
// 切换为本地被动模式可以解决FTP上传后文件为空的问题但需要服务器将FTP服务添加至防火墙白名单
ftp.enterLocalPassiveMode();
//切换工作路径
ftp.changeWorkingDirectory(ftpRootPath);
ftp.changeWorkingDirectory("/");
//判断是否连接成功
int reply = ftp.getReplyCode();
if (!FTPReply.isPositiveCompletion(reply)) {

View File

@ -1,9 +1,12 @@
package org.jeecg.common.util;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
import org.jeecg.common.properties.SpectrumPathProperties;
import org.jeecg.modules.base.enums.DataType;
import org.jeecg.modules.base.enums.SystemType;
import org.jeecg.modules.entity.vo.PHDFile;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import java.math.BigDecimal;
@ -18,21 +21,24 @@ import java.util.Map;
@Component
public class NameStandUtil {
@Autowired
private SpectrumPathProperties pathProperties;
public String GetSysTemSubdir(String systemType) {
StringBuffer path = new StringBuffer();
String path = null;
Map<String, String> pathMap = pathProperties.getFilePathMap();
if(systemType.contains(SystemType.BETA.getType())) {
path.append("Spectrum");
path.append(StringPool.SLASH+"Xenon");
path.append(StringPool.SLASH+"Sauna");
path = pathMap.getOrDefault(SystemType.BETA.getType(), "Spectrum/Xenon/Sauna");
} else if(systemType.contains(SystemType.GAMMA.getType())) {
path.append("Spectrum");
path.append(StringPool.SLASH+"Xenon");
path.append(StringPool.SLASH+"Spalax");
path = pathMap.getOrDefault(SystemType.GAMMA.getType(), "Spectrum/Xenon/Spalax");
} else if(systemType.contains(SystemType.PARTICULATE.getType())) {
path.append("Spectrum");
path.append(StringPool.SLASH+"Particulates");
path = pathMap.getOrDefault(SystemType.PARTICULATE.getType(), "Spectrum/Particulates");
} else if(systemType.contains(SystemType.WATER.getType())) {
path = pathMap.getOrDefault(SystemType.WATER.getType(), "Spectrum/Water");
} else if (systemType.contains(SystemType.SELFSTATION.getType())) {
path = pathMap.getOrDefault(SystemType.SELFSTATION.getType(), "Spectrum/Xenon/Self");
}
return path.toString();
return path;
}
public String GetDateTypeSubdir(String dataType){
@ -81,14 +87,15 @@ public class NameStandUtil {
public Map<String, String> NameStandard(String dataType, String spectrumQuantity, Double acqusitionLiveTime, String sampleFileName, String measurementId) {
String suffix = GetSuffix(dataType, spectrumQuantity,String.valueOf(acqusitionLiveTime));
Map<String, String> fileNames = NameStandardByName(sampleFileName, measurementId,suffix);
return fileNames;
return NameStandardByName(sampleFileName, measurementId,suffix);
}
public Map<String, String> NameStandard(PHDFile fileAnlyse) {
String suffix = GetSuffix(fileAnlyse.getMsgInfo().getData_type(), fileAnlyse.getHeader().getSpectrum_quantity(),String.valueOf(fileAnlyse.getAcq().getAcquisition_live_time()));
Map<String, String> fileNames = NameStandardByName(fileAnlyse.getFilename(), fileAnlyse.getHeader().getMeasurement_id(),suffix);
return fileNames;
String suffix = GetSuffix(fileAnlyse.getMsgInfo().getData_type(),
fileAnlyse.getHeader().getSpectrum_quantity(),
String.valueOf(fileAnlyse.getAcq().getAcquisition_live_time()),
fileAnlyse.getRoiSuffix());
return NameStandardByName(fileAnlyse.getFilename(), fileAnlyse.getHeader().getMeasurement_id(),suffix);
}
public String GetSuffix(String dataType, String Fulltype, String LT) {
@ -114,6 +121,33 @@ public class NameStandUtil {
return rData;
}
public String GetSuffix(String dataType, String Fulltype, String LT, String roiSuffix) {
String rData = "";
DecimalFormat df = new DecimalFormat("#.##########");
//AUX09_003-20151226_1855 _S_FULL_40184.8.PHD
//将acquisition_live_time保留六位有效数字 如果保留一位小数后小数点后的值是0则四舍五入保留整数否则按正常条件四舍五入保留小数位
String numberCal = NumberFormatUtil.numberCal(LT);
numberCal = df.format(Double.valueOf(numberCal));
// 谱类型增加 SPHDF SPHDP
if(dataType.contains(DataType.SAMPLEPHD.getType()) ||
dataType.contains(DataType.SPHDF.getType()) ||
dataType.contains(DataType.SPHDP.getType())) {
rData = StrUtil.isBlank(roiSuffix) ? "_S_"+Fulltype+"_"+numberCal+".PHD"
: "_S_"+Fulltype+"_"+numberCal+roiSuffix+".PHD";
} else if(dataType.contains(DataType.GASBKPHD.getType())) {
rData = StrUtil.isBlank(roiSuffix) ? "_G_"+Fulltype+"_"+numberCal+".PHD"
: "_G_"+Fulltype+"_"+numberCal+roiSuffix+".PHD";
} else if(dataType.contains(DataType.DETBKPHD.getType())) {
rData = StrUtil.isBlank(roiSuffix) ? "_D_"+Fulltype+"_"+numberCal+".PHD"
: "_D_"+Fulltype+"_"+numberCal+roiSuffix+".PHD";
} else if(dataType.contains(DataType.QCPHD.getType())) {
rData = StrUtil.isBlank(roiSuffix) ? "_Q_"+Fulltype+"_"+numberCal+".PHD"
: "_Q_"+Fulltype+"_"+numberCal+roiSuffix+".PHD";
}
return rData;
}
public Map<String, String> NameStandardByName(String fileName, String dateTimeFormat, String suffix) {
Map<String, String> map = new HashMap<>();
String StandardFileName="";

View File

@ -0,0 +1,12 @@
package org.jeecg.modules.base.bizVo;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.jeecg.common.api.QueryRequest;
@Data
public class AlertSystemVo extends QueryRequest {
private String code;
private String content;
}

View File

@ -0,0 +1,12 @@
package org.jeecg.modules.base.dto;
import lombok.Data;
@Data
public class RoiDto {
private Integer roiNum;
private String phdPath;
}

View File

@ -0,0 +1,35 @@
package org.jeecg.modules.base.entity.configuration;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName("CONFIGURATION.GARDS_ALERT_SYSTEM")
public class GardsAlertSystem implements Serializable {
@TableId(type = IdType.ASSIGN_ID)
private String id;
private String type;
private String code;
private String content;
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date moddate;
@TableField(exist = false)
private String typeStr;
public GardsAlertSystem(){ moddate = new Date(); }
}

View File

@ -97,4 +97,10 @@ public class GardsSampleAux implements Serializable {
*/
@TableField(value = "XE_COLLECTION_YIED_UNCER")
private Double xeCollectionYiedUncer;
@TableField("LON")
private Double lon;
@TableField("LAT")
private Double lat;
}

View File

@ -0,0 +1,51 @@
package org.jeecg.modules.base.entity.original;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName("ORIGINAL.SAMPLE_WATER_RESULT")
public class SampleWaterResult implements Serializable {
@TableField(value = "SAMPLE_RESULT_ID")
private Integer sampleResultId;
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "NUCLIDE_NAME")
private String nuclideName;
@TableField(value = "ENERGY")
private Double energy;
@TableField(value = "CSC_RATIO")
private Double cscRatio;
@TableField(value = "HALF_LIFE")
private Double halfLife;
@TableField(value = "MDA")
private Double mda;
@TableField(value = "ACTIVITY")
private Double activity;
@TableField(value = "SPEC_ACTIVITY")
private Double specActivity;
@TableField(value = "NID_FLAG")
private Integer nidFlag;
@TableField(value = "MODDATE")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date moddate;
}

View File

@ -0,0 +1,48 @@
package org.jeecg.modules.base.entity.rnauto;
import java.io.Serializable;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
@Data
@TableName("RNAUTO.GARDS_ANALYSIS_ROI")
@Accessors(chain = true)
public class GardsAnalysisRoi {
@TableField("IDANALYSIS")
private Integer idAnalysis;
private Integer sampleId;
private Integer roiId;
private Integer roiNum;
private Double minX;
private Double maxX;
private Double minY;
private Double maxY;
private String phdPath;
private String baselinePath;
private String lcPath;
private String scacPath;
private String logPath;
private String reportPath;
}

View File

@ -0,0 +1,74 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储数据分析过程中能量分辨率和效率刻度实际使用的刻度点数据
*/
@Data
@TableName("RNAUTO.GARDS_CALIBRATION_PAIRS_ROI")
public class GardsCalibrationPairsRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
private Integer roiId;
/**
* Ggamma探测器的数据#g_Bbeta探测器的数据,#b_
*/
@TableField(value = "SAMPLE_TYPE")
private String sampleType;
/**
* energy能量刻度
* efficiency效率刻度
* Resolution分辨率刻度
*/
@TableField(value = "CALTYPE")
private String caltype;
/**
* PHD代表数据来自PHD文件External代表数据来自外部如刻度工具其它文件等
*/
@TableField(value = "INPUT")
private String input;
/**
* 刻度点ID号
*/
@TableField(value = "IDCALPOINT")
private Integer idCalPoint;
@TableField(value = "XVALUE")
private Double xValue;
@TableField(value = "YVALUE")
private Double yValue;
@TableField(value = "DECAY_MODE")
private String decayMode;
/**
* y值不确定度
*/
@TableField(value = "UNCYVALUE")
private Double uncYValue;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
}

View File

@ -0,0 +1,119 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储数据分析过程中能量分辨率和效率刻度的拟合结果
*/
@Data
@TableName("RNAUTO.GARDS_CALIBRATION_ROI")
public class GardsCalibrationRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* Ggamma探测器的数据#g_Bbeta探测器的数据,#b_
*/
@TableField(value = "SAMPLE_TYPE")
private String sampleType;
/**
* energy能量刻度
* efficiency效率刻度
* Resolution分辨率刻度
*/
@TableField(value = "CALTYPE")
private String calType;
/**
* 拟合方程ID号统一定义
*/
@TableField(value = "FUNCTION")
private Integer function;
/**
* 拟合方程描述
*/
@TableField(value = "FUNCTIONDEF")
private String functionDef;
/**
* 拟合的起始值
*/
@TableField(value = "STARTOFRANGE")
private Integer startOfRange;
/**
* 拟合的结束值
*/
@TableField(value = "ENDOFRANGE")
private Integer endOfRange;
/**
* 拟合系数1
*/
@TableField(value = "COEFF1")
private Double coeff1;
/**
* 拟合系数2
*/
@TableField(value = "COEFF2")
private Double coeff2;
/**
* 拟合系数3
*/
@TableField(value = "COEFF3")
private Double coeff3;
/**
* 拟合系数4
*/
@TableField(value = "COEFF4")
private Double coeff4;
/**
* 拟合系数5
*/
@TableField(value = "COEFF5")
private Double coeff5;
/**
* 拟合系数6
*/
@TableField(value = "COEFF6")
private Double coeff6;
/**
* 拟合系数7
*/
@TableField(value = "COEFF7")
private Double coeff7;
/**
* 拟合系数8
*/
@TableField(value = "COEFF8")
private Double coeff8;
/**
* 拟合系数9
*/
@TableField(value = "COEFF9")
private Double coeff9;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
@TableField(value = "COEFF_STRING")
private String coeffString;
}

View File

@ -0,0 +1,48 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName("RNAUTO.GARDS_MDC_ROI")
public class GardsMDCRoi implements Serializable {
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "NUCLIDENAME")
private String nuclideName;
@TableField(value = "ENERGY")
private Double energy;
@TableField(value = "YIELD")
private Double yield;
@TableField(value = "EFFICIENCY")
private Double efficiency;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "MDC_ERR")
private String mdcErr;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
}

View File

@ -0,0 +1,122 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱中识别到的核素计算结果
*/
@Data
@TableName("RNAUTO.GARDS_NUCL_IDED_ROI")
public class GardsNuclIdedRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* 核素名称
*/
@TableField(value = "NUCLIDENAME")
private String nuclideName;
/**
* 核素类型
*/
@TableField(value = "TYPE")
private String type;
/**
* 核素半衰期
*/
@TableField(value = "HALFLIFE")
private String halflife;
/**
* 平均活度值
*/
@TableField(value = "AVE_ACTIV")
private String aveActiv;
/**
* 平均活度值不确定度
*/
@TableField(value = "AVE_ACTIV_ERR")
private Double aveActivErr;
/**
* 主射线活度值
*/
@TableField(value = "ACTIV_KEY")
private Double activKey;
/**
* 主射线活度值不确定度
*/
@TableField(value = "ACTIV_KEY_ERR")
private Double activKeyErr;
/**
* 核素的最小可探测活度
*/
@TableField(value = "MDA")
private String mda;
/**
* 核素的最小可探测活度不确定度
*/
@TableField(value = "MDA_ERR")
private Double mdaErr;
/**
* 核素识别标志
*/
@TableField(value = "NID_FLAG")
private Integer nidFlag;
@TableField(value = "ACTIV_DECAY")
private Double activDecay;
@TableField(value = "ACTIV_DECAY_ERR")
private Double activDecayErr;
/**
* 符合相加校正因子无设为1
*/
@TableField(value = "CSC_RATIO")
private Double cscRatio;
/**
* 符合相加校正因子不确定度无设为0
*/
@TableField(value = "CSC_RATIO_ERR")
private Double cscRatioErr;
/**
* 活度是否经过符合相加校正
*/
@TableField(value = "CSC_MOD_FLAG")
private Integer cscModFlag;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "CONCENTRATION")
private String concentration;
@TableField(value = "KEY_ENERGY")
private String keyEnergy;
@TableField(value = "KEY_YIELD")
private String keyYield;
}

View File

@ -0,0 +1,126 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱中识别到的峰计算结果
*/
@Data
@TableName("RNAUTO.GARDS_NUCL_LINES_IDED_ROI")
public class GardsNuclLinesIdedRoi implements Serializable {
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* 峰序号
*/
@TableField(value = "IDPEAK")
private Integer idPeak;
/**
* 核素名称
*/
@TableField(value = "NUCLIDENAME")
private String nuclideName;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
/**
* 核素库中核素对应峰的能量keV
*/
@TableField(value = "ENERGY")
private Double energy;
/**
* 核素库中核素对应峰的能量不确定度keV
*/
@TableField(value = "UNCENERGY")
private Double uncEnergy;
/**
* 核素库中核素对应峰的发射几率
*/
@TableField(value = "ABUNDANCE")
private Double abundance;
/**
* 核素库中核素对应峰的发射几率不确定度
*/
@TableField(value = "UNCABUNDANCE")
private Double uncAbundance;
/**
* 利用该峰计算得到的活度
*/
@TableField(value = "ACTIVITY")
private String activity;
/**
* 利用该峰计算得到的活度不确定度
*/
@TableField(value = "UNCACTIVITY")
private Double uncActivity;
/**
* 该峰处的探测效率
*/
@TableField(value = "EFFIC")
private Double effic;
/**
* 该峰处的探测效率不确定度
*/
@TableField(value = "UNEFFIC")
private Double unEffic;
/**
* 利用该峰计算得到的最小可探测活度
*/
@TableField(value = "MDA")
private Double mda;
/**
* 主射线标识01
*/
@TableField(value = "KEY_FLAG")
private Double keyFlag;
/**
* 符合相加校正因子无设为1
*/
@TableField(value = "CSC_RATIO")
private Double cscRatio;
/**
* 符合相加校正因子不确定度无设为0
*/
@TableField(value = "CSC_RATIO_ERR")
private Double cscRatioErr;
/**
* 活度是否经过符合相加校正
*/
@TableField(value = "CSC_MOD_FLAG")
private Double cscModFlag;
@TableField(value = "NUCLIDEFULLNAME")
private String nuclidefullname;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "CONCENTRATION")
private String concentration;
}

View File

@ -0,0 +1,166 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱的寻峰结果
*/
@Data
@TableName("RNAUTO.GARDS_PEAKS_ROI")
public class GardsPeaksRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 峰序号
*/
@TableField(value = "IDPEAK")
private Integer idPeak;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
/**
* 峰中心道道址
*/
@TableField(value = "CENTROIDCHANNEL")
private Double centroidChannel;
/**
* 峰中心道不确定度道址
*/
@TableField(value = "UNCCENTROIDCHANNEL")
private Double uncCentroidChannel;
/**
* 峰中心道能量keV
*/
@TableField(value = "ENERGY")
private Double energy;
/**
* 峰中心道能量不确定度keV
*/
@TableField(value = "UNCENERGY")
private Double uncEnergy;
/**
* 峰面积计数已扣除基线面积但未扣除空白样品计数和探测器本底计数
*/
@TableField(value = "AREA")
private Double area;
/**
* 峰面积不确定度计数
*/
@TableField(value = "UNCAREA")
private Double uncArea;
/**
* 峰的净计数率1/s=峰面积/活时间
*/
@TableField(value = "NETCOUNTRATE")
private Double netCountRate;
/**
* 峰的净计数率的不确定度1/s
*/
@TableField(value = "UNCNETCOUNTRATE")
private Double uncNetCountRate;
/**
* 测量系统在峰能量处的绝对效率
*/
@TableField(value = "EFFICIENCY")
private Double efficiency;
/**
* 测量系统在峰能量处的绝对效率的不确定度
*/
@TableField(value = "UNCEFFICIENCY")
private Double uncefficiency;
/**
* 峰的半高宽
*/
@TableField(value = "FWHM")
private Double fwhm;
/**
* 峰的十分之一高宽
*/
@TableField(value = "FWTM")
private Double fwtm;
/**
* 峰的重要性因子
*/
@TableField(value = "SIGNIFICANCE")
private Double significance;
/**
* 峰的可探测线Lc
*/
@TableField(value = "LC")
private Double lc;
/**
* 峰的感兴趣区的起始道
*/
@TableField(value = "ROISTART")
private Double roiStart;
/**
* 峰的感兴趣区的结束道
*/
@TableField(value = "ROIEND")
private Double roiEnd;
@TableField(value = "MULTIINDEX")
private Double mulitiIndex;
@TableField(value = "TAIL")
private Double tail;
@TableField(value = "TAILALPHA")
private Double tailAlpha;
@TableField(value = "UPPERTAIL")
private Double upperTail;
@TableField(value = "UPPERTAILALPHA")
private Double upperTailAlpha;
@TableField(value = "BWWIDTHCHAN")
private Double bwwidthchan;
@TableField(value = "RECOILDELTACHAN")
private Double recoildeltachan;
@TableField(value = "STEPRAIO")
private Double stepraio;
@TableField(value = "LD")
private Double ld;
@TableField(value = "SENSITIVITY")
private Double sensitivity;
@TableField(value = "BACKGROUNDAREA")
private Double backgroundarea;
@TableField(value = "MEANBACKCOUNT")
private Double meanbackcount;
@TableField(value = "RECOILBETACHAN")
private Double recoilbetachan;
@TableField(value = "PEAKCOMMENTS")
private String peakcomments;
}

View File

@ -0,0 +1,42 @@
package org.jeecg.modules.base.entity.rnauto;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName(value = "RNAUTO.GARDS_QC_CHECK_ROI")
public class GardsQcCheckRoi implements Serializable {
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "QC_NAME")
private String qcName;
@TableField(value = "QC_VALUE")
private Double qcValue;
@TableField(value = "QC_STANDARD")
private String qcStandard;
@TableField(value = "QC_RESULT")
private Integer qcResult;
@TableField(value = "MODDATE")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date moddate;
}

View File

@ -0,0 +1,78 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName(value = "RNMAN.GARDS_ANALY_SETTING_ROI")
public class GardsAnalySettingRoi implements Serializable {
@TableField(value = "IDANALYSIS")
private Integer idanalysis;
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
private Integer roiId;
@TableField(value = "MODDATE")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date moddate;
@TableField(value = "ECUTANALYSIS_LOW")
private Double ecutanalysisLow;
@TableField(value = "ECUTANALYSIS_HIGH")
private Double ecutanalysisHigh;
@TableField(value = "ENERGYTOLERANCE")
private Double energytolerance;
@TableField(value = "CALIBRATIONPSS_HIGH")
private Double calibrationpssHigh;
@TableField(value = "CALIBRATIONPSS_LOW")
private Double calibrationpssLow;
@TableField(value = "BASEIMPROVEPSS")
private Double baseimprovepss;
@TableField(value = "PSS_LOW")
private Double pssLow;
@TableField(value = "K_BACK")
private Double KBack;
@TableField(value = "K_ALPHA")
private Double KAlpha;
@TableField(value = "K_BETA")
private Double KBeta;
@TableField(value = "RISKLEVELK")
private Double risklevelk;
@TableField(value = "BUPDATECAL")
private Integer bupdatecal;
@TableField(value = "KEEPCALPEAKSERCHPEAKS")
private Integer keepcalpeakserchpeaks;
@TableField(value = "REFTIME_ACT")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date reftimeAct;
@TableField(value = "REFTIME_CONC")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date reftimeConc;
}

View File

@ -0,0 +1,42 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.experimental.Accessors;
@Data
@TableName("RNMAN.GARDS_ANALYSIS_ROI")
@Accessors(chain = true)
public class GardsAnalysisRoi {
@TableField("IDANALYSIS")
private Integer idAnalysis;
private Integer sampleId;
private Integer roiId;
private Integer roiNum;
private Double minX;
private Double maxX;
private Double minY;
private Double maxY;
private String phdPath;
private String baselinePath;
private String lcPath;
private String scacPath;
private String logPath;
private String reportPath;
}

View File

@ -0,0 +1,74 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储数据分析过程中能量分辨率和效率刻度实际使用的刻度点数据
*/
@Data
@TableName("RNMAN.GARDS_CALIBRATION_PAIRS_ROI")
public class GardsCalibrationPairsRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
private Integer roiId;
/**
* Ggamma探测器的数据#g_Bbeta探测器的数据,#b_
*/
@TableField(value = "SAMPLE_TYPE")
private String sampleType;
/**
* energy能量刻度
* efficiency效率刻度
* Resolution分辨率刻度
*/
@TableField(value = "CALTYPE")
private String caltype;
/**
* PHD代表数据来自PHD文件External代表数据来自外部如刻度工具其它文件等
*/
@TableField(value = "INPUT")
private String input;
/**
* 刻度点ID号
*/
@TableField(value = "IDCALPOINT")
private Integer idCalPoint;
@TableField(value = "XVALUE")
private Double xValue;
@TableField(value = "YVALUE")
private Double yValue;
@TableField(value = "DECAY_MODE")
private String decayMode;
/**
* y值不确定度
*/
@TableField(value = "UNCYVALUE")
private Double uncYValue;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
}

View File

@ -0,0 +1,119 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储数据分析过程中能量分辨率和效率刻度的拟合结果
*/
@Data
@TableName("RNMAN.GARDS_CALIBRATION_ROI")
public class GardsCalibrationRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* Ggamma探测器的数据#g_Bbeta探测器的数据,#b_
*/
@TableField(value = "SAMPLE_TYPE")
private String sampleType;
/**
* energy能量刻度
* efficiency效率刻度
* Resolution分辨率刻度
*/
@TableField(value = "CALTYPE")
private String calType;
/**
* 拟合方程ID号统一定义
*/
@TableField(value = "FUNCTION")
private Integer function;
/**
* 拟合方程描述
*/
@TableField(value = "FUNCTIONDEF")
private String functionDef;
/**
* 拟合的起始值
*/
@TableField(value = "STARTOFRANGE")
private Integer startOfRange;
/**
* 拟合的结束值
*/
@TableField(value = "ENDOFRANGE")
private Integer endOfRange;
/**
* 拟合系数1
*/
@TableField(value = "COEFF1")
private Double coeff1;
/**
* 拟合系数2
*/
@TableField(value = "COEFF2")
private Double coeff2;
/**
* 拟合系数3
*/
@TableField(value = "COEFF3")
private Double coeff3;
/**
* 拟合系数4
*/
@TableField(value = "COEFF4")
private Double coeff4;
/**
* 拟合系数5
*/
@TableField(value = "COEFF5")
private Double coeff5;
/**
* 拟合系数6
*/
@TableField(value = "COEFF6")
private Double coeff6;
/**
* 拟合系数7
*/
@TableField(value = "COEFF7")
private Double coeff7;
/**
* 拟合系数8
*/
@TableField(value = "COEFF8")
private Double coeff8;
/**
* 拟合系数9
*/
@TableField(value = "COEFF9")
private Double coeff9;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
@TableField(value = "COEFF_STRING")
private String coeffString;
}

View File

@ -0,0 +1,48 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName("RNMAN.GARDS_MDC_ROI")
public class GardsMDCRoi implements Serializable {
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "NUCLIDENAME")
private String nuclideName;
@TableField(value = "ENERGY")
private Double energy;
@TableField(value = "YIELD")
private Double yield;
@TableField(value = "EFFICIENCY")
private Double efficiency;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "MDC_ERR")
private String mdcErr;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
}

View File

@ -0,0 +1,122 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱中识别到的核素计算结果
*/
@Data
@TableName("RNMAN.GARDS_NUCL_IDED_ROI")
public class GardsNuclIdedRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* 核素名称
*/
@TableField(value = "NUCLIDENAME")
private String nuclideName;
/**
* 核素类型
*/
@TableField(value = "TYPE")
private String type;
/**
* 核素半衰期
*/
@TableField(value = "HALFLIFE")
private String halflife;
/**
* 平均活度值
*/
@TableField(value = "AVE_ACTIV")
private String aveActiv;
/**
* 平均活度值不确定度
*/
@TableField(value = "AVE_ACTIV_ERR")
private Double aveActivErr;
/**
* 主射线活度值
*/
@TableField(value = "ACTIV_KEY")
private Double activKey;
/**
* 主射线活度值不确定度
*/
@TableField(value = "ACTIV_KEY_ERR")
private Double activKeyErr;
/**
* 核素的最小可探测活度
*/
@TableField(value = "MDA")
private String mda;
/**
* 核素的最小可探测活度不确定度
*/
@TableField(value = "MDA_ERR")
private Double mdaErr;
/**
* 核素识别标志
*/
@TableField(value = "NID_FLAG")
private Integer nidFlag;
@TableField(value = "ACTIV_DECAY")
private Double activDecay;
@TableField(value = "ACTIV_DECAY_ERR")
private Double activDecayErr;
/**
* 符合相加校正因子无设为1
*/
@TableField(value = "CSC_RATIO")
private Double cscRatio;
/**
* 符合相加校正因子不确定度无设为0
*/
@TableField(value = "CSC_RATIO_ERR")
private Double cscRatioErr;
/**
* 活度是否经过符合相加校正
*/
@TableField(value = "CSC_MOD_FLAG")
private Integer cscModFlag;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "CONCENTRATION")
private String concentration;
@TableField(value = "KEY_ENERGY")
private String keyEnergy;
@TableField(value = "KEY_YIELD")
private String keyYield;
}

View File

@ -0,0 +1,126 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱中识别到的峰计算结果
*/
@Data
@TableName("RNMAN.GARDS_NUCL_LINES_IDED_ROI")
public class GardsNuclLinesIdedRoi implements Serializable {
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "ROI_ID")
private Integer roiId;
/**
* 峰序号
*/
@TableField(value = "IDPEAK")
private Integer idPeak;
/**
* 核素名称
*/
@TableField(value = "NUCLIDENAME")
private String nuclideName;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
/**
* 核素库中核素对应峰的能量keV
*/
@TableField(value = "ENERGY")
private Double energy;
/**
* 核素库中核素对应峰的能量不确定度keV
*/
@TableField(value = "UNCENERGY")
private Double uncEnergy;
/**
* 核素库中核素对应峰的发射几率
*/
@TableField(value = "ABUNDANCE")
private Double abundance;
/**
* 核素库中核素对应峰的发射几率不确定度
*/
@TableField(value = "UNCABUNDANCE")
private Double uncAbundance;
/**
* 利用该峰计算得到的活度
*/
@TableField(value = "ACTIVITY")
private String activity;
/**
* 利用该峰计算得到的活度不确定度
*/
@TableField(value = "UNCACTIVITY")
private Double uncActivity;
/**
* 该峰处的探测效率
*/
@TableField(value = "EFFIC")
private Double effic;
/**
* 该峰处的探测效率不确定度
*/
@TableField(value = "UNEFFIC")
private Double unEffic;
/**
* 利用该峰计算得到的最小可探测活度
*/
@TableField(value = "MDA")
private Double mda;
/**
* 主射线标识01
*/
@TableField(value = "KEY_FLAG")
private Double keyFlag;
/**
* 符合相加校正因子无设为1
*/
@TableField(value = "CSC_RATIO")
private Double cscRatio;
/**
* 符合相加校正因子不确定度无设为0
*/
@TableField(value = "CSC_RATIO_ERR")
private Double cscRatioErr;
/**
* 活度是否经过符合相加校正
*/
@TableField(value = "CSC_MOD_FLAG")
private Double cscModFlag;
@TableField(value = "NUCLIDEFULLNAME")
private String nuclidefullname;
@TableField(value = "MDC")
private String mdc;
@TableField(value = "CONCENTRATION")
private String concentration;
}

View File

@ -0,0 +1,166 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* 存储gamma谱的寻峰结果
*/
@Data
@TableName("RNMAN.GARDS_PEAKS_ROI")
public class GardsPeaksRoi implements Serializable {
/**
* 样品id
*/
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
/**
* 峰序号
*/
@TableField(value = "IDPEAK")
private Integer idPeak;
/**
* 分析ID号
*/
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "MODDATE")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date moddate;
/**
* 峰中心道道址
*/
@TableField(value = "CENTROIDCHANNEL")
private Double centroidChannel;
/**
* 峰中心道不确定度道址
*/
@TableField(value = "UNCCENTROIDCHANNEL")
private Double uncCentroidChannel;
/**
* 峰中心道能量keV
*/
@TableField(value = "ENERGY")
private Double energy;
/**
* 峰中心道能量不确定度keV
*/
@TableField(value = "UNCENERGY")
private Double uncEnergy;
/**
* 峰面积计数已扣除基线面积但未扣除空白样品计数和探测器本底计数
*/
@TableField(value = "AREA")
private Double area;
/**
* 峰面积不确定度计数
*/
@TableField(value = "UNCAREA")
private Double uncArea;
/**
* 峰的净计数率1/s=峰面积/活时间
*/
@TableField(value = "NETCOUNTRATE")
private Double netCountRate;
/**
* 峰的净计数率的不确定度1/s
*/
@TableField(value = "UNCNETCOUNTRATE")
private Double uncNetCountRate;
/**
* 测量系统在峰能量处的绝对效率
*/
@TableField(value = "EFFICIENCY")
private Double efficiency;
/**
* 测量系统在峰能量处的绝对效率的不确定度
*/
@TableField(value = "UNCEFFICIENCY")
private Double uncefficiency;
/**
* 峰的半高宽
*/
@TableField(value = "FWHM")
private Double fwhm;
/**
* 峰的十分之一高宽
*/
@TableField(value = "FWTM")
private Double fwtm;
/**
* 峰的重要性因子
*/
@TableField(value = "SIGNIFICANCE")
private Double significance;
/**
* 峰的可探测线Lc
*/
@TableField(value = "LC")
private Double lc;
/**
* 峰的感兴趣区的起始道
*/
@TableField(value = "ROISTART")
private Double roiStart;
/**
* 峰的感兴趣区的结束道
*/
@TableField(value = "ROIEND")
private Double roiEnd;
@TableField(value = "MULTIINDEX")
private Double mulitiIndex;
@TableField(value = "TAIL")
private Double tail;
@TableField(value = "TAILALPHA")
private Double tailAlpha;
@TableField(value = "UPPERTAIL")
private Double upperTail;
@TableField(value = "UPPERTAILALPHA")
private Double upperTailAlpha;
@TableField(value = "BWWIDTHCHAN")
private Double bwwidthchan;
@TableField(value = "RECOILDELTACHAN")
private Double recoildeltachan;
@TableField(value = "STEPRAIO")
private Double stepraio;
@TableField(value = "LD")
private Double ld;
@TableField(value = "SENSITIVITY")
private Double sensitivity;
@TableField(value = "BACKGROUNDAREA")
private Double backgroundarea;
@TableField(value = "MEANBACKCOUNT")
private Double meanbackcount;
@TableField(value = "RECOILBETACHAN")
private Double recoilbetachan;
@TableField(value = "PEAKCOMMENTS")
private String peakcomments;
}

View File

@ -0,0 +1,42 @@
package org.jeecg.modules.base.entity.rnman;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
@Data
@TableName(value = "RNMAN.GARDS_QC_CHECK_ROI")
public class GardsQcCheckRoi implements Serializable {
@TableField(value = "SAMPLE_ID")
private Integer sampleId;
@TableField(value = "IDANALYSIS")
private Integer idAnalysis;
@TableField(value = "ROI_ID")
private Integer roiId;
@TableField(value = "QC_NAME")
private String qcName;
@TableField(value = "QC_VALUE")
private Double qcValue;
@TableField(value = "QC_STANDARD")
private String qcStandard;
@TableField(value = "QC_RESULT")
private Integer qcResult;
@TableField(value = "MODDATE")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date moddate;
}

View File

@ -50,7 +50,11 @@ public enum DataType {
*/
GASBKPHD("GASBKPHD",".PHD"),
SPHDP("SPHDP", ".PHD"),
SPHDF("SPHDF", ".PHD");
SPHDF("SPHDF", ".PHD"),
GPS("RMSGPS", ".gps"),
RESULT("HRULT", ".result");
private String type;

View File

@ -4,10 +4,30 @@ import org.apache.commons.lang3.StringUtils;
public enum SampleFileHeader {
HEADER(0,"#Header"),COMMENT(1,"#Comment"),COLLECTION(2,"#Collection"),ACQUISITION(3,"#Acquisition"),PROCESSING(4,"#Processing"),SAMPLE(5,"#Sample"),
GENERGY(6,"#g_Energy"),BENERGY(7,"#b_Energy"),GRESOLUTION(8,"#g_Resolution"),BRESOLUTION(9,"#b_Resolution"),GEFFICIENCY(10,"#g_Efficiency"),
ROILIMITS(11,"#ROI_Limits"),BGEFFICIENCY(12,"#b-gEfficiency"),TOTALEFF(13,"#TotalEff"),RATIOS(14,"#Ratios"),GSPECTRUM(15,"#g_Spectrum"),BSPECTRUM(16,"#b_Spectrum"),
HISTOGRAM(17,"#Histogram"),CALIBRATION(18,"#Calibration"),CERTIFICATE(19,"#Certificate"),STOP(20,"STOP"),BEGIN(21,"BEGIN"),SPECTRUM(22,"#Spectrum");
HEADER(0,"#Header"),
COMMENT(1,"#Comment"),
COLLECTION(2,"#Collection"),
ACQUISITION(3,"#Acquisition"),
PROCESSING(4,"#Processing"),
SAMPLE(5,"#Sample"),
GENERGY(6,"#g_Energy"),
BENERGY(7,"#b_Energy"),
GRESOLUTION(8,"#g_Resolution"),
BRESOLUTION(9,"#b_Resolution"),
GEFFICIENCY(10,"#g_Efficiency"),
BEFFICIENCY(23,"#b_Efficiency"), // 20240801 自建台站增加
ROILIMITS(11,"#ROI_Limits"),
BGEFFICIENCY(12,"#b-gEfficiency"),
TOTALEFF(13,"#TotalEff"),
RATIOS(14,"#Ratios"),
GSPECTRUM(15,"#g_Spectrum"),
BSPECTRUM(16,"#b_Spectrum"),
HISTOGRAM(17,"#Histogram"),
CALIBRATION(18,"#Calibration"),
CERTIFICATE(19,"#Certificate"),
STOP(20,"STOP"),
BEGIN(21,"BEGIN"),
SPECTRUM(22,"#Spectrum");
private Integer code;

View File

@ -13,7 +13,15 @@ public enum SystemType {
/**
* γ
*/
GAMMA("G");
GAMMA("G"),
/**
* 自建台站 β-γ
*/
SELFSTATION("C"),
/**
* 海水系统 γ
*/
WATER("W");
private String type;

View File

@ -13,6 +13,8 @@ public class CalMDCInfo implements Serializable {
*/
private String nuclideName;
private Integer roiId;
/**
* 核素能量
*/

View File

@ -9,6 +9,6 @@ public class CommentData implements Serializable {
private String analyst;
private String comment;
private String comments;
}

View File

@ -181,6 +181,8 @@ public class PHDFile implements Serializable {
private Map<String, NuclideLines> phdNuclideMap;
private String roiSuffix;
public PHDFile() {
userId = "";
xmlFilePath = "";

View File

@ -0,0 +1,26 @@
package org.jeecg.modules.entity.vo;
import lombok.Data;
import java.io.Serializable;
@Data
public class ResultNuclide implements Serializable {
private String nuclideName;
private Double energy;
private Double cscRatio;
private String halfLife;
private Double mda;
private Double activity;
private Double specActivity;
private String nidFlag;
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.entity.vo;
import lombok.Data;
import org.jeecg.modules.base.dto.NuclideInfo;
import java.io.Serializable;
import java.util.HashMap;
@Data
public class SelfParameter implements Serializable {
// 存储核素信息
private HashMap<String, NuclideLine> nuclideMap;
public SelfParameter(){
nuclideMap = new HashMap<>();
}
}

View File

@ -10,5 +10,4 @@ public class SeriseData implements Serializable {
private double x;
private double y;
}

View File

@ -1,6 +1,7 @@
package org.jeecg.modules.entity.vo;
import lombok.Data;
import org.jeecg.common.util.NumUtil;
import java.io.Serializable;
@ -17,4 +18,7 @@ public class TableWidget implements Serializable {
private String fwhmKeV;
public void setChannel(Double channel) {
this.channel = NumUtil.fixedMax(6, channel);
}
}

View File

@ -1,6 +1,5 @@
package org.jeecg.modules;
import cn.hutool.core.util.RandomUtil;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.jeecg.common.constant.RedisConstant;
@ -120,6 +119,7 @@ public class AutoProcessManager{
TimeUnit.MILLISECONDS.sleep(sleepTime);
} catch (InterruptedException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
}
}
}
@ -169,6 +169,7 @@ public class AutoProcessManager{
//捕获异常不处理保障线程异常不退出
}catch (Exception e){
e.printStackTrace();
log.error(e.getMessage(), e);
}
long end = System.currentTimeMillis();
long sleepTime = taskProperties.getMonitoringMailCommStatusCycle() - (end-start);
@ -178,6 +179,7 @@ public class AutoProcessManager{
TimeUnit.MILLISECONDS.sleep(sleepTime);
} catch (InterruptedException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
}
}
}
@ -251,6 +253,7 @@ public class AutoProcessManager{
//捕获异常不处理保障线程异常不退出
}catch (Exception e){
e.printStackTrace();
log.error(e.getMessage(), e);
}
long end = System.currentTimeMillis();
long sleepTime = taskProperties.getMonitoringMailDataCycle() - (end-start);
@ -260,6 +263,7 @@ public class AutoProcessManager{
TimeUnit.MILLISECONDS.sleep(sleepTime);
} catch (InterruptedException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
}
}
}
@ -304,6 +308,7 @@ public class AutoProcessManager{
}
}catch (Exception e){
e.printStackTrace();
log.error(e.getMessage(), e);
}finally {
if(emailExecThread.getState() != State.TERMINATED && emailExecThread.isStop()){
final long nowTime = System.currentTimeMillis();
@ -325,6 +330,7 @@ public class AutoProcessManager{
TimeUnit.MILLISECONDS.sleep(sleepTime);
} catch (InterruptedException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
}
}
}

View File

@ -86,8 +86,8 @@ public class EmailParsingActuator extends Thread{
List<String> messageIds = new ArrayList<>();
try {
Message[] messages = emailServiceManager.receiveMail();
log.info("EmailParsingActuator本次{}获取邮件数量为:{}", Thread.currentThread().getName(), ArrayUtils.isEmpty(messages) ? 0 : messages.length);
if(ArrayUtils.isNotEmpty(messages)){
log.info("EmailParsingActuator本次{}获取邮件数量为:{}", Thread.currentThread().getName(), messages.length);
//检验获取的邮件是否在之前删除失败列表中若在直接调用邮件API删除并且此次数组里元素也删除
for(int i=messages.length-1;i>=0;i--){
if (null == messages[i].getHeader("Message-ID")) {
@ -122,6 +122,7 @@ public class EmailParsingActuator extends Thread{
log.error("EmailParsingActuator has exception: {}", e.getMessage());
log.info("Mail-Parsing线程池资源关闭...");
closeResource();
log.error(e.getMessage(), e);
throw new RuntimeException(e);
} finally {
//清除本批次邮件日志缓存
@ -142,6 +143,8 @@ public class EmailParsingActuator extends Thread{
TimeUnit.MILLISECONDS.sleep(sleepTime);
} catch (InterruptedException e) {
e.printStackTrace();
log.error(e.getMessage(), e);
throw new RuntimeException();
}
}
}

View File

@ -0,0 +1,24 @@
package org.jeecg.modules.exception;
/**
* C谱分析异常
*/
public class CAnalyseException extends AnalyseException{
/**
* Constructs a new exception with the specified detail message. The
* cause is not initialized, and may subsequently be initialized by
* a call to {@link #initCause}.
*
* @param message the detail message. The detail message is saved for
* later retrieval by the {@link #getMessage()} method.
*/
public CAnalyseException(String message) {
super(message);
}
public CAnalyseException(String message, boolean isDuplicateKeyException) {
super(message,isDuplicateKeyException);
}
}

View File

@ -0,0 +1,12 @@
package org.jeecg.modules.exception;
/*
GPS文件读取失败时抛出异常
*/
public class GPSFileReadException extends RuntimeException{
public GPSFileReadException(String message) {
super(message);
}
}

View File

@ -0,0 +1,7 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.original.GardsGPSData;
public interface GardsGPSDataMapper extends BaseMapper<GardsGPSData> {
}

View File

@ -0,0 +1,13 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.original.GardsGPSData;
import org.jeecg.modules.native_jni.struct.GPSSpectrumStruct;
import java.util.List;
public interface IGardsGPSDataService extends IService<GardsGPSData> {
List<GardsGPSData> create(GPSSpectrumStruct sourceData, String fileName);
}

View File

@ -0,0 +1,72 @@
package org.jeecg.modules.service.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
import com.baomidou.mybatisplus.core.toolkit.StringUtils;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.jeecg.common.util.DateUtils;
import org.jeecg.modules.base.entity.configuration.GardsStations;
import org.jeecg.modules.base.entity.original.GardsGPSData;
import org.jeecg.modules.exception.StationNotFoundException;
import org.jeecg.modules.mapper.GardsGPSDataMapper;
import org.jeecg.modules.native_jni.struct.GPSSpectrumStruct;
import org.jeecg.modules.service.GardsStationsService;
import org.jeecg.modules.service.IGardsGPSDataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.text.ParseException;
import java.util.LinkedList;
import java.util.List;
import java.util.Objects;
@Service
@DS("ora")
public class GardsGPSDataServiceImpl extends ServiceImpl<GardsGPSDataMapper, GardsGPSData> implements IGardsGPSDataService {
@Autowired
private GardsStationsService stationsService;
@Override
@Transactional(rollbackFor = Exception.class)
public List<GardsGPSData> create(GPSSpectrumStruct sourceData, String fileName) {
List<GardsGPSData> dataList = new LinkedList<>();
try {
//根据台站编码查询台站id
GardsStations station = stationsService.check(sourceData.stationCode, fileName);
if (Objects.nonNull(station)) {
//遍历时间和经纬度数据
for (int i=0; i<sourceData.recordDateList.size(); i++) {
GardsGPSData data = new GardsGPSData();
data.setStationId(station.getStationId());
data.setStationCode(sourceData.stationCode);
//拼接记录时间
if (StringUtils.isNotBlank(sourceData.recordDateList.get(i)) && StringUtils.isNotBlank(sourceData.recordTimeList.get(i))) {
String recordTimeStr = sourceData.recordDateList.get(i) + StringPool.SPACE + sourceData.recordTimeList.get(i);
data.setRecordTime(DateUtils.parseDate(recordTimeStr));
} else {
data.setRecordTime(null);
}
//时间间隔
data.setTimeSpan(StringUtils.isNotBlank(sourceData.spanTimeList.get(i))?Integer.valueOf(sourceData.spanTimeList.get(i)):0);
//经度
data.setLon(StringUtils.isNotBlank(sourceData.lonList.get(i))?Double.valueOf(sourceData.lonList.get(i)):null);
//纬度
data.setLat(StringUtils.isNotBlank(sourceData.latList.get(i))?Double.valueOf(sourceData.latList.get(i)):null);
dataList.add(data);
}
if (CollectionUtils.isNotEmpty(dataList)) {
this.saveBatch(dataList);
}
}
return dataList;
} catch (StationNotFoundException e) {
throw new RuntimeException(e);
} catch (ParseException e) {
throw new RuntimeException(e);
}
}
}

View File

@ -1,5 +1,7 @@
package org.jeecg.modules.service.impl;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;
import lombok.RequiredArgsConstructor;
import org.apache.commons.lang3.StringUtils;
import org.jeecg.common.constant.StringConstant;
@ -8,6 +10,7 @@ import org.jeecg.modules.base.entity.configuration.GardsDetectors;
import org.jeecg.modules.base.entity.configuration.GardsStations;
import org.jeecg.modules.base.entity.original.GardsSampleAux;
import org.jeecg.modules.base.entity.original.GardsSampleData;
import org.jeecg.modules.base.enums.DataType;
import org.jeecg.modules.file.FileOperation;
import org.jeecg.modules.mapper.GardsSampleAuxMapper;
import org.jeecg.modules.mapper.GardsSampleDataMapper;
@ -122,6 +125,14 @@ public class SpectrumBaseBlockServiceImpl implements ISpectrumBaseBlockService {
gardsSampleAux.setXeCollectionYied(struct.Xe_collection_yield);
gardsSampleAux.setXeCollectionYiedUncer(struct.uncertainty_2);
// 如果是样品谱类型 自建台站谱需要存储GPS坐标信息 其它样品谱GPS坐标为0
String dataType = struct.data_type;
if (StrUtil.contains(dataType, DataType.SAMPLEPHD.getType())
|| StrUtil.contains(dataType, DataType.SPHDF.getType())
|| StrUtil.contains(dataType, DataType.SPHDP.getType())){
gardsSampleAux.setLon(struct.lon);
gardsSampleAux.setLat(struct.lat);
}
this.sampleAuxMapper.insert(gardsSampleAux);
}
}

View File

@ -316,7 +316,7 @@ public abstract class AbstractSpectrumHandler extends AbstractChain {
ex.printStackTrace();
}
} else if(SpectrumSource.FROM_FILE_SOURCE.getSourceType().equals(spectrumSource) && (e instanceof FileRepeatException)){
this.spectrumFile.delete(); // TODO 删除原始谱文件
//this.spectrumFile.delete(); // TODO 删除原始谱文件
} else if (SpectrumSource.FORM_FILE_UNDEL.getSourceType().equals(spectrumSource) && !(e instanceof FileRepeatException)) {
try {
if (isDateFormatErr) {

View File

@ -0,0 +1,277 @@
package org.jeecg.modules.spectrum;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
import com.baomidou.mybatisplus.core.toolkit.StringUtils;
import org.apache.commons.io.FileUtils;
import org.jeecg.common.properties.SpectrumPathProperties;
import org.jeecg.common.util.DateUtils;
import org.jeecg.modules.ErrorLogManager;
import org.jeecg.modules.base.entity.original.GardsGPSData;
import org.jeecg.modules.base.enums.DataType;
import org.jeecg.modules.base.enums.SampleFileHeader;
import org.jeecg.modules.eneity.event.FormatErrorEvent;
import org.jeecg.modules.eneity.event.SpectrumErrorEvent;
import org.jeecg.modules.enums.ErrorType;
import org.jeecg.modules.exception.GPSFileReadException;
import org.jeecg.modules.exception.PHD_ReadException;
import org.jeecg.modules.file.FileOperation;
import org.jeecg.modules.native_jni.struct.GPSSpectrumStruct;
import org.springframework.util.CollectionUtils;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.time.LocalDate;
import java.util.Arrays;
import java.util.Date;
import java.util.List;
public class GPSSpectrum extends AbstractSpectrumHandler{
private List<String> lines = null;
private GPSSpectrumStruct sourceData = null;
/**
* 开始存库时间
*/
private Date startIntoDatabaseTime = null;
/**
* 结束存库时间
*/
private Date endIntoDatabaseTime = null;
private List<GardsGPSData> gpsData = null;
/**
* 设置过滤链路
*/
@Override
protected void setChina() {
AbstractSpectrumHandler spectrumHandler = new WaterResultSpectrum();
spectrumHandler.initNext(super.spectrumServiceQuotes,super.spectrumFile,super.sourceFilePath,
super.currDataType,super.mailContent,super.emlFileName,
super.spectrumSource,super.returnFileName, super.batchesCounter);
spectrumHandler.setPrevious(this);
super.setNext(spectrumHandler);
}
/**
* 前置检查
*/
@Override
protected void preCheck() {
this.readFile();
}
protected void readFile() {
//获取文件内容
File gpsFile = new File(super.spectrumFile.getAbsolutePath());
//判断文件是否存在如果不存在抛出phd文件读取异常
if (!gpsFile.exists()) {
throw new GPSFileReadException("This GPS file cannot be found in:"+super.spectrumFile.getAbsolutePath());
}
//文件内容读取
try {
lines = FileUtils.readLines(gpsFile, "UTF-8");
} catch (IOException e) {
ErrorLogManager.getInstance().write(new SpectrumErrorEvent(new Date(), "This GPS file read content error", super.spectrumFile.getName()));
throw new GPSFileReadException("This GPS file read content error");
}
}
@Override
public void handler() throws Exception {
if(DataType.GPS.getType().equals(super.currDataType.getType())){
try {
//前置检查
this.preCheck();
//打印当前处理的能谱类型
super.printCurrDataType();
//解析邮件内容
this.parseingEmail();
//修改能谱文件名称
this.updateSpectrumFileName();
//保存PHD文件到savefile
super.saveFileToSavefile();
//结构体数据入库
this.handlerOriginalData();
//把流程日志保存到日志目录
this.saveLogToLogDir();
//若本次文件来自于undel目录解析成功则删除
deleteIfFromUndelFile();
}catch (Exception e){
//异常返回文件名称用于报错日志
super.returnFileName.append(super.spectrumFile.getName());
//处理解析失败的文件
super.handleParseingFailFile(e);
throw e;
}
}
}
/**
* 解析邮件内容
* @throws Exception
*/
@Override
protected void parseingEmail() throws Exception {
this.sourceData = new GPSSpectrumStruct();
//初始下标是0 0不进行读取
int index = 0;
//从第第五行开始遍历文件内容
for (int i=0; i< lines.size(); i++) {
//读取文件行内容
String lineContent = lines.get(i);
//判断当前行是否包含begin 如果包含 从当前行开始向后读取4行
if (lineContent.contains(SampleFileHeader.BEGIN.getMessage())) {
index = i + 4;
}
//切割任意类型空格 获取行内容
List<String> contents = Arrays.asList(lineContent.split("\\s+"));
//固定格式BEGIN 后的第五行的数据是台站编码
if (index > 0 && i == index) {
if (StringUtils.isNotBlank(contents.get(0))) {
this.sourceData.stationCode = contents.get(0);
} else {
this.sourceData.stationCode = "";
}
if (StringUtils.isNotBlank(contents.get(1))) {
this.sourceData.receiveDate = contents.get(1);
} else {
this.sourceData.receiveDate = "";
}
if (StringUtils.isNotBlank(contents.get(2))) {
this.sourceData.receiveTime = contents.get(2);
} else {
this.sourceData.receiveTime = "";
}
} else if (index > 0 && i > index) {
if (!contents.contains(SampleFileHeader.STOP.getMessage()) ) {
if (StringUtils.isNotBlank(contents.get(0))) {
//记录日期
this.sourceData.recordDateList.add(contents.get(0));
} else {
//记录日期
this.sourceData.recordDateList.add("");
}
if (StringUtils.isNotBlank(contents.get(1))) {
//记录时间
this.sourceData.recordTimeList.add(contents.get(1));
} else {
//记录时间
this.sourceData.recordTimeList.add("");
}
if (StringUtils.isNotBlank(contents.get(2))) {
//数据采集间隔持续时间
this.sourceData.spanTimeList.add(contents.get(2));
} else {
//数据采集间隔持续时间
this.sourceData.spanTimeList.add("");
}
if (StringUtils.isNotBlank(contents.get(3))) {
//经度
this.sourceData.lonList.add(contents.get(3));
} else {
//经度
this.sourceData.lonList.add("");
}
if (StringUtils.isNotBlank(contents.get(4))) {
//纬度
this.sourceData.latList.add(contents.get(4));
} else {
//纬度
this.sourceData.latList.add("");
}
}
}
}
}
@Override
protected String getFileSaveRelativePath() {
final int year = LocalDate.now().getYear();
final int month = LocalDate.now().getMonth().getValue();
final SpectrumPathProperties properties = super.spectrumServiceQuotes.getSpectrumPathProperties();
StringBuilder relativePath = new StringBuilder();
relativePath.append(properties.getFilePathMap().get(super.currDataType.getType()));
relativePath.append(File.separator);
relativePath.append(year);
relativePath.append(File.separator);
relativePath.append(month>=10?month:"0"+month);
return relativePath.toString();
}
@Override
protected void updateSpectrumFileName() throws FileNotFoundException {
StringBuilder newFileName = new StringBuilder();
newFileName.append(this.sourceData.stationCode);
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(super.currDataType.getType());
newFileName.append(StringPool.DASH);
newFileName.append(this.sourceData.receiveDate.replace(StringPool.SLASH, ""));
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(this.sourceData.receiveTime.replace(StringPool.COLON, ""));
newFileName.append(super.currDataType.getSuffix());
if(!super.spectrumFile.exists()){
//发送格式化错误事件后续统计报告使用
spectrumServiceQuotes.getApplicationContext().publishEvent(new FormatErrorEvent());
throw new FileNotFoundException(super.spectrumFile.getAbsolutePath()+" does not exist");
}
super.spectrumFile = FileOperation.rename(super.spectrumFile,newFileName.toString(),true);
//设置能谱文件保存相对路径包含文件名称
String fileSavePath = this.getFileSaveRelativePath();
this.spectrumFileRelativePath = fileSavePath+File.separator+this.spectrumFile.getName();
}
@Override
protected void updateErrorSpectrumFileName() throws FileNotFoundException {
StringBuilder newFileName = new StringBuilder();
newFileName.append(this.sourceData.stationCode);
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(super.currDataType.getType());
newFileName.append(StringPool.DASH);
newFileName.append(this.sourceData.receiveDate.replace(StringPool.SLASH, ""));
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(this.sourceData.receiveTime.replace(StringPool.COLON, ""));
newFileName.append(super.currDataType.getSuffix());
if(!super.spectrumFile.exists()){
//发送格式化错误事件后续统计报告使用
spectrumServiceQuotes.getApplicationContext().publishEvent(new FormatErrorEvent());
throw new FileNotFoundException(super.spectrumFile.getAbsolutePath()+" does not exist");
}
super.spectrumFile = FileOperation.rename(super.spectrumFile,newFileName.toString(),true);
}
@Override
protected void handlerOriginalData() throws Exception {
this.startIntoDatabaseTime = new Date();
this.gpsData = spectrumServiceQuotes.getGardsGPSDataService().create(this.sourceData, super.spectrumFileRelativePath);
this.endIntoDatabaseTime = new Date();
}
/**
* 把流程日志保存到日志目录
*/
@Override
protected void saveLogToLogDir() throws IOException {
//获取健康谱记录ID范围
String gpsIdRange = "";
if(!CollectionUtils.isEmpty(this.gpsData)){
gpsIdRange = this.gpsData.get(0).getGpsId()+"-"+this.gpsData.get(this.gpsData.size()-1).getGpsId();
}
//组装日志文件内容
StringBuilder logContent = new StringBuilder();
logContent.append("-------------------------- Write Data into Database at ").append(DateUtils.formatDate(this.startIntoDatabaseTime,"yyyy-MM-dd HH:mm:ss")).append(" ---------------------------");
logContent.append(System.lineSeparator()).append(System.lineSeparator());
logContent.append("GPS ID: ").append(gpsIdRange).append(" StandardFile:").append(super.spectrumFile.getAbsolutePath());
logContent.append(System.lineSeparator()).append(System.lineSeparator());
logContent.append("------------------- ").append("Write Data into Database Successfully at ").append(DateUtils.formatDate(this.endIntoDatabaseTime,"yyyy-MM-dd HH:mm:ss")).append(" --------------------");
final SpectrumPathProperties properties = this.spectrumServiceQuotes.getSpectrumPathProperties();
final String dirPath = properties.getRootPath()+properties.getLogPath()+File.separator+this.getFileSaveRelativePath();
final String fileName = super.spectrumFile.getName().replace(this.currDataType.getSuffix(),LOG_FILE_SUFFIX);
final String finalPath = dirPath+ File.separator+fileName;
super.sendSpectrumLogToQueue(finalPath,logContent.toString());
}
}

View File

@ -48,6 +48,12 @@ public class HealthStatusSpectrum extends AbstractSpectrumHandler{
*/
@Override
protected void setChina() {
AbstractSpectrumHandler spectrumHandler = new GPSSpectrum();
spectrumHandler.initNext(super.spectrumServiceQuotes,super.spectrumFile,super.sourceFilePath,
super.currDataType,super.mailContent,super.emlFileName,
super.spectrumSource,super.returnFileName, super.batchesCounter);
spectrumHandler.setPrevious(this);
super.setNext(spectrumHandler);
}
/**
@ -102,6 +108,8 @@ public class HealthStatusSpectrum extends AbstractSpectrumHandler{
super.handleParseingFailFile(e);
throw e;
}
} else {
super.next.handler();
}
}

View File

@ -110,9 +110,15 @@ public class SamplephdSpectrum extends AbstractS_D_Q_G_SpectrumHandler {
Sample_B_Analysis bAnalysis = new Sample_B_Analysis(this);
bAnalysis.analysis();
}
if (this.sourceData.system_type.equals(SystemType.PARTICULATE.getType()) || this.sourceData.system_type.equals(SystemType.GAMMA.getType())) {
if (this.sourceData.system_type.equals(SystemType.PARTICULATE.getType())
|| this.sourceData.system_type.equals(SystemType.GAMMA.getType())
|| this.sourceData.system_type.equals(SystemType.WATER.getType())) {
Sample_G_Analysis sample_g_analysis = new Sample_G_Analysis(this, super.sourceData, super.spectrumServiceQuotes, super.sampleData);
sample_g_analysis.analysis();
}
if (this.sourceData.system_type.equals(SystemType.SELFSTATION.getType())) {
Sample_C_Analysis sample_c_analysis = new Sample_C_Analysis(this, super.sourceData, super.spectrumServiceQuotes, super.sampleData);
sample_c_analysis.analysis();
}
}
}

View File

@ -6,8 +6,10 @@ import org.jeecg.common.properties.*;
import org.jeecg.common.util.NameStandUtil;
import org.jeecg.common.util.RedisStreamUtil;
import org.jeecg.common.util.RedisUtil;
import org.jeecg.common.util.SelfUtil;
import org.jeecg.modules.datasource.OraDataSourceProperties;
import org.jeecg.modules.service.*;
import org.jeecg.modules.service.impl.GardsCalibrationRoiAutoServiceImpl;
import org.springframework.context.ApplicationContext;
import org.springframework.core.io.ResourceLoader;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
@ -85,11 +87,32 @@ public class SpectrumServiceQuotes {
private final RedisUtil redisUtil;
private final MaximumPoolSizeProperties maximumPoolSizeProperties;
private final IGardsGPSDataService gardsGPSDataService;
private final SelfUtil selfStationUtil;
/* 自动处理库_ROI相关类引用 */
private final IGardsAnalysisRoiAutoService analysisRoiAutoService;
private final GardsCalibrationRoiAutoServiceImpl calibrationRoiAutoService;
private final IGardsCalibrationPairsRoiAutoService calibrationPairsRoiAutoService;
private final IGardsMdcRoiAutoService mdcRoiAutoService;
private final IGardsNuclIdedRoiAutoService nuclIdedRoiAutoService;
private final IGardsNuclLinesIdedRoiAutoService nuclLinesIdedRoiAutoService;
private final IGardsPeaksRoiAutoService peaksRoiAutoService;
private final IGardsQcCheckRoiAutoService qcCheckRoiAutoService;
/**
* 原始库插入数据锁
*/
private final Object originalLibraryLock = new Object();
private final BatchesCounter batchesCounter;
}

View File

@ -0,0 +1,219 @@
package org.jeecg.modules.spectrum;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
import org.apache.commons.io.FileUtils;
import org.jeecg.common.properties.SpectrumPathProperties;
import org.jeecg.common.util.DateUtils;
import org.jeecg.modules.ErrorLogManager;
import org.jeecg.modules.base.entity.original.SampleWaterResult;
import org.jeecg.modules.base.enums.DataType;
import org.jeecg.modules.base.enums.SampleFileHeader;
import org.jeecg.modules.eneity.event.FormatErrorEvent;
import org.jeecg.modules.eneity.event.SpectrumErrorEvent;
import org.jeecg.modules.exception.GPSFileReadException;
import org.jeecg.modules.file.FileOperation;
import org.jeecg.modules.native_jni.struct.WaterResultStruct;
import org.springframework.util.CollectionUtils;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.time.LocalDate;
import java.util.*;
public class WaterResultSpectrum extends AbstractSpectrumHandler{
private List<String> lines = null;
private WaterResultStruct sourceData = null;
/**
* 开始存库时间
*/
private Date startIntoDatabaseTime = null;
/**
* 结束存库时间
*/
private Date endIntoDatabaseTime = null;
private List<SampleWaterResult> waterResultList = null;
@Override
protected void setChina() {
}
@Override
protected void preCheck() {
this.readFile();
}
protected void readFile() {
//获取文件内容
File resultFile = new File(super.spectrumFile.getAbsolutePath());
//判断文件是否存在如果不存在抛出phd文件读取异常
if (!resultFile.exists()) {
throw new GPSFileReadException("This Result file cannot be found in:"+super.spectrumFile.getAbsolutePath());
}
//文件内容读取
try {
lines = FileUtils.readLines(resultFile, "UTF-8");
} catch (IOException e) {
ErrorLogManager.getInstance().write(new SpectrumErrorEvent(new Date(), "This Result file read content error", super.spectrumFile.getName()));
throw new GPSFileReadException("This Result file read content error");
}
}
@Override
public void handler() throws Exception {
if(DataType.RESULT.getType().equals(super.currDataType.getType())){
try {
//前置检查
this.preCheck();
//打印当前处理的能谱类型
super.printCurrDataType();
//解析邮件内容
this.parseingEmail();
//修改能谱文件名称
this.updateSpectrumFileName();
//保存PHD文件到savefile
super.saveFileToSavefile();
//结构体数据入库
this.handlerOriginalData();
//把流程日志保存到日志目录
this.saveLogToLogDir();
//若本次文件来自于undel目录解析成功则删除
deleteIfFromUndelFile();
}catch (Exception e){
//异常返回文件名称用于报错日志
super.returnFileName.append(super.spectrumFile.getName());
//处理解析失败的文件
super.handleParseingFailFile(e);
throw e;
}
}
}
@Override
protected void parseingEmail() throws Exception {
this.sourceData = new WaterResultStruct();
//遍历文件内容
for (int i=0; i< lines.size(); i++) {
//获取行内容
String lineContent = lines.get(i);
//判断行内容是否包含header的内容
if (lineContent.contains(SampleFileHeader.HEADER.getMessage())) {
Map<String, String> map = new HashMap<>();
this.readContent(i+1, map);
}
}
}
private int readContent(int index, Map<String, String> map) {
int lastIndex = 0;
for (int i= index; i<lines.size(); i++) {
//从当前下标开始读取内容 直到下一个结束的标识为止 并返回结束标识的下标
String lineContent = lines.get(i);
//判断当前行是否包含# 或者 STOP 如果都不包含则进行内容读取 如果包含则跳过
if (!lineContent.contains("#") && !lineContent.contains(SampleFileHeader.STOP.getMessage())) {
//切割任意类型空格 获取行内容
List<String> contents = Arrays.asList(lineContent.split("\\s+"));
//遍历当前行内容
for (int j=0; j<contents.size(); j++) {
String content = contents.get(j);
}
} else {
lastIndex = i;
}
}
return lastIndex;
}
@Override
protected String getFileSaveRelativePath() {
final int year = LocalDate.now().getYear();
final int month = LocalDate.now().getMonth().getValue();
final SpectrumPathProperties properties = super.spectrumServiceQuotes.getSpectrumPathProperties();
StringBuilder relativePath = new StringBuilder();
relativePath.append(properties.getFilePathMap().get(super.currDataType.getType()));
relativePath.append(File.separator);
relativePath.append(year);
relativePath.append(File.separator);
relativePath.append(month>=10?month:"0"+month);
return relativePath.toString();
}
@Override
protected void updateSpectrumFileName() throws FileNotFoundException {
StringBuilder newFileName = new StringBuilder();
newFileName.append(this.sourceData.stationCode);
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(super.currDataType.getType());
newFileName.append(StringPool.DASH);
newFileName.append(this.sourceData.sampleRefId.substring(5, 17));
newFileName.append(super.currDataType.getSuffix());
if(!super.spectrumFile.exists()){
//发送格式化错误事件后续统计报告使用
spectrumServiceQuotes.getApplicationContext().publishEvent(new FormatErrorEvent());
throw new FileNotFoundException(super.spectrumFile.getAbsolutePath()+" does not exist");
}
super.spectrumFile = FileOperation.rename(super.spectrumFile,newFileName.toString(),true);
//设置能谱文件保存相对路径包含文件名称
String fileSavePath = this.getFileSaveRelativePath();
this.spectrumFileRelativePath = fileSavePath+File.separator+this.spectrumFile.getName();
}
@Override
protected void updateErrorSpectrumFileName() throws FileNotFoundException {
StringBuilder newFileName = new StringBuilder();
newFileName.append(this.sourceData.stationCode);
newFileName.append(StringPool.UNDERSCORE);
newFileName.append(super.currDataType.getType());
newFileName.append(StringPool.DASH);
newFileName.append(this.sourceData.sampleRefId.substring(5, 17));
newFileName.append(super.currDataType.getSuffix());
if(!super.spectrumFile.exists()){
//发送格式化错误事件后续统计报告使用
spectrumServiceQuotes.getApplicationContext().publishEvent(new FormatErrorEvent());
throw new FileNotFoundException(super.spectrumFile.getAbsolutePath()+" does not exist");
}
super.spectrumFile = FileOperation.rename(super.spectrumFile,newFileName.toString(),true);
}
@Override
protected void handlerOriginalData() throws Exception {
this.startIntoDatabaseTime = new Date();
// this.gpsData = spectrumServiceQuotes.getGardsGPSDataService().create(this.sourceData, super.spectrumFileRelativePath);
this.endIntoDatabaseTime = new Date();
}
/**
* 把流程日志保存到日志目录
*/
@Override
protected void saveLogToLogDir() throws IOException {
//获取海水结果谱记录核素ID范围
String nuclideIdRange = "";
if(!CollectionUtils.isEmpty(this.waterResultList)){
nuclideIdRange = this.waterResultList.get(0).getSampleResultId()+"-"+this.waterResultList.get(this.waterResultList.size()-1).getSampleResultId();
}
//组装日志文件内容
StringBuilder logContent = new StringBuilder();
logContent.append("-------------------------- Write Data into Database at ").append(DateUtils.formatDate(this.startIntoDatabaseTime,"yyyy-MM-dd HH:mm:ss")).append(" ---------------------------");
logContent.append(System.lineSeparator()).append(System.lineSeparator());
logContent.append("WATER RESULT NUCLIDE ID: ").append(nuclideIdRange).append(" StandardFile:").append(super.spectrumFile.getAbsolutePath());
logContent.append(System.lineSeparator()).append(System.lineSeparator());
logContent.append("------------------- ").append("Write Data into Database Successfully at ").append(DateUtils.formatDate(this.endIntoDatabaseTime,"yyyy-MM-dd HH:mm:ss")).append(" --------------------");
final SpectrumPathProperties properties = this.spectrumServiceQuotes.getSpectrumPathProperties();
final String dirPath = properties.getRootPath()+properties.getLogPath()+File.separator+this.getFileSaveRelativePath();
final String fileName = super.spectrumFile.getName().replace(this.currDataType.getSuffix(),LOG_FILE_SUFFIX);
final String finalPath = dirPath+ File.separator+fileName;
super.sendSpectrumLogToQueue(finalPath,logContent.toString());
}
}

View File

@ -2,6 +2,7 @@ package org.jeecg.common.util;
import cn.hutool.core.io.FileUtil;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;
import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
@ -2313,6 +2314,12 @@ public class GammaFileUtil extends AbstractLogOrReport {
}
}
public List<String> GetReportContent(PHDFile phd, String userName, String flag) {
GStoreMiddleProcessData middleData = new GStoreMiddleProcessData();
GetInterMiddlData(phd, userName, middleData, flag);
return reportContent(middleData);
}
public boolean GetInterMiddlData(PHDFile phd, String userName, GStoreMiddleProcessData middleData, String flag) {
boolean bRet = true;
Map<String, NuclideLines> temp = new HashMap<>();
@ -2324,6 +2331,21 @@ public class GammaFileUtil extends AbstractLogOrReport {
}
return bRet;
}
public boolean GetInterMiddlData(List<PHDFile> phds, String userName, List<GStoreMiddleProcessData> middleDatas, String flag) {
boolean bRet = true;
try {
for (int i = 0; i < phds.size(); i++) {
Map<String, NuclideLines> temp = new HashMap<>();
PHDFile phd = phds.get(i);
GStoreMiddleProcessData middleData = middleDatas.get(i);
bRet = GetMiddleData(phd, userName, temp,middleData, MiddleDataType.InterAction.getType(), flag);
middleData.analyses_type ="Interactive";
}
} catch (ParseException e) {
throw new RuntimeException(e);
}
return bRet;
}
public String GetLogContent(GStoreMiddleProcessData middleData) {
StringBuffer strBuffer = new StringBuffer();
@ -2678,7 +2700,7 @@ public class GammaFileUtil extends AbstractLogOrReport {
strBuffer.append(System.lineSeparator());
if (middleData.sample_Type.equals(SystemType.PARTICULATE.getType())) {
strBuffer.append(" (Particulates Version) ");
} else if (middleData.sample_Type.equals(SystemType.GAMMA.getType())) {
} else if (StrUtil.equalsAny(middleData.sample_Type, SystemType.GAMMA.getType(), SystemType.SELFSTATION.getType())) {
strBuffer.append(" (Noble Gas Version) ");
}
//换行
@ -3099,6 +3121,293 @@ public class GammaFileUtil extends AbstractLogOrReport {
return "";
}
public List<String> reportContent(GStoreMiddleProcessData middleData) {
List<String> result = new ArrayList<>();
result.add(" CNL06 GENERATED REPORT");
result.add(" " + middleData.analyses_type + " RADIONUCLIDE REPORT");
if (middleData.sample_Type.equals(SystemType.PARTICULATE.getType())) {
result.add(" (Particulates Version) ");
} else if (StrUtil.equalsAny(middleData.sample_Type, SystemType.GAMMA.getType(), SystemType.SELFSTATION.getType())) {
result.add(" (Noble Gas Version) ");
}
result.add(" Creation Date " + DateUtils.formatDate(new Date(), "yyyy/MM/dd-HH:mm:ss"));
result.add("#SAMPLE INFORMATION");
//报告内容第一部分数据
result.add(rowFormat("%sStation ID:%-25s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_stationID));
result.add(rowFormat("%sDetector ID:%-24s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_detectID));
result.add(rowFormat("%sSample ID:%-26s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_id));
result.add(rowFormat("%sSample Geometry:%-20s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_Geometry));
result.add(rowFormat("%sSample Quantity[m3]:%-16s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_quantity));
result.add(rowFormat("%sSample Type:%-24s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_Type));
result.add(rowFormat("%sCollection Start:%-19s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_collection_start));
result.add(rowFormat("%sCollection Stop:%-20s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_collection_stop));
result.add(rowFormat("%sSampling Time[h]:%-19s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_time));
result.add(rowFormat("%sDecay Time[h]:%-22s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_decay_time));
result.add(rowFormat("%sAcquisition Start:%-18s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_acquisiton_start));
result.add(rowFormat("%sAcquisition Stop:%-19s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_acquistion_stop));
result.add(rowFormat("%sAcquisition Time[s]:%-16s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_acquistion_time));
result.add(rowFormat("%sAvg Flow Rate[m3/h]:%-16s%s", StringPool.SPACE, StringPool.SPACE, middleData.sample_Avg_Flow_Rate));
String[] cells1 = new String[]{" Collection Station Comments"};
String[] datas1 = new String[]{middleData.Collection_Station_Comments};
//根据固定宽度切割数据
Map<String, List<String>> reportMap1 = GetReportFixedWidth(cells1, datas1, 30);
List<String> title1 = reportMap1.get("title");
List<String> content1 = reportMap1.get("content");
for (int i = 0; i < title1.size(); i++) {
String title = title1.get(i);
String content = content1.get(i);
result.add(String.format("%s:%-8s%s", title, StringPool.SPACE, content));
}
//报告内容第二部分数据
String[] cell2 = new String[]{" Analysis General Comments"};
String[] datas2 = new String[]{middleData.NDC_Analysis_General_Comments};
//根据固定宽度切割数据
Map<String, List<String>> reportMap2 = GetReportFixedWidth(cell2, datas2, 30);
List<String> title2 = reportMap2.get("title");
List<String> content2 = reportMap2.get("content");
for (int i = 0; i < title2.size(); i++) {
String title = title2.get(i);
String content = content2.get(i);
result.add(String.format("%s:%-10s%s", title, StringPool.SPACE, content));
}
//获取核素信息
String qsNuclidesName = "";
for (int m = 0; m < middleData.nucl_ided_Nuclidename.size() - 1; m++) {
qsNuclidesName = qsNuclidesName + middleData.nucl_ided_Nuclidename.get(m) + ";";
}
if (middleData.nucl_ided_Nuclidename.size() > 1) {
qsNuclidesName = qsNuclidesName + middleData.nucl_ided_Nuclidename.get(middleData.nucl_ided_Nuclidename.size() - 1);
}
result.add("#ACTIVITY SUMMARY");
//报告内容第三部分数据
String[] cells3 = new String[]{" Nuclides Identified"};
String[] datas3 = new String[]{qsNuclidesName};
//根据固定宽度切割数据
Map<String, List<String>> reportMap3 = GetReportFixedWidth(cells3, datas3, 30);
List<String> title3 = reportMap3.get("title");
List<String> content3 = reportMap3.get("content");
for (int i = 0; i < title3.size(); i++) {
String title = title3.get(i);
String content = content3.get(i);
result.add(String.format("%s:%-16s%s", title, StringPool.SPACE, content));
}
result.add(String.format("%s:%-4s%s", " Keyline Activities for Nuclides", StringPool.SPACE, ""));
result.add(String.format("%s:%-8s%s", " with defined Reference Line", StringPool.SPACE, ""));
result.add(String.format("%s:%-12s%s", " Activity Reference Time", StringPool.SPACE, middleData.sample_acquisiton_start));
result.add(String.format("%s:%-7s%s", " Concentration Reference Time", StringPool.SPACE, middleData.sample_collection_start));
String nuclideTitle = "%-15s%-18s%-15s%-15s%-15s%-21s%-15s";
String[] nuclideData = new String[]{" Nuclide", "Halflife(s)", "Activity(Bq)", "RelErr%", "MDA(Bq)", "Conc(uBq/m^3)", "MDC"};
result.add(rowFormat(nuclideTitle, nuclideData));
for (int i = 0; i < middleData.nucl_ided_Nuclidename.size(); i++) {
result.add(rowFormat(nuclideTitle, 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)));
}
result.add("#PEAK SEARCH RESULTS");
result.add(StringPool.SPACE + middleData.peaks_idPeak.size() + " peaks reported:");
double peaksUsed = 0;
for (int m = 0; m < middleData.peaks_Nuclide_name.size(); m++) {
if (StringUtils.isNotBlank(middleData.peaks_Nuclide_name.get(m))) {
peaksUsed++;
}
}
result.add(StringPool.SPACE + peaksUsed + " peaks with ID (" + NumberFormatUtil.numberSixLen(String.valueOf(peaksUsed / middleData.peaks_idPeak.size() * 100)) + "%):");
result.add(StringPool.SPACE + (middleData.peaks_idPeak.size() - peaksUsed) + " peaks without ID(" + NumberFormatUtil.numberSixLen(String.valueOf(Double.valueOf(middleData.peaks_idPeak.size() - peaksUsed) / middleData.peaks_idPeak.size() * 100)) + "%):");
String peakTitle = "%-10s%-15s%-15s%-14s%-15s%-21s%-15s%-11s%-28s";
String[] peakData = new String[]{" PeakID", "Energy[kev]", "Centroid", "FWHM[kev]", "NetArea", "NAErr%", "Signif", "Sensit", "Nuclide"};
result.add(rowFormat(peakTitle, peakData));
for (int i = 0; i < middleData.peaks_idPeak.size(); i++) {
result.add(rowFormat(peakTitle, 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))),
StringUtils.join(middleData.peaks_Nuclide_name.get(i), StringPool.SEMICOLON)));
}
result.add("#PROCESSING PARAMETERS");
result.add(rowFormat("%sECutAnalysis_Low:%-19s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getECutAnalysis_Low())));
result.add(rowFormat("%sECutAnalysis_High:%-18s%s", StringPool.SPACE, StringPool.SPACE, middleData.setting_specSetup.getECutAnalysis_High() == -9999 ? "inf" : String.valueOf(middleData.setting_specSetup.getECutAnalysis_High())));
result.add(rowFormat("%sEnergyTolerance:%-20s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getEnergyTolerance())));
result.add(rowFormat("%sBaseImprovePSS:%-21s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getBaseImprovePSS())));
result.add(rowFormat("%sPSS_low:%-28s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getPss_low())));
result.add(rowFormat("%sk_back:%-29s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getK_back())));
result.add(rowFormat("%sk_alpha:%-28s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getK_alpha())));
result.add(rowFormat("%sk_beta:%-29s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getK_beta())));
result.add(rowFormat("%sRiskLevelK:%-25s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getRiskLevelK())));
Date refTimeAct = middleData.setting_specSetup.getRefTime_act();
result.add(rowFormat("%srefTime_act:%-24s%s", StringPool.SPACE, StringPool.SPACE, DateUtils.formatDate(refTimeAct), "yyyy-MM-dd HH:mm:ss"));
result.add(rowFormat("%srefTime_conc:%-23s%s", StringPool.SPACE, StringPool.SPACE, DateUtils.formatDate(middleData.setting_specSetup.getRefTime_conc(), "yyyy-MM-dd HH:mm:ss")));
result.add("#CALIBRATION PARAMETERS");
result.add(rowFormat("%sCalibrationPSS_low:%-17s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getCalibrationPSS_low())));
result.add(rowFormat("%sCalibrationPSS_high:%-16s%s", StringPool.SPACE, StringPool.SPACE, String.valueOf(middleData.setting_specSetup.getCalibrationPSS_high())));
result.add(rowFormat("%sbUpdateCal:%-25s%s", StringPool.SPACE, StringPool.SPACE, (middleData.setting_specSetup.isBUpdateCal() ? "1" : "0")));
result.add(rowFormat("%sKeepCalPeakSearchPeaks:%-13s%s", StringPool.SPACE, StringPool.SPACE, (middleData.setting_specSetup.isKeepCalPeakSearchPeaks() ? "1" : "0")));
if (middleData.calibration_pairs_E_idCalPoint.size() > 0) {
result.add("#Calibration");
result.add(" Energy Calibration [" + middleData.calibration_pairs_E_Input + " ]");
result.add(rowFormat("%sFunction:%-27s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_E_functionTypeDef));
String[] cellsE4 = new String[]{" E"};
String[] datasE4 = new String[]{middleData.calibration_E_functionDef};
//根据固定宽度切割数据
Map<String, List<String>> reportMapE4 = GetReportFixedWidth(cellsE4, datasE4, 30);
List<String> titleE4 = reportMapE4.get("title");
List<String> contentE4 = reportMapE4.get("content");
for (int i = 0; i < titleE4.size(); i++) {
String title = titleE4.get(i);
String content = contentE4.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
String[] cells4 = new String[]{" P"};
String[] datas4 = new String[]{middleData.calibration_E_coeff_string};
//根据固定宽度切割数据
Map<String, List<String>> reportMap4 = GetReportFixedWidth(cells4, datas4, 30);
List<String> title4 = reportMap4.get("title");
List<String> content4 = reportMap4.get("content");
for (int i = 0; i < title4.size(); i++) {
String title = title4.get(i);
String content = content4.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
result.add(rowFormat("%sErr:%-32s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_E_uncoeff_string));
result.add(rowFormat("%sData:%-31s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_pairs_E_Input));
}
if (middleData.calibration_pairs_R_idCalPoint.size() > 0) {
result.add(" Resolution Calibration [" + middleData.calibration_pairs_R_Input + " ]");
result.add(rowFormat("%sFunction:%-27s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_R_functionTypeDef));
String[] cellsE5 = new String[]{" E"};
String[] datasE5 = new String[]{middleData.calibration_R_functionDef};
//根据固定宽度切割数据
Map<String, List<String>> reportMapE5 = GetReportFixedWidth(cellsE5, datasE5, 30);
List<String> titleE5 = reportMapE5.get("title");
List<String> contentE5 = reportMapE5.get("content");
for (int i = 0; i < titleE5.size(); i++) {
String title = titleE5.get(i);
String content = contentE5.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
String[] cells5 = new String[]{" P"};
String[] datas5 = new String[]{middleData.calibration_R_coeff_string};
//根据固定宽度切割数据
Map<String, List<String>> reportMap5 = GetReportFixedWidth(cells5, datas5, 30);
List<String> title5 = reportMap5.get("title");
List<String> content5 = reportMap5.get("content");
for (int i = 0; i < title5.size(); i++) {
String title = title5.get(i);
String content = content5.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
result.add(rowFormat("%sErr:%-32s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_R_uncoeff_string));
result.add(rowFormat("%sData:%-31s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_pairs_R_Input));
}
if (middleData.calibration_pairs_EF_idCalPoint.size() > 0) {
result.add(" Efficiency Calibration [" + middleData.calibration_pairs_EF_Input + " ]");
result.add(rowFormat("%sFunction:%-27s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_EF_functionTypeDef));
String[] cellsE6 = new String[]{" E"};
String[] datasE6 = new String[]{middleData.calibration_EF_functionDef};
//根据固定宽度切割数据
Map<String, List<String>> reportMapE6 = GetReportFixedWidth(cellsE6, datasE6, 30);
List<String> titleE6 = reportMapE6.get("title");
List<String> contentE6 = reportMapE6.get("content");
for (int i = 0; i < titleE6.size(); i++) {
String title = titleE6.get(i);
String content = contentE6.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
String[] cells6 = new String[]{" P"};
String[] datas6 = new String[]{middleData.calibration_EF_coeff_string};
//根据固定宽度切割数据
Map<String, List<String>> reportMap6 = GetReportFixedWidth(cells6, datas6, 30);
List<String> title6 = reportMap6.get("title");
List<String> content6 = reportMap6.get("content");
for (int i = 0; i < title6.size(); i++) {
String title = title6.get(i);
String content = content6.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
result.add(rowFormat("%sErr:%-32s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_EF_uncoeff_string));
result.add(rowFormat("%sData:%-31s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_pairs_EF_Input));
}
if (middleData.calibration_pairs_T_idCalPoint.size() > 0) {
result.add(" Tot_efficiency Calibration [" + middleData.calibration_pairs_T_Input + " ]");
result.add(rowFormat("%sFunction:%-27s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_T_functionTypeDef));
String[] cellsE7 = new String[]{" E"};
String[] datasE7 = new String[]{middleData.calibration_T_functionDef};
//根据固定宽度切割数据
Map<String, List<String>> reportMapE7 = GetReportFixedWidth(cellsE7, datasE7, 30);
List<String> titleE7 = reportMapE7.get("title");
List<String> contentE7 = reportMapE7.get("content");
for (int i = 0; i < titleE7.size(); i++) {
String title = titleE7.get(i);
String content = contentE7.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
String[] cells7 = new String[]{" P"};
String[] datas7 = new String[]{middleData.calibration_T_coeff_string};
//根据固定宽度切割数据
Map<String, List<String>> reportMap7 = GetReportFixedWidth(cells7, datas7, 30);
List<String> title7 = reportMap7.get("title");
List<String> content7 = reportMap7.get("content");
for (int i = 0; i < title7.size(); i++) {
String title = title7.get(i);
String content = content7.get(i);
result.add(rowFormat("%s:%-34s%s", title, StringPool.SPACE, content));
}
result.add(rowFormat("%sErr:%-32s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_T_uncoeff_string));
result.add(rowFormat("%sData:%-31s%s", StringPool.SPACE, StringPool.SPACE, middleData.calibration_pairs_T_Input));
}
result.add("#DATA QUALITY FLAGS");
String qualityTitle = "%-15s%-15s%-15s%-15s";
result.add(rowFormat(qualityTitle, " Name", "Pass/Fail", "Value", "Test"));
for (int i = 0; i < middleData.QC_CHECK_QC_NAME.size(); i++) {
result.add(rowFormat(qualityTitle, StringPool.SPACE + middleData.QC_CHECK_QC_NAME.get(i), (Double.valueOf(middleData.QC_CHECK_QC_RESULT.get(i)) < 1 ? "Fail" : "Pass"), StringUtils.isNotBlank(middleData.QC_CHECK_QC_VALUE.get(i)) ? String.format("%.3f", Double.valueOf(middleData.QC_CHECK_QC_VALUE.get(i))) : "null", middleData.QC_CHECK_QC_STANDARD.get(i)));
}
return result;
}
public List<String> DoubleLimit(List data) {
List<String> rData = new LinkedList<>();
for(int pos=0;pos<data.size();pos++) {
@ -3178,8 +3487,9 @@ public class GammaFileUtil extends AbstractLogOrReport {
boolean bRet=true;
//标准名称规范化
String dataType = fileAnlyse.getMsgInfo().getData_type();
String systemType = fileAnlyse.getHeader().getSystem_type();
String subDirSavePath = "";
subDirSavePath+=nameStandUtil.GetSysTemSubdir(fileAnlyse.getHeader().getSystem_type());
subDirSavePath+=nameStandUtil.GetSysTemSubdir(systemType);
subDirSavePath+=nameStandUtil.GetDateTypeSubdir(dataType);
Map<String, String> fileNames = nameStandUtil.NameStandard(fileAnlyse);
String lcName = fileNames.get("lc");
@ -3212,7 +3522,8 @@ public class GammaFileUtil extends AbstractLogOrReport {
anylseBegin = DateUtils.formatDate(new Date(), "yyyy/MM/dd HH:mm:ss");
bRet = AnalyseSpectrum(fileAnlyse,nucline);
if (bRet) {
RunQC(fileAnlyse);
if (!StrUtil.equals(systemType, SystemType.SELFSTATION.getType()))
RunQC(fileAnlyse);
fileAnlyse.setEfficiencyParam(fileAnlyse.getUsedEffiPara().getP());
fileAnlyse.setEfficiencyEnergy(fileAnlyse.getUsedEffiKD().getG_energy());
fileAnlyse.setEfficiencyCurRow(0);
@ -3316,7 +3627,7 @@ public class GammaFileUtil extends AbstractLogOrReport {
}
//gards_ calibration_pairs Efficiency
middleData.calibration_pairs_sample_type = fileAnlyse.getHeader().getSystem_type();
middleData.calibration_pairs_sample_type = systemType;
if(fileAnlyse.getUsedEffiKD() != null && fileAnlyse.getUsedEffiKD().getG_energy().size() != 0) {
middleData.calibration_pairs_EF_Caltype = CalType.EFFICIENCY_CAL.getType();
middleData.calibration_pairs_EF_Input = fileAnlyse.getUsedEffi();
@ -3390,7 +3701,7 @@ public class GammaFileUtil extends AbstractLogOrReport {
// gards_ calibration 数据表
//拼写刻度字符串
//获取刻度描述字符串
middleData.calibration_sample_type = fileAnlyse.getHeader().getSystem_type();
middleData.calibration_sample_type = systemType;
String coeffEnergy = "";
String uncerEnergy = "";
String funcDefEnergy = "";
@ -3805,7 +4116,7 @@ public class GammaFileUtil extends AbstractLogOrReport {
middleData.sample_stationID = fileAnlyse.getHeader().getSite_code();
middleData.sample_detectID = fileAnlyse.getHeader().getDetector_code();
middleData.sample_Geometry = fileAnlyse.getHeader().getSample_geometry();
middleData.sample_Type = fileAnlyse.getHeader().getSystem_type();
middleData.sample_Type = systemType;
middleData.setting_specSetup = fileAnlyse.getUsedSetting();
middleData.Collection_Station_Comments = StringUtils.isNotBlank(fileAnlyse.getOriTotalCmt())?fileAnlyse.getOriTotalCmt():"";
middleData.NDC_Analysis_General_Comments = StringUtils.isNotBlank(fileAnlyse.getTotalCmt())?fileAnlyse.getTotalCmt():"";

View File

@ -0,0 +1,348 @@
package org.jeecg.common.util;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.baomidou.mybatisplus.core.toolkit.StringPool;
import org.jeecg.modules.base.enums.CalName;
import org.jeecg.modules.entity.vo.*;
import org.jeecg.modules.native_jni.EnergySpectrumHandler;
import org.jeecg.modules.native_jni.struct.EnergySpectrumStruct;
import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Component;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintWriter;
import java.text.DecimalFormat;
import java.util.Date;
import java.util.LinkedList;
import java.util.List;
import java.util.Objects;
@Component
public class SelfUtil {
public List<Long> roiList(Integer startChannel, Integer endChannel, long betaChannels, long gammaChannels, List<Long> h_counts) {
// g_counts
List<Long> counts = new LinkedList<>();
//存储同一列不同行加和后的数量
List<Integer> sumList = new LinkedList<>();
//遍历所有列
for (int i=0; i<gammaChannels; i++) {
long sum = 0;
//根据起始道值和结束道值 获取这一列的所有对应道值的数据
for (int j=startChannel; j <= endChannel; j++) {
//列数 * 总行数 + 当前行下标 获取对应的数据数组下标
int index = (int) (i * betaChannels + j);
long count = 0;
//判断下标是否在h_counts范围内
if (index > 0 && index < h_counts.size()) {
count = h_counts.get(index);
}
sum+=count;
}
counts.add(sum);
}
return counts;
}
/**
* 根据ROI卡出来的Gamma数据生成新的GammaPHD文件
* @param pathName 文件存储路径
* @param fileName GammaPHD名称
* @param struct BetaPHD内容
* @param g_counts ROI卡出来的Gamma数据
*/
public void createGammaFile(String pathName,String fileName, EnergySpectrumStruct struct, List<Long> g_counts) {
File file = new File(pathName + "\\" + fileName);
// 创建PrintWriter对象
PrintWriter out = null;
DecimalFormat decimalFormat = new DecimalFormat("0.000000");
try {
out = new PrintWriter(file);
out.println("BEGIN IMS2.0");
out.println("MSG_TYPE DATA");
// todo msg_type用的不对dll没解析出这个字段
out.println("MSG_ID " + struct.msg_id + " " + struct.msg_type + "\n" + "DATA_TYPE " + struct.data_type);
out.println("#Header 3");
// 解析出的Gamma谱 系统类型暂时使用G
out.println(struct.site_code + " " + struct.detector_code + " C " +
struct.sample_geometry + " " + struct.spectrum_quantity);
out.println(struct.sample_ref_id);
out.println(struct.measurement_id + " " + struct.detector_bk_measurement_id + " 0");
out.println(struct.transmit_date + " " + struct.transmit_time);
out.println("#Collection");
out.println(struct.collection_start_date + " " + struct.collection_start_time + " " +
struct.collection_stop_date + " " + struct.collection_stop_time + " "
+ decimalFormat.format(struct.air_volume));
out.println("#Acquisition");
out.println(struct.acquisition_start_date + " " + struct.acquisition_start_time + " " +
decimalFormat.format(struct.acquisition_real_time) + " " +
decimalFormat.format(struct.acquisition_live_time));
out.println("#g_Energy");
format(struct.g_energy, struct.g_centroid_channel, struct.g_uncertainty, out);
out.println("#g_Resolution");
format(struct.g_r_energy, struct.g_r_FWHM, struct.g_r_uncertainty, out);
out.println("#g_Efficiency");
format(struct.g_e_energy, struct.g_e_efficiency, struct.g_e_uncertainty, out);
out.println("#g_Spectrum");
// num_g_channel 根据g_counts数量得来和PHD写的数字没有关系g_energy_span是PHD写的值
out.println(struct.num_g_channel + " " + struct.g_energy_span);
// 存储前一个数字
String beforeStr = "";
for (int i = 0; i < g_counts.size(); i++) {
String str = g_counts.get(i).toString();
if(i % 5 == 0) {
if (i == 0) {
out.printf((i+1)+"");
} else {
out.printf("\n" + (i+1) );
}
beforeStr = i+"";
}
if(StrUtil.isEmpty(beforeStr)){
beforeStr = str;
}
// 根据前一个字符长度计算需要的空格
out.printf("%" + (str.length() + (6 - beforeStr.length()))+ "s" , g_counts.get(i));
if(i == g_counts.size() - 1) {
out.println();
}
beforeStr = str;
}
out.print("STOP");
} catch (FileNotFoundException e) {
throw new RuntimeException(e);
} finally {
if (null != out) {
out.close();
}
}
}
/**
* 数据格式化
* @param aList 第一列数据
* @param bList 第二列数据
* @param cList 第三列数据
* @param out
*/
private static void format(List<Double> aList, List<Double> bList,List<Double> cList,PrintWriter out) {
for (int i = 0; i < aList.size(); i++) {
DecimalFormat decimalFormat = new DecimalFormat("0.000000");
String a = decimalFormat.format(aList.get(i));
String b = decimalFormat.format(bList.get(i));
String c = decimalFormat.format(cList.get(i));
out.print(a);
out.printf("%" + ( b.length() + (17 - a.length())) + "s", b);
out.printf("%" + ( c.length() + (17 - b.length())) + "s", c+"\n");
}
}
/**
* 根据DLL解析GammaPHD内容 得到PHDFile实体
* @param fileName
* @param pathName
* @return
*/
public PHDFile getGammaPHD(String fileName, String pathName) {
PHDFile phd = new PHDFile();
phd.setFilepath(pathName);
phd.setFilename(fileName);
File file = new File(pathName + StringPool.SLASH + fileName);
phd.setTmpFilePath(file.getAbsolutePath());
try {
//读取文件信息
EnergySpectrumStruct struct = EnergySpectrumHandler.getSourceData(file.getAbsolutePath());
//MsgInfo
phd.getMsgInfo().setMsg_id(struct.msg_id);
phd.getMsgInfo().setMsg_type(struct.msg_type);
phd.getMsgInfo().setData_type(struct.data_type);
//Header
phd.getHeader().setDesignator(struct.designator);
phd.getHeader().setSite_code(struct.site_code);
phd.getHeader().setDetector_code(struct.detector_code);
phd.getHeader().setSystem_type(struct.system_type);
phd.getHeader().setSample_geometry(struct.sample_geometry);
phd.getHeader().setSpectrum_quantity(struct.spectrum_quantity);
phd.getHeader().setSample_ref_id(struct.sample_ref_id);
phd.getHeader().setMeasurement_id(struct.measurement_id);
phd.getHeader().setDetector_bk_measurement_id(struct.detector_bk_measurement_id);
phd.getHeader().setGas_bk_measurement_id(struct.gas_bk_measurement_id);
phd.getHeader().setTransmit_date(struct.transmit_date);
phd.getHeader().setTransmit_time(struct.transmit_time);
//Comment
phd.setOriTotalCmt(struct.comment);
//Collection
if (StrUtil.isNotBlank(struct.collection_start_date) && StrUtil.isNotBlank(struct.collection_start_time)
&& StrUtil.isNotBlank(struct.collection_stop_date) && StrUtil.isNotBlank(struct.collection_stop_time)
&& Objects.nonNull(struct.air_volume)) {
phd.getCollect().setCollection_start_date(struct.collection_start_date);
phd.getCollect().setCollection_start_time(struct.collection_start_time);
phd.getCollect().setCollection_stop_date(struct.collection_stop_date);
phd.getCollect().setCollection_stop_time(struct.collection_stop_time);
phd.getCollect().setAir_volume(struct.air_volume);
if (phd.getCollect().getCollection_start_time().indexOf('.') < 0) {
phd.getCollect().setCollection_start_time(phd.getCollect().getCollection_start_time() + ".0");
}
if (phd.getCollect().getCollection_stop_time().indexOf('.') < 0) {
phd.getCollect().setCollection_stop_time(phd.getCollect().getCollection_stop_time() + ".0");
}
} else {
phd.getCollect().setAir_volume(0.0);
}
//Acquisition
if (StrUtil.isNotBlank(struct.acquisition_start_date) && StrUtil.isNotBlank(struct.acquisition_start_time)
&& Objects.nonNull(struct.acquisition_real_time) && Objects.nonNull(struct.acquisition_live_time)) {
phd.getAcq().setAcquisition_start_date(struct.acquisition_start_date);
phd.getAcq().setAcquisition_start_time(struct.acquisition_start_time);
phd.getAcq().setAcquisition_real_time(struct.acquisition_real_time);
phd.getAcq().setAcquisition_live_time(struct.acquisition_live_time);
if (phd.getAcq().getAcquisition_start_time().indexOf('.') < 0) {
phd.getAcq().setAcquisition_start_time(phd.getAcq().getAcquisition_start_time() + ".0");
}
} else {
phd.getAcq().setAcquisition_live_time(0.0);
phd.getAcq().setAcquisition_real_time(0.0);
}
//Processing
if (Objects.nonNull(struct.sample_volume_of_Xe) && Objects.nonNull(struct.uncertainty_1)
&& Objects.nonNull(struct.Xe_collection_yield) && Objects.nonNull(struct.uncertainty_2)
&& StrUtil.isNotBlank(struct.archive_bottle_id)) {
phd.getProcess().setSample_volume_of_Xe(struct.sample_volume_of_Xe);
phd.getProcess().setUncertainty_1(struct.uncertainty_1);
phd.getProcess().setXe_collection_yield(struct.Xe_collection_yield);
phd.getProcess().setUncertainty_2(struct.uncertainty_2);
phd.getProcess().setArchive_bottle_id(struct.archive_bottle_id);
} else {
phd.getProcess().setSample_volume_of_Xe(0.0);
phd.getProcess().setXe_collection_yield(0.0);
phd.getProcess().setUncertainty_1(0.0);
phd.getProcess().setUncertainty_2(0.0);
}
//Sample
if (Objects.nonNull(struct.dimension_1) && Objects.nonNull(struct.dimension_2)) {
phd.getSampleBlock().setDimension_1(struct.dimension_1);
phd.getSampleBlock().setDimension_2(struct.dimension_2);
} else {
phd.getSampleBlock().setDimension_1(0.0);
phd.getSampleBlock().setDimension_2(0.0);
}
//Calibration
if (StrUtil.isNotBlank(struct.date_calibration) && StrUtil.isNotBlank(struct.time_calibration)) {
phd.getCalibration().setDate_calibration(struct.date_calibration);
phd.getCalibration().setTime_calibration(struct.time_calibration);
}
//Certificate
if (Objects.nonNull(struct.total_source_activity) && StrUtil.isNotBlank(struct.assay_date)
&& StrUtil.isNotBlank(struct.assay_time) && StrUtil.isNotBlank(struct.units_activity)
&& CollectionUtils.isNotEmpty(struct.nuclide_name)
&& CollectionUtils.isNotEmpty(struct.half_life_time) && CollectionUtils.isNotEmpty(struct.time_unit)
&& CollectionUtils.isNotEmpty(struct.activity_nuclide_time_assay) && CollectionUtils.isNotEmpty(struct.uncertainty)
&& CollectionUtils.isNotEmpty(struct.cer_g_energy) && CollectionUtils.isNotEmpty(struct.g_intensity)
&& CollectionUtils.isNotEmpty(struct.electron_decay_mode) && CollectionUtils.isNotEmpty(struct.maximum_energy)
&& CollectionUtils.isNotEmpty(struct.intensity_b_particle) && Objects.nonNull(struct.record_count)) {
phd.getCertificate().setTotal_source_activity(struct.total_source_activity);
phd.getCertificate().setAssay_date(struct.assay_date);
phd.getCertificate().setAssay_time(struct.assay_time);
phd.getCertificate().setUnits_activity(struct.units_activity);
phd.getCertificate().setNuclide_name(struct.nuclide_name);
phd.getCertificate().setHalf_life_time(struct.half_life_time);
phd.getCertificate().setTime_unit(struct.time_unit);
phd.getCertificate().setActivity_nuclide_time_assay(struct.activity_nuclide_time_assay);
phd.getCertificate().setUncertainty(struct.uncertainty);
phd.getCertificate().setG_energy(struct.cer_g_energy);
phd.getCertificate().setG_intensity(struct.g_intensity);
phd.getCertificate().setElectron_decay_mode(struct.electron_decay_mode);
phd.getCertificate().setMaximum_energy(struct.maximum_energy);
phd.getCertificate().setIntensity_b_particle(struct.intensity_b_particle);
phd.getCertificate().setRecord_count(struct.record_count);
}
//g_Spectrum
if (Objects.nonNull(struct.num_g_channel) && Objects.nonNull(struct.g_energy_span)
&& Objects.nonNull(struct.g_begin_channel) && CollectionUtils.isNotEmpty(struct.g_counts)) {
phd.getSpec().setNum_g_channel(struct.g_counts.size()); // todo 原Num_g_channel有误
phd.getSpec().setG_energy_span(struct.g_energy_span);
phd.getSpec().setBegin_channel(struct.g_begin_channel);
phd.getSpec().setCounts(struct.g_counts);
int i = 0;
for (; i < phd.getSpec().getNum_g_channel(); i++) {
if (phd.getSpec().getCounts().get(i) > 0) {
break;
}
}
if (i == phd.getSpec().getNum_g_channel()) {
phd.setValid(false);
}
}
//g_Energy
if (CollectionUtils.isNotEmpty(struct.g_energy) && CollectionUtils.isNotEmpty(struct.g_centroid_channel) &&
CollectionUtils.isNotEmpty(struct.g_uncertainty) && Objects.nonNull(struct.g_record_count)) {
GEnergyBlock gEnergyBlock = new GEnergyBlock();
gEnergyBlock.setG_energy(struct.g_energy);
gEnergyBlock.setCentroid_channel(struct.g_centroid_channel);
gEnergyBlock.setUncertainty(struct.g_uncertainty);
gEnergyBlock.setRecord_count(struct.g_record_count);
phd.getMapEnerKD().put(CalName.CalPHD.getType(), gEnergyBlock);
}
//g_Resolution
if (CollectionUtils.isNotEmpty(struct.g_r_energy) && CollectionUtils.isNotEmpty(struct.g_r_FWHM) &&
CollectionUtils.isNotEmpty(struct.g_r_uncertainty) && Objects.nonNull(struct.g_r_record_count)) {
GResolutionBlock gResolutionBlock = new GResolutionBlock();
gResolutionBlock.setG_energy(struct.g_r_energy);
gResolutionBlock.setFWHM(struct.g_r_FWHM);
gResolutionBlock.setUncertainty(struct.g_r_uncertainty);
gResolutionBlock.setRecord_count(struct.g_r_record_count);
phd.getMapResoKD().put(CalName.CalPHD.getType(), gResolutionBlock);
}
//g_Efficiency
if (CollectionUtils.isNotEmpty(struct.g_e_energy) && CollectionUtils.isNotEmpty(struct.g_e_efficiency) &&
CollectionUtils.isNotEmpty(struct.g_e_uncertainty) && Objects.nonNull(struct.g_e_record_count)) {
GEfficiencyBlock gEfficiencyBlock = new GEfficiencyBlock();
gEfficiencyBlock.setG_energy(struct.g_e_energy);
gEfficiencyBlock.setEfficiency(struct.g_e_efficiency);
gEfficiencyBlock.setUncertainty(struct.g_e_uncertainty);
gEfficiencyBlock.setRecord_count(struct.g_e_record_count);
phd.getMapEffiKD().put(CalName.CalPHD.getType(), gEfficiencyBlock);
}
//TotalEff
if (CollectionUtils.isNotEmpty(struct.t_g_energy) && CollectionUtils.isNotEmpty(struct.total_efficiency) &&
CollectionUtils.isNotEmpty(struct.t_uncertainty) && Objects.nonNull(struct.t_record_count)) {
TotaleffBlock totaleffBlock = new TotaleffBlock();
totaleffBlock.setG_energy(struct.t_g_energy);
totaleffBlock.setTotal_efficiency(struct.total_efficiency);
totaleffBlock.setUncertainty(struct.t_uncertainty);
totaleffBlock.setRecord_count(struct.t_record_count);
phd.getMapTotEKD().put(CalName.CalPHD.getType(), totaleffBlock);
}
// 初始化默认分析设置
if(phd.getHeader().getSystem_type().equalsIgnoreCase("P")) {
phd.getSetting().setECutAnalysis_Low(35.0);
phd.getSetting().setBUpdateCal(true);
}
if (StrUtil.isNotBlank(phd.getCollect().getCollection_start_date())
&& StrUtil.isNotBlank(phd.getCollect().getCollection_start_time())) {
phd.getSetting().setRefTime_conc(DateUtils.parseDate(phd.getCollect().getCollection_start_date()
+ StringPool.SPACE + phd.getCollect().getCollection_start_time()));
}
if (StrUtil.isNotBlank(phd.getAcq().getAcquisition_start_date()) && StrUtil.isNotBlank(phd.getAcq().getAcquisition_start_time())) {
phd.getSetting().setRefTime_act(DateUtils.parseDate(phd.getAcq().getAcquisition_start_date()
+ StringPool.SPACE + phd.getAcq().getAcquisition_start_time()));
}
SpecSetup usedSetting = new SpecSetup();
BeanUtils.copyProperties(phd.getSetting(), usedSetting);
phd.setUsedSetting(usedSetting);
phd.setBAnalyed(false);
phd.setAnaly_start_time(DateUtils.formatDate(new Date(), "yyyy/MM/dd HH:mm:ss"));
} catch (Exception e) {
throw new RuntimeException(e);
}
return phd;
}
}

View File

@ -0,0 +1,9 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsAnalySetting;
import org.jeecg.modules.base.entity.rnman.GardsAnalySettingRoi;
public interface GardsAnalySettingRoiMapper extends BaseMapper<GardsAnalySettingRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsAnalysisRoi;
public interface GardsAnalysisRoiManMapper extends BaseMapper<GardsAnalysisRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsAnalysisRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsAnalysisRoiMapper extends BaseMapper<GardsAnalysisRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsCalibrationPairsRoi;
public interface GardsCalibrationPairsRoiManMapper extends BaseMapper<GardsCalibrationPairsRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsCalibrationPairsRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsCalibrationPairsRoiMapper extends BaseMapper<GardsCalibrationPairsRoi> {
}

View File

@ -0,0 +1,14 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnman.GardsCalibrationRoi;
import java.util.List;
public interface GardsCalibrationRoiManMapper extends BaseMapper<GardsCalibrationRoi> {
@InterceptorIgnore(tenantLine = "true")
int createBatch(@Param("calibrationRois") List<GardsCalibrationRoi> calibrationRois);
}

View File

@ -0,0 +1,15 @@
package org.jeecg.modules.mapper;
import java.util.List;
import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsCalibration;
import org.jeecg.modules.base.entity.rnauto.GardsCalibrationRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
public interface GardsCalibrationRoiMapper extends BaseMapper<GardsCalibrationRoi> {
@InterceptorIgnore(tenantLine = "true")
int createBatch(@Param("calibrationRois") List<GardsCalibrationRoi> calibrationRois);
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsMDCRoi;
public interface GardsMdcRoiManMapper extends BaseMapper<GardsMDCRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsMDCRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsMdcRoiMapper extends BaseMapper<GardsMDCRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsNuclIdedRoi;
public interface GardsNuclIdedRoiManMapper extends BaseMapper<GardsNuclIdedRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsNuclIdedRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsNuclIdedRoiMapper extends BaseMapper<GardsNuclIdedRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsNuclLinesIdedRoi;
public interface GardsNuclLinesIdedRoiManMapper extends BaseMapper<GardsNuclLinesIdedRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsNuclLinesIdedRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsNuclLinesIdedRoiMapper extends BaseMapper<GardsNuclLinesIdedRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsPeaksRoi;
public interface GardsPeaksRoiManMapper extends BaseMapper<GardsPeaksRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsPeaksRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsPeaksRoiMapper extends BaseMapper<GardsPeaksRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.jeecg.modules.base.entity.rnman.GardsQcCheckRoi;
public interface GardsQcCheckRoiManMapper extends BaseMapper<GardsQcCheckRoi> {
}

View File

@ -0,0 +1,17 @@
package org.jeecg.modules.mapper;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.base.entity.rnauto.GardsQcCheckRoi;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface GardsQcCheckRoiMapper extends BaseMapper<GardsQcCheckRoi> {
}

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsAnalysisRoiMapper">
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsCalibrationPairsRoiMapper">
</mapper>

View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsCalibrationRoiManMapper">
<insert id="createBatch" parameterType="org.jeecg.modules.base.entity.rnman.GardsCalibrationRoi">
begin
<foreach collection="calibrationRois" separator=";" close=";" item="calibration">
insert into RNMAN.GARDS_CALIBRATION_ROI(
SAMPLE_ID,
ROI_ID,
IDANALYSIS,
SAMPLE_TYPE,
CALTYPE,
FUNCTION,
FUNCTIONDEF,
STARTOFRANGE,
ENDOFRANGE,
COEFF_STRING,
moddate)
values
(#{calibration.sampleId},
#{calibration.roiId},
#{calibration.idAnalysis},
#{calibration.sampleType},
#{calibration.calType},
#{calibration.function},
#{calibration.functionDef},
#{calibration.startOfRange},
#{calibration.endOfRange},
#{calibration.coeffString},
#{calibration.moddate})
</foreach>
end;
</insert>
</mapper>

View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsCalibrationRoiMapper">
<insert id="createBatch" parameterType="org.jeecg.modules.base.entity.rnauto.GardsCalibrationRoi">
begin
<foreach collection="calibrationRois" separator=";" close=";" item="calibration">
insert into RNAUTO.GARDS_CALIBRATION_ROI(
SAMPLE_ID,
ROI_ID,
IDANALYSIS,
SAMPLE_TYPE,
CALTYPE,
FUNCTION,
FUNCTIONDEF,
STARTOFRANGE,
ENDOFRANGE,
COEFF_STRING,
moddate)
values
(#{calibration.sampleId},
#{calibration.roiId},
#{calibration.idAnalysis},
#{calibration.sampleType},
#{calibration.calType},
#{calibration.function},
#{calibration.functionDef},
#{calibration.startOfRange},
#{calibration.endOfRange},
#{calibration.coeffString},
#{calibration.moddate})
</foreach>
end;
</insert>
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsMdcRoiMapper">
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsNuclIdedRoiMapper">
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsNuclLinesIdedRoiMapper">
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsPeaksRoiMapper">
</mapper>

View File

@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.mapper.GardsQcCheckRoiMapper">
</mapper>

View File

@ -84,4 +84,5 @@ public class EnergySpectrumHandler {
public static native List<Double> GetFittingData(List<Double> data, String fitType, List<Double> fittingPara);
public static native String selfBgAnalyse(String PHDPath, String param);
}

View File

@ -98,6 +98,17 @@ public class EnergySpectrumStruct {
*/
public double acquisition_live_time;
/*************************** GPS Block ***********************/
/*
* 坐标: 经度值
* */
public double lon;
/*
* 坐标: 纬度值
* */
public double lat;
/************************* Collection Block ******************/
/**
@ -237,6 +248,22 @@ public class EnergySpectrumStruct {
public int g_e_record_count;
/************************* g_Efficiency Block ******************/
/**
* β -energy (keV)
*/
public List<Double> b_e_energy;
/**
* efficiency (counts in peak/photon emitted)
*/
public List<Double> b_e_efficiency;
/**
* uncertainty (counts in peak/photon emitted)
*/
public List<Double> b_e_uncertainty;
public int b_e_record_count;
/************************* ROI_Limits Block ******************/
/**
* ROI number

View File

@ -0,0 +1,33 @@
package org.jeecg.modules.native_jni.struct;
import java.util.LinkedList;
import java.util.List;
public class GPSSpectrumStruct {
public String stationCode;
public String receiveDate;
public String receiveTime;
public List<String> recordDateList;
public List<String> recordTimeList;
public List<String> spanTimeList;
public List<String> lonList;
public List<String> latList;
public GPSSpectrumStruct() {
recordDateList = new LinkedList<>();
recordTimeList = new LinkedList<>();
spanTimeList = new LinkedList<>();
lonList = new LinkedList<>();
latList = new LinkedList<>();
}
}

View File

@ -0,0 +1,28 @@
package org.jeecg.modules.native_jni.struct;
import org.jeecg.modules.entity.vo.ResultNuclide;
import java.util.LinkedList;
import java.util.List;
public class WaterResultStruct {
public String stationCode;
public String detectorCode;
public String sampleRefId;
public Double lon;
public Double lat;
public List<ResultNuclide> resultNuclideList;
public WaterResultStruct() {
resultNuclideList = new LinkedList<>();
}
}

View File

@ -0,0 +1,53 @@
package org.jeecg.modules.service;
import org.jeecg.modules.base.entity.rnman.GardsAnalyses;
import org.jeecg.modules.entity.vo.CalMDCInfo;
import org.jeecg.modules.entity.vo.GStoreMiddleProcessData;
import org.jeecg.modules.entity.vo.PHDFile;
import org.jeecg.modules.entity.vo.QcCheckItem;
import org.jeecg.modules.native_jni.struct.EnergySpectrumStruct;
import java.util.List;
import java.util.Map;
public interface AnalysisManService {
void middleDataTable(Integer idAnalysis, List<GStoreMiddleProcessData> middleDatas);
void saveAnalysisROI(Integer sampleId, Integer idAnalysis,EnergySpectrumStruct sampleStruct,
List<GStoreMiddleProcessData> middleDatas, List<String> phdFilePaths);
void deleteAnalysisROI(Integer idAnalysis);
void deleteCalibrationPairs(Integer idAnalysis);
void deleteCalibration(Integer idAnalysis);
void deletePeaks(Integer idAnalysis);
void deleteNuclLines(Integer idAnalysis);
void deleteNucl(Integer idAnalysis);
void deleteQCCheck(Integer idAnalysis);
void deleteMDC(Integer idAnalysis);
void deleteAnalySetting(Integer idAnalysis);
void saveCalibrationPairsROI(Integer sampleId, Integer idAnalysis);
void saveCalibrationROI(Integer sampleId, Integer idAnalysis);
void savePeaksROI(Integer sampleId, Integer idAnalysis);
void saveNuclLinesIdedROI(Integer sampleId, Integer idAnalysis);
void saveNuclIdedROI(Integer sampleId, Integer idAnalysis);
void saveQcCheckROI(Integer sampleId, Map<String, QcCheckItem> qcItems, Integer idAnalysis);
void saveMDCROI(Integer sampleId, List<Map<String, CalMDCInfo>> mdcInfoMaps, Integer idAnalysis);
void saveAnalySettingROI(Integer sampleId, Integer idAnalysis, List<PHDFile> phdFiles);
}

View File

@ -0,0 +1,10 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.rnman.GardsAnalySetting;
import org.jeecg.modules.base.entity.rnman.GardsAnalySettingRoi;
import org.jeecg.modules.entity.vo.PHDFile;
public interface IGardsAnalySettingRoiService extends IService<GardsAnalySettingRoi> {
}

View File

@ -0,0 +1,11 @@
package org.jeecg.modules.service;
import org.jeecg.modules.base.entity.rnauto.GardsAnalysisRoi;
import com.baomidou.mybatisplus.extension.service.IService;
import java.util.List;
public interface IGardsAnalysisRoiAutoService extends IService<GardsAnalysisRoi> {
List<GardsAnalysisRoi> analysisRoi(Integer idAnalysis);
}

View File

@ -0,0 +1,13 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.rnman.GardsAnalysisRoi;
import java.util.List;
public interface IGardsAnalysisRoiManService extends IService<GardsAnalysisRoi> {
Integer getIdAnalysisAny(Integer sampleId);
List<GardsAnalysisRoi> analysisRoi(Integer idAnalysis);
}

View File

@ -0,0 +1,14 @@
package org.jeecg.modules.service;
import org.jeecg.modules.base.entity.rnauto.GardsCalibrationPairsRoi;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* @Description:
* @Author: jeecg-boot
* @Date: 2024-07-24
* @Version: V1.0
*/
public interface IGardsCalibrationPairsRoiAutoService extends IService<GardsCalibrationPairsRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.rnman.GardsCalibrationPairsRoi;
public interface IGardsCalibrationPairsRoiManService extends IService<GardsCalibrationPairsRoi> {
}

View File

@ -0,0 +1,11 @@
package org.jeecg.modules.service;
import org.jeecg.modules.base.entity.rnauto.GardsCalibrationRoi;
import com.baomidou.mybatisplus.extension.service.IService;
import java.util.List;
public interface IGardsCalibrationRoiAutoService extends IService<GardsCalibrationRoi> {
int createBatch(List<GardsCalibrationRoi> calibrationRois);
}

View File

@ -0,0 +1,11 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.rnman.GardsCalibrationRoi;
import java.util.List;
public interface IGardsCalibrationRoiManService extends IService<GardsCalibrationRoi> {
int createBatch(List<GardsCalibrationRoi> calibrationRois);
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.service;
import org.jeecg.modules.base.entity.rnauto.GardsMDCRoi;
import com.baomidou.mybatisplus.extension.service.IService;
public interface IGardsMdcRoiAutoService extends IService<GardsMDCRoi> {
}

View File

@ -0,0 +1,8 @@
package org.jeecg.modules.service;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.modules.base.entity.rnman.GardsMDCRoi;
public interface IGardsMdcRoiManService extends IService<GardsMDCRoi> {
}

Some files were not shown because too many files have changed in this diff Show More