diff --git a/ht/src/main/java/com/ccsens/ht/service/QuestionService.java b/ht/src/main/java/com/ccsens/ht/service/QuestionService.java index a1f13a95..92bb5920 100644 --- a/ht/src/main/java/com/ccsens/ht/service/QuestionService.java +++ b/ht/src/main/java/com/ccsens/ht/service/QuestionService.java @@ -717,7 +717,7 @@ public class QuestionService implements IQuestionService { } lineParameter.setSpeed(speed); // 落笔总时间 - paintTime += Long.parseLong(e[e.length - 1]) - Long.parseLong(a[a.length - 1]); + paintTime += Long.parseLong(e[e.length - 1]) - Long.parseLong(s[s.length - 1]); //和上一笔的间隔 & 思考总时长 if(Long.parseLong(e[e.length - 1]) == 0){ lineParameter.setIntervalDuration(htPatientCanvas.getBeginTime() - htPatientCanvas.getOpenCanvasTime()); diff --git a/ht/src/main/resources/application.yml b/ht/src/main/resources/application.yml index d082c0ea..5889ff7f 100644 --- a/ht/src/main/resources/application.yml +++ b/ht/src/main/resources/application.yml @@ -1,4 +1,4 @@ spring: profiles: - active: prod - include: common, util-prod \ No newline at end of file + active: test + include: common, util-test \ No newline at end of file diff --git a/question/src/main/java/com/ccsens/question/service/PatientReportService.java b/question/src/main/java/com/ccsens/question/service/PatientReportService.java index 2ad9b1df..39959c48 100644 --- a/question/src/main/java/com/ccsens/question/service/PatientReportService.java +++ b/question/src/main/java/com/ccsens/question/service/PatientReportService.java @@ -69,33 +69,33 @@ public class PatientReportService implements IPatientReportService { public JsonResponse generatePatientReport(PatientReportDto.Generate generate, Long userId) { log.info("生成报告单请求参数:userId:{}, patientReport:{}", userId, generate); //查询医生信息 - HtDoctorExample doctorExample = new HtDoctorExample(); - doctorExample.createCriteria().andUserIdEqualTo(userId).andAuditStateEqualTo(Constant.Ht.Doctor.CHECK_SUCCESS).andIsDelEqualTo(Constant.Ht.NUMBER_DEFAULT); - List doctors = htDoctorDao.selectByExample(doctorExample); - if (CollectionUtils.isEmpty(doctors)) { - log.info("根据userId未找到审核通过的医生信息:{}", userId); - return JsonResponse.newInstance().ok(CodeEnum.PARAM_ERROR); - } - //查询病人信息 - HtPatient htPatient = htPatientMapper.selectByPrimaryKey(generate.getPatientId()); - if (htPatient == null) { - log.info("根据patientId未找到病友信息:{}", generate.getPatientId()); - return JsonResponse.newInstance().ok(CodeEnum.PARAM_ERROR); - } +// HtDoctorExample doctorExample = new HtDoctorExample(); +// doctorExample.createCriteria().andUserIdEqualTo(userId).andAuditStateEqualTo(Constant.Ht.Doctor.CHECK_SUCCESS).andIsDelEqualTo(Constant.Ht.NUMBER_DEFAULT); +// List doctors = htDoctorDao.selectByExample(doctorExample); +// if (CollectionUtils.isEmpty(doctors)) { +// log.info("根据userId未找到审核通过的医生信息:{}", userId); +// return JsonResponse.newInstance().ok(CodeEnum.PARAM_ERROR); +// } +// //查询病人信息 +// HtPatient htPatient = htPatientMapper.selectByPrimaryKey(generate.getPatientId()); +// if (htPatient == null) { +// log.info("根据patientId未找到病友信息:{}", generate.getPatientId()); +// return JsonResponse.newInstance().ok(CodeEnum.PARAM_ERROR); +// } HtPatientReport htPatientReport = new HtPatientReport(); htPatientReport.setId(snowflake.nextId()); - htPatientReport.setDoctorId(doctors.get(0).getId()); +// htPatientReport.setDoctorId(doctors.get(0).getId()); htPatientReport.setPatientId(generate.getPatientId()); - htPatientReport.setPatientIdcard(htPatient.getIdcard()); - htPatientReport.setPatientAge(StrUtil.isEmpty(htPatient.getIdcard()) ? null : (byte)IdcardUtil.getAgeByIdCard(htPatient.getIdcard())); +// htPatientReport.setPatientIdcard(htPatient.getIdcard()); +// htPatientReport.setPatientAge(StrUtil.isEmpty(htPatient.getIdcard()) ? null : (byte)IdcardUtil.getAgeByIdCard(htPatient.getIdcard())); htPatientReport.setEvaluationCode(Constant.Ht.Report.PARENT_CODE); htPatientReport.setName(Constant.Ht.Report.PARENT_NAME + DateUtil.today()); htPatientReport.setReportTime(System.currentTimeMillis()); // 查询医院信息 - String hospital = htPositionDao.queryHospital(doctors.get(0).getPositionId()); - htPatientReport.setHospital(hospital); +// String hospital = htPositionDao.queryHospital(doctors.get(0).getPositionId()); +// htPatientReport.setHospital(hospital); htPatientReportDao.insertSelective(htPatientReport); log.info("生成病友报告单:{}", generate); PatientReportVo.Generate generateVo = new PatientReportVo.Generate();