|
@@ -48,24 +48,24 @@ public class DataTask implements ITask {
|
|
|
Report report = new Report().use("zskk");
|
|
|
report.setId(creatId());
|
|
|
report.setReportDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
- if (record.getStr("description") == null || record.getStr("IMPRESSION") == null
|
|
|
- || record.getStr("description").isBlank()) {
|
|
|
+ if (record.getStr("DESCRIPTION") == null || record.getStr("IMPRESSION") == null
|
|
|
+ || record.getStr("DESCRIPTION").isBlank()) {
|
|
|
continue;
|
|
|
}
|
|
|
- report.setImpression(record.getStr("description"));
|
|
|
+ report.setImpression(record.getStr("DESCRIPTION"));
|
|
|
report.setDescription(record.getStr("IMPRESSION"));
|
|
|
report.setExamId(exams2.getId());
|
|
|
report.setCreatedAt(new Date());
|
|
|
- report.setReportDoctorId(getDoctorIdByName(record.getStr("REPORTDOCTOR")));
|
|
|
- report.setReviewDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")));
|
|
|
+ report.setReportDoctorId(getDoctorIdByName(record.getStr("REPORTDOCTOR")==null?"":record.getStr("REPORTDOCTOR")));
|
|
|
+ report.setReviewDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR")));
|
|
|
report.setReviewDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
- report.setConfirmDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")));
|
|
|
+ report.setConfirmDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR")));
|
|
|
report.setConfirmDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
report.save();
|
|
|
PatientInfos patientInfos = PatientInfos.dao.use("zskk").findById(exams2.getPatientId());
|
|
|
patientInfos.setName(record.getStr("PATIENTNAME"));
|
|
|
- patientInfos.setPhone(record.getStr("PHONE"));
|
|
|
- patientInfos.setCardNum(record.getStr("IDCARD"));
|
|
|
+ patientInfos.setPhone(record.getStr("PHONE")==null?"":record.getStr("PHONE"));
|
|
|
+ patientInfos.setCardNum(record.getStr("IDCARD")==null?"":record.getStr("IDCARD"));
|
|
|
patientInfos.update();
|
|
|
exams2.setExamStatus(9);
|
|
|
// String patString = record.getStr("住院号");
|
|
@@ -73,8 +73,8 @@ public class DataTask implements ITask {
|
|
|
// patString = String.format("%0"+length+"d",Long.valueOf(patString));
|
|
|
// exams2.setHopitalizedNo(patString);
|
|
|
// exams2.setClinDoctors(record.getStr("CLINICALDOCTOR"));
|
|
|
- exams2.setApplicationDepartment(record.getStr("DEPARTMENT"));
|
|
|
- exams2.setApplicationDoctor(record.getStr("CLINICALDOCTOR"));
|
|
|
+// exams2.setApplicationDepartment(record.getStr("DEPARTMENT"));
|
|
|
+ exams2.setApplicationDoctor(record.getStr("CLINICALDOCTOR")==null?"":record.getStr("CLINICALDOCTOR"));
|
|
|
// exams2.setClinDiag(record.getStr("diagnosis"));
|
|
|
exams2.update();
|
|
|
// 传云医康 数据
|
|
@@ -83,7 +83,7 @@ public class DataTask implements ITask {
|
|
|
// 医院id
|
|
|
data.put("hospital_id", "02400005");
|
|
|
// 影像所见
|
|
|
- data.put("description", record.getStr("description"));
|
|
|
+ data.put("description", record.getStr("DESCRIPTION"));
|
|
|
// 意见建议
|
|
|
data.put("impression", record.getStr("IMPRESSION"));
|
|
|
// 检查id
|
|
@@ -96,9 +96,9 @@ public class DataTask implements ITask {
|
|
|
// 患者性别
|
|
|
data.put("patient_sex", patientInfos.getSex());
|
|
|
// 身份证号
|
|
|
- data.put("card_num", record.getStr("IDCARD"));
|
|
|
+ data.put("card_num", record.getStr("IDCARD")==null?"":record.getStr("IDCARD"));
|
|
|
// 手机号
|
|
|
- data.put("phone", patientInfos.getPhone());
|
|
|
+ data.put("phone", record.getStr("PHONE")==null?"":record.getStr("PHONE"));
|
|
|
// 患者生日
|
|
|
data.put("birthday", patientInfos.getBirthday());
|
|
|
// 患者检查时年龄
|
|
@@ -108,28 +108,29 @@ public class DataTask implements ITask {
|
|
|
// 报告时间 10位时间戳
|
|
|
data.put("report_datetime", returnSecondTimestamp(record.getStr("REPORTDATE")));
|
|
|
// 报告医生id
|
|
|
- data.put("report_doctor_id", record.getStr("REPORTDOCTOR"));
|
|
|
+ data.put("report_doctor_id", record.getStr("REPORTDOCTOR")==null?"":record.getStr("REPORTDOCTOR"));
|
|
|
// 报告医生姓名
|
|
|
- data.put("report_doctor_name", record.getStr("REPORTDOCTOR"));
|
|
|
+ data.put("report_doctor_name", record.getStr("REPORTDOCTOR")==null?"":record.getStr("REPORTDOCTOR"));
|
|
|
// 审核时间
|
|
|
data.put("review_datetime", returnSecondTimestamp(record.getStr("REPORTDATE")));
|
|
|
// 审核医生id
|
|
|
- data.put("review_doctor_id", record.getStr("REVIEWDOCTOR"));
|
|
|
+ data.put("review_doctor_id", record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR"));
|
|
|
// 审核姓名
|
|
|
- data.put("review_doctor_name", record.getStr("REVIEWDOCTOR"));
|
|
|
+ data.put("review_doctor_name", record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR"));
|
|
|
// 确认时间
|
|
|
data.put("confirm_datetime", returnSecondTimestamp(record.getStr("REPORTDATE")));
|
|
|
// 确认医生id
|
|
|
- data.put("confirm_doctor_id", record.getStr("REVIEWDOCTOR"));
|
|
|
+ data.put("confirm_doctor_id", record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR"));
|
|
|
// 确认医生姓名
|
|
|
- data.put("confirm_doctor_name", record.getStr("REVIEWDOCTOR"));
|
|
|
+ data.put("confirm_doctor_name", record.getStr("REVIEWDOCTOR")==null?"":record.getStr("REVIEWDOCTOR"));
|
|
|
data.put("patient_no", "");
|
|
|
|
|
|
|
|
|
ThreadPoolService tService = new com.zskk.service.ThreadPoolService();
|
|
|
tService.execute(() -> {
|
|
|
String dadaString = JSON.toJSONString(data);
|
|
|
- dadaString = dadaString.replace("\\r\\n", "");
|
|
|
+ dadaString = dadaString.replace("\\n", "");
|
|
|
+ dadaString = dadaString.replace("\\r", "");
|
|
|
dadaString = dadaString.replace("*", "X");
|
|
|
dadaString = dadaString.replace("<p>", "");
|
|
|
dadaString = dadaString.replace("<br/>", "");
|