Browse Source

20210107未选择病人点试题报错

sd
zy_Java 5 years ago
parent
commit
58dd4f9f6f
  1. 14
      ht/src/main/java/com/ccsens/ht/service/QuestionService.java

14
ht/src/main/java/com/ccsens/ht/service/QuestionService.java

@ -86,12 +86,14 @@ public class QuestionService implements IQuestionService {
QuestionVo.Question questionVo = QuestionVo.Question.toQuestionVo(question); QuestionVo.Question questionVo = QuestionVo.Question.toQuestionVo(question);
//检查当前试题是否有答案,共享答案的试题是否有答案 //检查当前试题是否有答案,共享答案的试题是否有答案
boolean f = false; boolean f = false;
HtPatientScoreExample scoreExample = new HtPatientScoreExample(); if(ObjectUtil.isNotNull(query.getPatientReportId())){
scoreExample.createCriteria().andPatientReportIdEqualTo(query.getPatientReportId()).andQuestionIdEqualTo(question.getId()) HtPatientScoreExample scoreExample = new HtPatientScoreExample();
.andTypeBetween((byte)0,(byte)1); scoreExample.createCriteria().andPatientReportIdEqualTo(query.getPatientReportId()).andQuestionIdEqualTo(question.getId())
if(htPatientScoreDao.countByExample(scoreExample) > 0){ .andTypeBetween((byte)0,(byte)1);
f = true; if(htPatientScoreDao.countByExample(scoreExample) > 0){
questionVo.setShowShareAnswer((byte) 0); f = true;
questionVo.setShowShareAnswer((byte) 0);
}
} }
//查询可以共享答案的试题的id //查询可以共享答案的试题的id

Loading…
Cancel
Save