|
@@ -26,14 +26,16 @@ public class DataTask implements ITask {
|
|
|
for (Object object : jsonArray) {
|
|
|
try {
|
|
|
JSONObject jsonObject = JSON.parseObject(object.toString());
|
|
|
- Record record = Db.use("connected").findFirst("select * from reportcheck where studyuid=?", jsonObject.getString("studyuid"));
|
|
|
- if (record == null) {
|
|
|
+ Record record1 = Db.use("connected").findFirst("select * from V_EXAM_INFO where 检查号=? and 检查状态=4", jsonObject.getString("patient_num"));
|
|
|
+ if (record1 == null) {
|
|
|
continue;
|
|
|
}
|
|
|
+ Record record2 = Db.use("connected").findFirst("select * from V_EXAM_REPORT where 检查号=?", jsonObject.getString("patient_num"));
|
|
|
+
|
|
|
// if (parseStringToDate(record.getStr("checktime"))==Boolean.FALSE) {
|
|
|
// continue;
|
|
|
// }
|
|
|
- if (record.getStr("impression").isBlank() || record.getStr("description").isBlank()) {
|
|
|
+ if (record2.getStr("检查所见").isBlank() || record2.getStr("影像诊断").isBlank()) {
|
|
|
continue;
|
|
|
}
|
|
|
Map<String, String> params = new HashMap<>();
|
|
@@ -44,43 +46,43 @@ public class DataTask implements ITask {
|
|
|
|
|
|
params.put("code", jsonObject.getString("id"));
|
|
|
//报告医生姓名
|
|
|
- params.put("report_doctor_name", record.getStr("reportdoctor"));
|
|
|
+ params.put("report_doctor_name", record2.getStr("报告医生姓名"));
|
|
|
//报告时间
|
|
|
- params.put("report_datetime", record.getStr("reportdate"));
|
|
|
+ params.put("report_datetime", record2.getStr("报告时间"));
|
|
|
//审核医生姓名
|
|
|
- params.put("review_doctor_name", record.getStr("reviewdoctor")==null?"":record.getStr("reviewdoctor"));
|
|
|
+ params.put("review_doctor_name", record2.getStr("审核医生姓名")==null?"":record2.getStr("审核医生姓名"));
|
|
|
//审核时间
|
|
|
- params.put("review_datetime", record.getStr("checktime"));
|
|
|
+ params.put("review_datetime", record2.getStr("审核时间"));
|
|
|
//确认医生姓名
|
|
|
- params.put("confirm_doctor_name", record.getStr("reviewdoctor")==null?"":record.getStr("reviewdoctor"));
|
|
|
+ params.put("confirm_doctor_name", record2.getStr("审核医生姓名")==null?"":record2.getStr("审核医生姓名"));
|
|
|
//确认时间
|
|
|
- params.put("confirm_datetime", record.getStr("checktime"));
|
|
|
+ params.put("confirm_datetime", record2.getStr("审核时间"));
|
|
|
//意见建议
|
|
|
- params.put("impression", record.getStr("impression"));
|
|
|
+ params.put("impression", record2.getStr("检查所见"));
|
|
|
//影像所见
|
|
|
- params.put("description", record.getStr("description"));
|
|
|
+ params.put("description", record2.getStr("影像诊断"));
|
|
|
//exams表
|
|
|
//申请科室
|
|
|
- params.put("application_department", record.getStr("department")==null?"":record.getStr("department"));
|
|
|
+ params.put("application_department", record1.getStr("就诊科室名称")==null?"":record1.getStr("就诊科室名称"));
|
|
|
//申请医生
|
|
|
- params.put("application_doctor", record.getStr("clinicaldoctor")==null?"":record.getStr("clinicaldoctor"));
|
|
|
+ params.put("application_doctor", record1.getStr("申请医师名称")==null?"":record1.getStr("申请医师名称"));
|
|
|
//临床诊断
|
|
|
params.put("clin_diag", "");
|
|
|
//症状
|
|
|
- params.put("clin_symp", record.getStr("symptom")==null?"":record.getStr("symptom"));
|
|
|
+ params.put("clin_symp", record1.getStr("主诉")==null?"":record1.getStr("主诉"));
|
|
|
//patient_infos表
|
|
|
//患者姓名
|
|
|
- params.put("name", record.getStr("patientname"));
|
|
|
+ params.put("name", record1.getStr("姓名"));
|
|
|
//患者手机号
|
|
|
- params.put("phone", record.getStr("phone")==null?"":record.getStr("phone"));
|
|
|
+ params.put("phone", record1.getStr("联系电话")==null?"":record1.getStr("联系电话"));
|
|
|
//患者身份证号
|
|
|
- params.put("card_num", record.getStr("idcard")==null?"":record.getStr("idcard"));
|
|
|
+ params.put("card_num", record1.getStr("证件号码")==null?"":record1.getStr("证件号码"));
|
|
|
//检查结果1阴2阳
|
|
|
params.put("report_result", "0");
|
|
|
//门诊号住院号
|
|
|
params.put("hopitalized_no", "");
|
|
|
- params.put("exam_project", record.getStr("JianchaMingcheng") == null ? "" : record.getStr("JianchaMingcheng"));
|
|
|
- params.put("exam_method", record.getStr("JianchaFangfa") == null ? "" : record.getStr("JianchaFangfa"));
|
|
|
+ params.put("exam_project", record1.getStr("标本部位") == null ? "" : record1.getStr("标本部位"));
|
|
|
+// params.put("exam_method", record.getStr("JianchaFangfa") == null ? "" : record.getStr("JianchaFangfa"));
|
|
|
ThreadPoolService tService = ServiceFactory.getService(ThreadPoolService.class);
|
|
|
tService.execute(() -> {
|
|
|
dService.saveReport(params);
|