chenyongxing 7 年 前
コミット
c94bc5a53f

+ 9 - 6
patient-co-customization/patient-co-modern-medicine/src/main/java/com/yihu/mm/controller/medicine/PhysicalExaminationController.java

@ -104,7 +104,11 @@ public class PhysicalExaminationController extends BaseController {
        //查找居民是否已经答过该试题
        MedicineAnswerLog answer = medicineAnswerLogService.findAnswer(patientCode, examCode, _pb_id,ct_id);
        jsonQuestion.put("answer",(answer==null?"":answer.getProblems()));
        String answerStr="";
        if(answer!=null){
            answerStr = answer.getProblems().replace("\"","\\\"");
        }
        jsonQuestion.put("answer",answerStr);
        return jsonQuestion.toString();
    }
@ -114,10 +118,9 @@ public class PhysicalExaminationController extends BaseController {
    @ResponseBody
    public String handleExam(@ApiParam(name = "ct_id", value = "咨询编号", required = true)@RequestParam(required = true, name = "ct_id") String ct_id,
                               @ApiParam(name = "pb_id", value = "问卷编号,第一题为0", required = true)@RequestParam(required = true, name = "pb_id") String pb_id,
                                @ApiParam(name = "i_multiselect", value = "试题类型(0单选 ,1多选)", required = true)@RequestParam(required = true, name = "i_multiselect") String i_multiselect,
                                @ApiParam(name = "type", value = "试题类型(0单选 ,1多选)", required = true)@RequestParam(required = true, name = "type") String type,
                               @ApiParam(name = "dc_answer", value = "问题答案", required = true)@RequestParam(required = true, name = "dc_answer") String dc_answer,
                             @ApiParam(name = "patientCode", value = "居民code", required = true)@RequestParam(required = true, name = "patientCode") String patientCode,
                             @ApiParam(name = "isLast", value = "是否是最后一题(0否 ,1是)", required = true)@RequestParam(required = false, name = "isLast") String isLast){
                             @ApiParam(name = "patientCode", value = "居民code", required = true)@RequestParam(required = true, name = "patientCode") String patientCode){
        PatientExam patientExam = patientExamService.findByPatientAndTpId(patientCode, examCode,ct_id);
        String tpName = patientExam.getTpName();
        String result = physicalExaminationService.handleExam(examCode, pb_id, dc_answer, ct_id);
@ -133,7 +136,7 @@ public class PhysicalExaminationController extends BaseController {
            answer.setTpName(tpName);
            answer.setCtId(ct_id);
        }
        answer.setPbType(String.valueOf(i_multiselect));
        answer.setPbType(String.valueOf(type));
        answer.setProblems(dc_answer);
        medicineAnswerLogService.save(answer);
        return result;
@ -162,7 +165,7 @@ public class PhysicalExaminationController extends BaseController {
    }
    @ApiOperation(value = "查看报告单")
    @RequestMapping(value = "/findconconhealth",produces="application/json;charset=UTF-8")
    @RequestMapping(value = "/showDetail",produces="application/json;charset=UTF-8")
    @ResponseBody
    public String showDetail(@ApiParam(name = "patientCode", value = "居民code", required = false)@RequestParam(required = true, name = "patientCode") String patientCode,
            @ApiParam(name = "ct_id", value = "咨询编号", required = false)@RequestParam(required = false, name = "ct_id") String ct_id){