Browse Source

发起协同门诊

Trick 5 years ago
parent
commit
a0f3d28e4f
21 changed files with 1628 additions and 0 deletions
  1. 1 0
      business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/PrescriptionService.java
  2. 11 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyQuestionDao.java
  3. 15 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyQuestionsOptionDao.java
  4. 11 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateDao.java
  5. 15 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateOptionDao.java
  6. 15 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateQuestionDao.java
  7. 11 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyUserAnswerDao.java
  8. 11 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyUserDao.java
  9. 327 0
      business/base-service/src/main/java/com/yihu/jw/hospital/survey/service/SurveyService.java
  10. 100 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyQuestionDO.java
  11. 60 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyQuestionsOptionDO.java
  12. 82 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateDO.java
  13. 96 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateOptionDO.java
  14. 136 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateQuestionDO.java
  15. 99 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyUserAnswerDO.java
  16. 82 0
      common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyUserDO.java
  17. 120 0
      common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyQuestionVO.java
  18. 63 0
      common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyQuestionsOptionVO.java
  19. 103 0
      common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateOptionVO.java
  20. 158 0
      common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateQuestionVO.java
  21. 112 0
      common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateVO.java

+ 1 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/prescription/service/PrescriptionService.java

@ -703,6 +703,7 @@ public class PrescriptionService extends BaseJpaService<WlyyPrescriptionDO, Pres
        //2.判断是否有未结束的
        List<WlyyOutpatientDO> list = outpatientDao.findByPatientList(patient);
        if(list!=null&&list.size()>0){
            rs.put("outpatient",list.get(0));
            rs.put("code",-2);
            rs.put("mes","存在未结束的诊断");
            return rs;

+ 11 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyQuestionDao.java

@ -0,0 +1,11 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyQuestionDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyQuestionDao extends PagingAndSortingRepository<WlyySurveyQuestionDO, String>, JpaSpecificationExecutor<WlyySurveyQuestionDO> {
}

+ 15 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyQuestionsOptionDao.java

@ -0,0 +1,15 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyQuestionsOptionDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
import java.util.List;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyQuestionsOptionDao extends PagingAndSortingRepository<WlyySurveyQuestionsOptionDO, String>, JpaSpecificationExecutor<WlyySurveyQuestionsOptionDO> {
    List<WlyySurveyQuestionsOptionDO> findByQuestionCodeAndDelOrderBySortAsc(String questionCode,String del);
}

+ 11 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateDao.java

@ -0,0 +1,11 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyTemplateDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyTemplateDao extends PagingAndSortingRepository<WlyySurveyTemplateDO, String>, JpaSpecificationExecutor<WlyySurveyTemplateDO> {
}

+ 15 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateOptionDao.java

@ -0,0 +1,15 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyTemplateOptionDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
import java.util.List;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyTemplateOptionDao extends PagingAndSortingRepository<WlyySurveyTemplateOptionDO, String>, JpaSpecificationExecutor<WlyySurveyTemplateOptionDO> {
    List<WlyySurveyTemplateOptionDO> findByTemplateQuestionCodeAndDelOrderBySortAsc(String templateQuestionCode,String del);
}

+ 15 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyTemplateQuestionDao.java

@ -0,0 +1,15 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyTemplateQuestionDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
import java.util.List;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyTemplateQuestionDao extends PagingAndSortingRepository<WlyySurveyTemplateQuestionDO, String>, JpaSpecificationExecutor<WlyySurveyTemplateQuestionDO> {
    List<WlyySurveyTemplateQuestionDO> findByTemplateCodeAndDelOrderBySortAsc(String templateCode,String del);
}

+ 11 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyUserAnswerDao.java

@ -0,0 +1,11 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyUserAnswerDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyUserAnswerDao extends PagingAndSortingRepository<WlyySurveyUserAnswerDO, String>, JpaSpecificationExecutor<WlyySurveyUserAnswerDO> {
}

+ 11 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/dao/SurveyUserDao.java

@ -0,0 +1,11 @@
package com.yihu.jw.hospital.survey.dao;
import com.yihu.jw.entity.hospital.survey.WlyySurveyUserDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;
/**
 * Created by Trick on 2019/9/6.
 */
public interface SurveyUserDao extends PagingAndSortingRepository<WlyySurveyUserDO, String>, JpaSpecificationExecutor<WlyySurveyUserDO> {
}

+ 327 - 0
business/base-service/src/main/java/com/yihu/jw/hospital/survey/service/SurveyService.java

@ -0,0 +1,327 @@
package com.yihu.jw.hospital.survey.service;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.yihu.jw.entity.hospital.survey.*;
import com.yihu.jw.hospital.dict.WlyyHospitalSysDictDao;
import com.yihu.jw.hospital.survey.dao.*;
import com.yihu.jw.restmodel.hospital.consult.WlyyHospitalSysDictVO;
import com.yihu.jw.restmodel.hospital.survey.*;
import com.yihu.jw.restmodel.web.MixEnvelop;
import com.yihu.jw.rm.hospital.BaseHospitalRequestMapping;
import com.yihu.mysql.query.BaseJpaService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.BeanPropertyRowMapper;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
/**
 * Created by Trick on 2019/9/6.
 */
@Service
@Transactional
public class SurveyService extends BaseJpaService<WlyySurveyQuestionDO, SurveyQuestionDao> {
    @Autowired
    private WlyyHospitalSysDictDao sysDictDao;
    @Autowired
    private JdbcTemplate jdbcTemplate;
    @Autowired
    private ObjectMapper objectMapper;
    @Autowired
    private SurveyQuestionDao surveyQuestionDao;
    @Autowired
    private SurveyQuestionsOptionDao surveyQuestionsOptionDao;
    @Autowired
    private SurveyTemplateDao surveyTemplateDao;
    @Autowired
    private SurveyTemplateQuestionDao surveyTemplateQuestionDao;
    @Autowired
    private SurveyTemplateOptionDao surveyTemplateOptionDao;
    /**
     * 查询字典
     * 1.surveyLabel;2.surveyScreenLabel
     * @param name
     * @return
     */
    public List<WlyyHospitalSysDictVO> getSurveyLabel(String name){
        List<WlyyHospitalSysDictVO> list = new ArrayList<>();
        return convertToModels(sysDictDao.findByDictName(name),list,WlyyHospitalSysDictVO.class);
    }
    /**
     * 查询问题
     * @param title
     * @param questionType
     * @param page
     * @param size
     * @return
     */
    public MixEnvelop findSurveyQuestion(String title,Integer questionType,Integer page,Integer size)throws Exception{
        //计算总数
        String totalSql ="SELECT" +
                " COUNT(1) AS total" +
                " FROM" +
                " wlyy_survey_question q " +
                " WHERE q.del = '1' ";
        if(StringUtils.isNotBlank(title)){
            totalSql+=" AND q.title like '%"+title+"%'";
        }
        if(questionType!=null){
            totalSql+=" AND q.question_type ="+questionType;
        }
        List<Map<String, Object>> rstotal = jdbcTemplate.queryForList(totalSql);
        Long count = 0L;
        if (rstotal != null && rstotal.size() > 0) {
            count = (Long) rstotal.get(0).get("total");
        }
        //计算总数
        String sql ="SELECT " +
                " q.id AS id, " +
                " q.title AS title, " +
                " q.question_comment AS questionComment, " +
                " q.question_type AS questionType, " +
                " q.is_required AS isRequired, " +
                " q.min_num AS minNum, " +
                " q.max_num AS maxNum, " +
                " q.del, " +
                " q.create_time AS createTime, " +
                " q.update_time AS updateTime " +
                " FROM " +
                " wlyy_survey_question q " +
                " WHERE q.del = '1' ";
        if(StringUtils.isNotBlank(title)){
            sql+=" AND q.title like '%"+title+"%'";
        }
        if(questionType!=null){
            sql+=" AND q.question_type ="+questionType;
        }
        sql += " ORDER BY o.create_time DESC LIMIT " + (page - 1) * size + "," + size + " ";
        List<WlyySurveyQuestionVO> list = jdbcTemplate.query(sql, new BeanPropertyRowMapper(WlyySurveyQuestionVO.class));
        if(list!=null&&list.size()>0){
            for(WlyySurveyQuestionVO sq:list){
                List<WlyySurveyQuestionsOptionDO> optionDOs = surveyQuestionsOptionDao.findByQuestionCodeAndDelOrderBySortAsc(sq.getId(),"1");
                if(optionDOs!=null&&optionDOs.size()>0){
                    List<WlyySurveyQuestionsOptionVO> optionVOs = new ArrayList<>();
                    sq.setOptionVOs(convertToModels(optionDOs,optionVOs,WlyySurveyQuestionsOptionVO.class));
                }
            }
        }
        return MixEnvelop.getSuccessListWithPage(BaseHospitalRequestMapping.Prescription.api_success, list, page, size, count);
    }
    /**
     * 查询问题单条
     * @param surveyId
     * @return
     */
    public WlyySurveyQuestionVO findBySurveyId(String surveyId){
        WlyySurveyQuestionDO sq = surveyQuestionDao.findOne(surveyId);
        WlyySurveyQuestionVO surveyQuestionVO = convertToModel(sq,WlyySurveyQuestionVO.class);
        List<WlyySurveyQuestionsOptionDO> optionDOs = surveyQuestionsOptionDao.findByQuestionCodeAndDelOrderBySortAsc(sq.getId(),"1");
        if(optionDOs!=null&&optionDOs.size()>0){
            List<WlyySurveyQuestionsOptionVO> optionVOs = new ArrayList<>();
            surveyQuestionVO.setOptionVOs(convertToModels(optionDOs,optionVOs,WlyySurveyQuestionsOptionVO.class));
        }
        return surveyQuestionVO;
    }
    /**
     * 保存问题
     * @param sqOptionJson
     * @return
     * @throws Exception
     */
    public Boolean saveSurveyQuestion(String sqjsons,String sqOptionJson)throws Exception{
        //保存问题
        List<WlyySurveyQuestionDO> surveys = (List<WlyySurveyQuestionDO>) com.alibaba.fastjson.JSONArray.parseArray(sqjsons, WlyySurveyQuestionDO.class);
        surveyQuestionDao.save(surveys);
        if(surveys!=null&&surveys.size()>0){
            for(WlyySurveyQuestionDO sq:surveys){
                List<WlyySurveyQuestionsOptionDO> optionDOs = surveyQuestionsOptionDao.findByQuestionCodeAndDelOrderBySortAsc(sq.getId(),"1");
                if(optionDOs!=null&&optionDOs.size()>0){
                    surveyQuestionsOptionDao.delete(optionDOs);
                }
                if(StringUtils.isNotBlank(sqOptionJson)){
                    List<WlyySurveyQuestionsOptionDO> options = (List<WlyySurveyQuestionsOptionDO>) com.alibaba.fastjson.JSONArray.parseArray(sqOptionJson, WlyySurveyQuestionsOptionDO.class);
                    surveyQuestionsOptionDao.save(options);
                }
            }
        }
        return true;
    }
    /**
     * 单个编辑问题
     * @param sqjson
     * @param sqOptionJson
     * @return
     * @throws Exception
     */
    public Boolean updataSurveyQuestion(String sqjson,String sqOptionJson) throws Exception{
        WlyySurveyQuestionDO sq = objectMapper.readValue(sqjson,WlyySurveyQuestionDO.class);
        surveyQuestionDao.save(sq);
        List<WlyySurveyQuestionsOptionDO> optionDOs = surveyQuestionsOptionDao.findByQuestionCodeAndDelOrderBySortAsc(sq.getId(),"1");
        if(optionDOs!=null&&optionDOs.size()>0){
            surveyQuestionsOptionDao.delete(optionDOs);
        }
        if(StringUtils.isNotBlank(sqOptionJson)){
            List<WlyySurveyQuestionsOptionDO> options = (List<WlyySurveyQuestionsOptionDO>) com.alibaba.fastjson.JSONArray.parseArray(sqOptionJson, WlyySurveyQuestionsOptionDO.class);
            surveyQuestionsOptionDao.save(options);
        }
        return true;
    }
    /**
     * 删除问题
     * @param ids
     * @return
     */
    public Boolean delSurveyQuestion(String ids){
        String sids[] =ids.split(",");
        if(sids!=null&&ids.length()>0){
            for(String id:sids){
                WlyySurveyQuestionDO del = surveyQuestionDao.findOne(id);
                if(del!=null){
                    surveyQuestionDao.delete(del);
                }
                List<WlyySurveyQuestionsOptionDO> optionDOs = surveyQuestionsOptionDao.findByQuestionCodeAndDelOrderBySortAsc(id,"1");
                if(optionDOs!=null&&optionDOs.size()>0){
                    surveyQuestionsOptionDao.delete(optionDOs);
                }
            }
        }
        return true;
    }
    //=====================问卷模板=====================================
    /**
     *  查询模板列表
     * @param title
     * @param label
     * @param page
     * @param size
     * @return
     */
    public MixEnvelop findSurveyTemplate(String title,String label,Integer page,Integer size){
        String totalSql ="SELECT " +
                " COUNT(1) AS total" +
                " FROM " +
                " wlyy_survey_template t ";
        if(StringUtils.isNotBlank(label)){
            totalSql+=" JOIN wlyy_survey_label_info i OM t.id = i.survey_temp_code";
        }
        totalSql += " WHERE " +
                    " t.del = '1'";
        if(StringUtils.isNotBlank(title)){
            totalSql += " t.title like '%"+title+"%' ";
        }
        if(StringUtils.isNotBlank(label)){
            totalSql += " i.label_code ='"+label+"'";
        }
        List<Map<String, Object>> rstotal = jdbcTemplate.queryForList(totalSql);
        Long count = 0L;
        if (rstotal != null && rstotal.size() > 0) {
            count = (Long) rstotal.get(0).get("total");
        }
        String sql = "SELECT " +
                " t.id, " +
                " t.title, " +
                " t.template_comment AS templateComment, " +
                " t.organization, " +
                " t.creater, " +
                " t.create_time AS createTime, " +
                " t.del, " +
                " t.update_time AS updateTime" +
                " FROM " +
                " wlyy_survey_template t ";
        if(StringUtils.isNotBlank(label)){
            sql += " JOIN wlyy_survey_label_info i OM t.id = i.survey_temp_code";
        }
            sql += " WHERE " +
                   " t.del = '1'";
        if(StringUtils.isNotBlank(title)){
            sql += " t.title like '%"+title+"%' ";
        }
        if(StringUtils.isNotBlank(label)){
            sql += " i.label_code ='"+label+"'";
        }
        sql += " ORDER BY o.create_time DESC LIMIT " + (page - 1) * size + "," + size + " ";
        List<WlyySurveyTemplateVO> list = jdbcTemplate.query(sql, new BeanPropertyRowMapper(WlyySurveyTemplateVO.class));
        if(list!=null&&list.size()>0){
            //设置标签
            for(WlyySurveyTemplateVO templateVO : list){
                templateVO.setLabels(findSurveyTemplateLabel(templateVO.getId()));
            }
        }
        return MixEnvelop.getSuccessListWithPage(BaseHospitalRequestMapping.Prescription.api_success, list, page, size, count);
    }
    /**
     * 获取问卷模板详情
     * @param tempId
     * @return
     */
    public WlyySurveyTemplateVO findSurveyTemplateById(String tempId){
        WlyySurveyTemplateDO templateDO = surveyTemplateDao.findOne(tempId);
        WlyySurveyTemplateVO templateVO = convertToModel(templateDO,WlyySurveyTemplateVO.class);
        templateVO.setLabels(findSurveyTemplateLabel(tempId));
        List<WlyySurveyTemplateQuestionDO> tqDOs = surveyTemplateQuestionDao.findByTemplateCodeAndDelOrderBySortAsc(tempId,"1");
        if(tqDOs!=null&&tqDOs.size()>0){
            //设置问题
            List<WlyySurveyTemplateQuestionVO> tqVOs = new ArrayList<>();
            convertToModels(tqDOs,tqVOs,WlyySurveyTemplateQuestionVO.class);
            templateVO.setTemplateQuestionVOs(tqVOs);
            //设置选项
            for(WlyySurveyTemplateQuestionVO tq:tqVOs){
                List<WlyySurveyTemplateOptionDO> optionDOs  = surveyTemplateOptionDao.findByTemplateQuestionCodeAndDelOrderBySortAsc(tq.getId(),"1");
                List<WlyySurveyTemplateOptionVO> optionVOs = new ArrayList<>();
                convertToModels(optionDOs,optionVOs,WlyySurveyTemplateOptionVO.class);
                tq.setTemplateOptionVOs(optionVOs);
            }
        }
        return templateVO;
    }
    public List<Map<String,Object>> findSurveyTemplateLabel(String tempId){
        String sql ="SELECT " +
                " i.label_code AS labelCode, " +
                " i.label_name AS labelName " +
                " FROM " +
                " wlyy_survey_label_info i " +
                " WHERE " +
                " i.survey_temp_code = '"+tempId+"'";
        List<Map<String,Object>> list = jdbcTemplate.queryForList(sql);
        return list;
    }
//    public Boolean saveSurveyTemplate(){
//
//    }
}

+ 100 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyQuestionDO.java

@ -0,0 +1,100 @@
package com.yihu.jw.entity.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_question")
public class WlyySurveyQuestionDO extends UuidIdentityEntity {
    private String title;//问题标题',
    private String questionComment;//问题说明(可为null)',
    private Integer questionType;//问题类型(0单选 1多选 2问答)',
    private Integer isRequired;//是否必答(0否 1是)',
    private Integer minNum;//最小答案个数(多选有效)',
    private Integer maxNum;//最大答案个数(多选有效)',
    private String del;//删除标志(1正常,0删除)',
    private Date createTime;//创建时间',
    private Date updateTime;//修改时间',
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getQuestionComment() {
        return questionComment;
    }
    public void setQuestionComment(String questionComment) {
        this.questionComment = questionComment;
    }
    public Integer getQuestionType() {
        return questionType;
    }
    public void setQuestionType(Integer questionType) {
        this.questionType = questionType;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getMinNum() {
        return minNum;
    }
    public void setMinNum(Integer minNum) {
        this.minNum = minNum;
    }
    public Integer getMaxNum() {
        return maxNum;
    }
    public void setMaxNum(Integer maxNum) {
        this.maxNum = maxNum;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 60 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyQuestionsOptionDO.java

@ -0,0 +1,60 @@
package com.yihu.jw.entity.hospital.survey;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_questions_option")
public class WlyySurveyQuestionsOptionDO extends UuidIdentityEntity {
    private String questionCode;//题库问题编码',
    private String content;//选项内容',
    private Integer isRequired;//选项说明是否必填(0否 1是)',
    private Integer sort;//单题内排序',
    private String del;//删除标志(1正常,0删除)',
    public String getQuestionCode() {
        return questionCode;
    }
    public void setQuestionCode(String questionCode) {
        this.questionCode = questionCode;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
}

+ 82 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateDO.java

@ -0,0 +1,82 @@
package com.yihu.jw.entity.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_template")
public class WlyySurveyTemplateDO extends UuidIdentityEntity {
    private String title;//模板标题',
    private String templateComment;//模板说明',
    private String creater;//创建人',
    private String organization;//发布机构',
    private String del;//删除标志(1正常,0删除)',
    private Date createTime;//创建时间',
    private Date updateTime;//修改时间',
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getTemplateComment() {
        return templateComment;
    }
    public void setTemplateComment(String templateComment) {
        this.templateComment = templateComment;
    }
    public String getCreater() {
        return creater;
    }
    public void setCreater(String creater) {
        this.creater = creater;
    }
    public String getOrganization() {
        return organization;
    }
    public void setOrganization(String organization) {
        this.organization = organization;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 96 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateOptionDO.java

@ -0,0 +1,96 @@
package com.yihu.jw.entity.hospital.survey;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_template_option")
public class WlyySurveyTemplateOptionDO extends UuidIdentityEntity {
    private String templateCode;//模板编码',
    private String templateQuestionCode;//模板问题编码',
    private String content;//选项内容',
    private Integer isRequired;//选项说明是否必填(0否 1是)',
    private Integer score;//选项分值',
    private String questionCodeNext;//下一题问题编码(问答题逻辑跳转)',
    private String questionSortNext;//下一题问题所属sort排序',
    private String del;//删除标志(1正常,0删除)',
    private Integer sort;//单题内排序',
    public String getTemplateCode() {
        return templateCode;
    }
    public void setTemplateCode(String templateCode) {
        this.templateCode = templateCode;
    }
    public String getTemplateQuestionCode() {
        return templateQuestionCode;
    }
    public void setTemplateQuestionCode(String templateQuestionCode) {
        this.templateQuestionCode = templateQuestionCode;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getScore() {
        return score;
    }
    public void setScore(Integer score) {
        this.score = score;
    }
    public String getQuestionCodeNext() {
        return questionCodeNext;
    }
    public void setQuestionCodeNext(String questionCodeNext) {
        this.questionCodeNext = questionCodeNext;
    }
    public String getQuestionSortNext() {
        return questionSortNext;
    }
    public void setQuestionSortNext(String questionSortNext) {
        this.questionSortNext = questionSortNext;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
}

+ 136 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyTemplateQuestionDO.java

@ -0,0 +1,136 @@
package com.yihu.jw.entity.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_template_question")
public class WlyySurveyTemplateQuestionDO extends UuidIdentityEntity {
    private String title;//问题标题',
    private String questionComment;//问题说明(可为null)',
    private Integer questionType;//问题类型(0单选 1多选 2问答)',
    private String templateCode;//模板编码',
    private Integer isRequired;//是否必答(0否 1是)',
    private Integer minNum;//最小答案个数(多选有效)',
    private Integer maxNum;//最大答案个数(多选有效)',
    private String questionCodeNext;//下一题问题编码(问答题逻辑跳转)',
    private String questionSortNext;//下一题问题所属sort排序',
    private Integer sort;//排序',
    private String del;//删除标志(1正常,0删除)',
    private Date createTime;//创建时间',
    private Date updateTime;//修改时间',
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getQuestionComment() {
        return questionComment;
    }
    public void setQuestionComment(String questionComment) {
        this.questionComment = questionComment;
    }
    public Integer getQuestionType() {
        return questionType;
    }
    public void setQuestionType(Integer questionType) {
        this.questionType = questionType;
    }
    public String getTemplateCode() {
        return templateCode;
    }
    public void setTemplateCode(String templateCode) {
        this.templateCode = templateCode;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getMinNum() {
        return minNum;
    }
    public void setMinNum(Integer minNum) {
        this.minNum = minNum;
    }
    public Integer getMaxNum() {
        return maxNum;
    }
    public void setMaxNum(Integer maxNum) {
        this.maxNum = maxNum;
    }
    public String getQuestionCodeNext() {
        return questionCodeNext;
    }
    public void setQuestionCodeNext(String questionCodeNext) {
        this.questionCodeNext = questionCodeNext;
    }
    public String getQuestionSortNext() {
        return questionSortNext;
    }
    public void setQuestionSortNext(String questionSortNext) {
        this.questionSortNext = questionSortNext;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

+ 99 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyUserAnswerDO.java

@ -0,0 +1,99 @@
package com.yihu.jw.entity.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_user_answer")
public class WlyySurveyUserAnswerDO extends UuidIdentityEntity {
    private String surveyTempCode;//问卷模板编码',
    private String tempQuestionCode;//问答题题目编码',
    private Integer questionType;//
    private String tempOptionCode;//问卷选项编码',
    private String content;//问答题答案/选择题,问答题的中文',
    private String patient;//患者ID',
    private String patientName;//患者姓名',
    private Integer score;//得分',
    private Date createTime;//答案填写时间',
    public String getSurveyTempCode() {
        return surveyTempCode;
    }
    public void setSurveyTempCode(String surveyTempCode) {
        this.surveyTempCode = surveyTempCode;
    }
    public String getTempQuestionCode() {
        return tempQuestionCode;
    }
    public void setTempQuestionCode(String tempQuestionCode) {
        this.tempQuestionCode = tempQuestionCode;
    }
    public Integer getQuestionType() {
        return questionType;
    }
    public void setQuestionType(Integer questionType) {
        this.questionType = questionType;
    }
    public String getTempOptionCode() {
        return tempOptionCode;
    }
    public void setTempOptionCode(String tempOptionCode) {
        this.tempOptionCode = tempOptionCode;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public String getPatient() {
        return patient;
    }
    public void setPatient(String patient) {
        this.patient = patient;
    }
    public String getPatientName() {
        return patientName;
    }
    public void setPatientName(String patientName) {
        this.patientName = patientName;
    }
    public Integer getScore() {
        return score;
    }
    public void setScore(Integer score) {
        this.score = score;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}

+ 82 - 0
common/common-entity/src/main/java/com/yihu/jw/entity/hospital/survey/WlyySurveyUserDO.java

@ -0,0 +1,82 @@
package com.yihu.jw.entity.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.entity.UuidIdentityEntity;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;
/**
 * Created by Trick on 2019/9/6.
 */
@Entity
@Table(name = "wlyy_survey_user")
public class WlyySurveyUserDO extends UuidIdentityEntity {
    private String surveyTempCode;//问卷模板编码',
    private String surveyTempTitle;//模板标题
    private String patient;//患者ID',
    private String patientName;//
    private Integer status;//是否已答(0未答 1已答 2放弃)',
    private Date endTime;//完成时间(放弃时间)',
    private Date createTime;//调查时间(居民接受时间)',
    public String getSurveyTempCode() {
        return surveyTempCode;
    }
    public void setSurveyTempCode(String surveyTempCode) {
        this.surveyTempCode = surveyTempCode;
    }
    public String getSurveyTempTitle() {
        return surveyTempTitle;
    }
    public void setSurveyTempTitle(String surveyTempTitle) {
        this.surveyTempTitle = surveyTempTitle;
    }
    public String getPatient() {
        return patient;
    }
    public void setPatient(String patient) {
        this.patient = patient;
    }
    public String getPatientName() {
        return patientName;
    }
    public void setPatientName(String patientName) {
        this.patientName = patientName;
    }
    public Integer getStatus() {
        return status;
    }
    public void setStatus(Integer status) {
        this.status = status;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getEndTime() {
        return endTime;
    }
    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}

+ 120 - 0
common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyQuestionVO.java

@ -0,0 +1,120 @@
package com.yihu.jw.restmodel.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.restmodel.UuidIdentityVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
import java.util.List;
/**
 * Created by Trick on 2019/9/9.
 */
@ApiModel(value = "WlyySurveyQuestionVO", description = "问卷调查")
public class WlyySurveyQuestionVO extends UuidIdentityVO {
    @ApiModelProperty(value = "问题标题", example = "模块1")
    private String title;//问题标题',
    @ApiModelProperty(value = "问题说明", example = "模块1")
    private String questionComment;//问题说明(可为null)',
    @ApiModelProperty(value = "问题类型(0单选 1多选 2问答", example = "模块1")
    private Integer questionType;//问题类型(0单选 1多选 2问答)',
    @ApiModelProperty(value = "是否必答(0否 1是)", example = "模块1")
    private Integer isRequired;//是否必答(0否 1是)',
    @ApiModelProperty(value = "最小答案个数(多选有效)", example = "模块1")
    private Integer minNum;//最小答案个数(多选有效)',
    @ApiModelProperty(value = "最大答案个数(多选有效)", example = "模块1")
    private Integer maxNum;//最大答案个数(多选有效)',
    @ApiModelProperty(value = "删除标志(1正常,0删除)", example = "模块1")
    private String del;//删除标志(1正常,0删除)',
    @ApiModelProperty(value = "创建时间", example = "模块1")
    private Date createTime;//创建时间',
    @ApiModelProperty(value = "修改时间", example = "模块1")
    private Date updateTime;//修改时间',
    @ApiModelProperty(value = "选项目", example = "模块1")
    private List<WlyySurveyQuestionsOptionVO> optionVOs;
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getQuestionComment() {
        return questionComment;
    }
    public void setQuestionComment(String questionComment) {
        this.questionComment = questionComment;
    }
    public Integer getQuestionType() {
        return questionType;
    }
    public void setQuestionType(Integer questionType) {
        this.questionType = questionType;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getMinNum() {
        return minNum;
    }
    public void setMinNum(Integer minNum) {
        this.minNum = minNum;
    }
    public Integer getMaxNum() {
        return maxNum;
    }
    public void setMaxNum(Integer maxNum) {
        this.maxNum = maxNum;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
    public List<WlyySurveyQuestionsOptionVO> getOptionVOs() {
        return optionVOs;
    }
    public void setOptionVOs(List<WlyySurveyQuestionsOptionVO> optionVOs) {
        this.optionVOs = optionVOs;
    }
}

+ 63 - 0
common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyQuestionsOptionVO.java

@ -0,0 +1,63 @@
package com.yihu.jw.restmodel.hospital.survey;
import com.yihu.jw.restmodel.UuidIdentityVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
/**
 * Created by Trick on 2019/9/9.
 */
@ApiModel(value = "WlyySurveyQuestionVO", description = "问卷调查选项")
public class WlyySurveyQuestionsOptionVO extends UuidIdentityVO {
    @ApiModelProperty(value = "题库问题编码", example = "模块1")
    private String questionCode;//题库问题编码',
    @ApiModelProperty(value = "选项内容", example = "模块1")
    private String content;//选项内容',
    @ApiModelProperty(value = "选项说明是否必填(0否 1是)", example = "模块1")
    private Integer isRequired;//选项说明是否必填(0否 1是)',
    @ApiModelProperty(value = "单题内排序", example = "模块1")
    private Integer sort;//单题内排序',
    @ApiModelProperty(value = "删除标志", example = "模块1")
    private String del;//删除标志(1正常,0删除)',
    public String getQuestionCode() {
        return questionCode;
    }
    public void setQuestionCode(String questionCode) {
        this.questionCode = questionCode;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
}

+ 103 - 0
common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateOptionVO.java

@ -0,0 +1,103 @@
package com.yihu.jw.restmodel.hospital.survey;
import com.yihu.jw.restmodel.UuidIdentityVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
/**
 * Created by Trick on 2019/9/9.
 */
@ApiModel(value = "WlyySurveyTemplateOptionVO", description = "问卷调查模板问题选项")
public class WlyySurveyTemplateOptionVO extends UuidIdentityVO {
    @ApiModelProperty(value = "模板编码", example = "模块1")
    private String templateCode;//模板编码',
    @ApiModelProperty(value = "模板问题编码", example = "模块1")
    private String templateQuestionCode;//模板问题编码',
    @ApiModelProperty(value = "选项内容", example = "模块1")
    private String content;//选项内容',
    @ApiModelProperty(value = "选项说明是否必填(0否 1是)", example = "模块1")
    private Integer isRequired;//选项说明是否必填(0否 1是)',
    @ApiModelProperty(value = "选项分值", example = "模块1")
    private Integer score;//选项分值',
    @ApiModelProperty(value = "下一题问题编码(问答题逻辑跳转)", example = "模块1")
    private String questionCodeNext;//下一题问题编码(问答题逻辑跳转)',
    @ApiModelProperty(value = "下一题问题所属sort排序", example = "模块1")
    private String questionSortNext;//下一题问题所属sort排序',
    @ApiModelProperty(value = "删除标志(1正常,0删除)", example = "模块1")
    private String del;//删除标志(1正常,0删除)',
    @ApiModelProperty(value = "单题内排序", example = "模块1")
    private Integer sort;//单题内排序',
    public String getTemplateCode() {
        return templateCode;
    }
    public void setTemplateCode(String templateCode) {
        this.templateCode = templateCode;
    }
    public String getTemplateQuestionCode() {
        return templateQuestionCode;
    }
    public void setTemplateQuestionCode(String templateQuestionCode) {
        this.templateQuestionCode = templateQuestionCode;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getScore() {
        return score;
    }
    public void setScore(Integer score) {
        this.score = score;
    }
    public String getQuestionCodeNext() {
        return questionCodeNext;
    }
    public void setQuestionCodeNext(String questionCodeNext) {
        this.questionCodeNext = questionCodeNext;
    }
    public String getQuestionSortNext() {
        return questionSortNext;
    }
    public void setQuestionSortNext(String questionSortNext) {
        this.questionSortNext = questionSortNext;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
}

+ 158 - 0
common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateQuestionVO.java

@ -0,0 +1,158 @@
package com.yihu.jw.restmodel.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.restmodel.UuidIdentityVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
import java.util.List;
/**
 * Created by Trick on 2019/9/9.
 */
@ApiModel(value = "WlyySurveyTemplateQuestionVO", description = "问卷调查模板问题")
public class WlyySurveyTemplateQuestionVO extends UuidIdentityVO {
    @ApiModelProperty(value = "问题标题", example = "模块1")
    private String title;//问题标题',
    @ApiModelProperty(value = "问题说明(可为null)", example = "模块1")
    private String questionComment;//问题说明(可为null)',
    @ApiModelProperty(value = "问题类型(0单选 1多选 2问答)", example = "模块1")
    private Integer questionType;//问题类型(0单选 1多选 2问答)',
    @ApiModelProperty(value = "模板编码", example = "模块1")
    private String templateCode;//模板编码',
    @ApiModelProperty(value = "是否必答(0否 1是)", example = "模块1")
    private Integer isRequired;//是否必答(0否 1是)',
    @ApiModelProperty(value = "最小答案个数(多选有效)", example = "模块1")
    private Integer minNum;//最小答案个数(多选有效)',
    @ApiModelProperty(value = "最大答案个数(多选有效)", example = "模块1")
    private Integer maxNum;//最大答案个数(多选有效)',
    @ApiModelProperty(value = "下一题问题编码(问答题逻辑跳转)", example = "模块1")
    private String questionCodeNext;//下一题问题编码(问答题逻辑跳转)',
    @ApiModelProperty(value = "下一题问题所属sort排序", example = "模块1")
    private String questionSortNext;//下一题问题所属sort排序',
    @ApiModelProperty(value = "排序", example = "模块1")
    private Integer sort;//排序',
    @ApiModelProperty(value = "删除标志(1正常,0删除)", example = "模块1")
    private String del;//删除标志(1正常,0删除)',
    @ApiModelProperty(value = "创建时间", example = "模块1")
    private Date createTime;//创建时间',
    @ApiModelProperty(value = "修改时间", example = "模块1")
    private Date updateTime;//修改时间',
    @ApiModelProperty(value = "选项", example = "模块1")
    private List<WlyySurveyTemplateOptionVO> templateOptionVOs;
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getQuestionComment() {
        return questionComment;
    }
    public void setQuestionComment(String questionComment) {
        this.questionComment = questionComment;
    }
    public Integer getQuestionType() {
        return questionType;
    }
    public void setQuestionType(Integer questionType) {
        this.questionType = questionType;
    }
    public String getTemplateCode() {
        return templateCode;
    }
    public void setTemplateCode(String templateCode) {
        this.templateCode = templateCode;
    }
    public Integer getIsRequired() {
        return isRequired;
    }
    public void setIsRequired(Integer isRequired) {
        this.isRequired = isRequired;
    }
    public Integer getMinNum() {
        return minNum;
    }
    public void setMinNum(Integer minNum) {
        this.minNum = minNum;
    }
    public Integer getMaxNum() {
        return maxNum;
    }
    public void setMaxNum(Integer maxNum) {
        this.maxNum = maxNum;
    }
    public String getQuestionCodeNext() {
        return questionCodeNext;
    }
    public void setQuestionCodeNext(String questionCodeNext) {
        this.questionCodeNext = questionCodeNext;
    }
    public String getQuestionSortNext() {
        return questionSortNext;
    }
    public void setQuestionSortNext(String questionSortNext) {
        this.questionSortNext = questionSortNext;
    }
    public Integer getSort() {
        return sort;
    }
    public void setSort(Integer sort) {
        this.sort = sort;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
    public List<WlyySurveyTemplateOptionVO> getTemplateOptionVOs() {
        return templateOptionVOs;
    }
    public void setTemplateOptionVOs(List<WlyySurveyTemplateOptionVO> templateOptionVOs) {
        this.templateOptionVOs = templateOptionVOs;
    }
}

+ 112 - 0
common/common-rest-model/src/main/java/com/yihu/jw/restmodel/hospital/survey/WlyySurveyTemplateVO.java

@ -0,0 +1,112 @@
package com.yihu.jw.restmodel.hospital.survey;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yihu.jw.restmodel.UuidIdentityVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
import java.util.List;
import java.util.Map;
/**
 * Created by Trick on 2019/9/9.
 */
@ApiModel(value = "WlyySurveyTemplateVO", description = "问卷调查模板")
public class WlyySurveyTemplateVO extends UuidIdentityVO {
    @ApiModelProperty(value = "模板标题", example = "模块1")
    private String title;//模板标题',
    @ApiModelProperty(value = "模板说明", example = "模块1")
    private String templateComment;//模板说明',
    @ApiModelProperty(value = "创建人", example = "模块1")
    private String creater;//创建人',
    @ApiModelProperty(value = "发布机构", example = "模块1")
    private String organization;//发布机构',
    @ApiModelProperty(value = "删除标志(1正常,0删除)", example = "模块1")
    private String del;//删除标志(1正常,0删除)',
    @ApiModelProperty(value = "创建时间", example = "模块1")
    private Date createTime;//创建时间',
    @ApiModelProperty(value = "修改时间", example = "模块1")
    private Date updateTime;//修改时间',
    @ApiModelProperty(value = "标签", example = "模块1")
    private List<Map<String,Object>> labels;
    @ApiModelProperty(value = "问题", example = "模块1")
    private List<WlyySurveyTemplateQuestionVO> templateQuestionVOs;
    public String getTitle() {
        return title;
    }
    public void setTitle(String title) {
        this.title = title;
    }
    public String getTemplateComment() {
        return templateComment;
    }
    public void setTemplateComment(String templateComment) {
        this.templateComment = templateComment;
    }
    public String getCreater() {
        return creater;
    }
    public void setCreater(String creater) {
        this.creater = creater;
    }
    public String getOrganization() {
        return organization;
    }
    public void setOrganization(String organization) {
        this.organization = organization;
    }
    public String getDel() {
        return del;
    }
    public void setDel(String del) {
        this.del = del;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+08:00")
    public Date getUpdateTime() {
        return updateTime;
    }
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
    public List<Map<String, Object>> getLabels() {
        return labels;
    }
    public void setLabels(List<Map<String, Object>> labels) {
        this.labels = labels;
    }
    public List<WlyySurveyTemplateQuestionVO> getTemplateQuestionVOs() {
        return templateQuestionVOs;
    }
    public void setTemplateQuestionVOs(List<WlyySurveyTemplateQuestionVO> templateQuestionVOs) {
        this.templateQuestionVOs = templateQuestionVOs;
    }
}