|
|
|
@ -1,6 +1,11 @@
|
|
|
|
|
package com.supervision.manage.service.impl;
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.lang.Assert;
|
|
|
|
|
import cn.hutool.core.util.StrUtil;
|
|
|
|
|
import com.supervision.manage.service.DiseaseQuestionManageService;
|
|
|
|
|
import com.supervision.model.AskTemplateQuestionLibrary;
|
|
|
|
|
import com.supervision.model.DiseaseQuestion;
|
|
|
|
|
import com.supervision.service.AskTemplateQuestionLibraryService;
|
|
|
|
|
import com.supervision.vo.manage.DiseaseQuestionResVo;
|
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
@ -11,9 +16,35 @@ import java.util.List;
|
|
|
|
|
@RequiredArgsConstructor
|
|
|
|
|
public class DiseaseQuestionManageServiceImpl implements DiseaseQuestionManageService {
|
|
|
|
|
|
|
|
|
|
private final AskTemplateQuestionLibraryService askTemplateQuestionLibraryService;
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public List<DiseaseQuestionResVo> queryPageByDiseaseId(String diseaseId) {
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
public void batchSaveQuestionList(List<DiseaseQuestion> diseaseQuestionList) {
|
|
|
|
|
|
|
|
|
|
/*Assert.notEmpty(diseaseQuestionList,"数据为空");
|
|
|
|
|
diseaseQuestionList.forEach(this::assertDiseaseQuestion);*/
|
|
|
|
|
List<AskTemplateQuestionLibrary> list = askTemplateQuestionLibraryService.lambdaQuery().or(
|
|
|
|
|
|
|
|
|
|
(t)->askTemplateQuestionLibraryService.lambdaQuery().eq(AskTemplateQuestionLibrary::getCode,"cod")).list();
|
|
|
|
|
|
|
|
|
|
System.out.println("dd");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private void assertDiseaseQuestion(DiseaseQuestion diseaseQuestion){
|
|
|
|
|
|
|
|
|
|
Assert.isTrue(StrUtil.isEmpty(diseaseQuestion.getId()),"id需要为空");
|
|
|
|
|
|
|
|
|
|
Assert.notEmpty(diseaseQuestion.getDiseaseId(),"疾病id不能为空");
|
|
|
|
|
|
|
|
|
|
Assert.notEmpty(diseaseQuestion.getQuestionId(),"问题id不能为空");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|