|
@@ -22,15 +22,15 @@ public class DataTask implements ITask {
|
|
|
List<Exams> exams = Exams.dao.use("zskk").find("SELECT * FROM pacsonline.exams where exam_status=3 and institution_id=81069903 order by createdAt desc limit 30");
|
|
|
for (Exams exams2 : exams) {
|
|
|
try {
|
|
|
-// Studies studies = Studies.dao.use("zskk").findById(exams2.getStudyId());
|
|
|
+ Studies studies = Studies.dao.use("zskk").findById(exams2.getStudyId());
|
|
|
|
|
|
- Record record = Db.use("connected").findFirst("SELECT * FROM zlhis.zskk_reportinfo_1 where STUDYUID=?",exams2.getAccessionNum());
|
|
|
+ Record record = Db.use("connected").findFirst("SELECT * FROM zlhis.zskk_reportinfo_1 where STUDYUID=?",studies.getStudyuid());
|
|
|
if (record == null) {
|
|
|
continue;
|
|
|
}
|
|
|
Report report = new Report().use("zskk");
|
|
|
report.setId(creatId());
|
|
|
- report.setReportDatetime(parseStringToDate(record.getStr("STUDY_DATE")));
|
|
|
+ report.setReportDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
if (record.getStr("IMPRESSION") == null && record.getStr("DESCRIPTION") == null) {
|
|
|
continue;
|
|
|
}
|
|
@@ -40,9 +40,9 @@ public class DataTask implements ITask {
|
|
|
report.setCreatedAt(new Date());
|
|
|
report.setReportDoctorId(getDoctorIdByName(record.getStr("REPORTDOCTOR")));
|
|
|
report.setReviewDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")));
|
|
|
- report.setReviewDatetime(parseStringToDate(record.getStr("STUDY_DATE")));
|
|
|
+ report.setReviewDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
report.setConfirmDoctorId(getDoctorIdByName(record.getStr("REVIEWDOCTOR")));
|
|
|
- report.setConfirmDatetime(parseStringToDate(record.getStr("STUDY_DATE")));
|
|
|
+ report.setConfirmDatetime(parseStringToDate(record.getStr("REPORTDATE")));
|
|
|
report.save();
|
|
|
PatientInfos patientInfos = PatientInfos.dao.use("zskk").findById(exams2.getPatientId());
|
|
|
patientInfos.setName(record.getStr("PATIENTNAME"));
|
|
@@ -94,7 +94,7 @@ public class DataTask implements ITask {
|
|
|
newDoctors.setUsername("none");
|
|
|
newDoctors.setRealname(name);
|
|
|
newDoctors.setPassword("123456");
|
|
|
- newDoctors.setInstitutionId("04500002");
|
|
|
+ newDoctors.setInstitutionId("81069903");
|
|
|
newDoctors.setCreatedAt(new Date());
|
|
|
newDoctors.setUpdatedAt(new Date());
|
|
|
newDoctors.save();
|