You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
virtual-patient/virtual-patient-model/src/main/resources/mapper/DiseasePhysicalMapper.xml

56 lines
3.4 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.supervision.mapper.DiseasePhysicalMapper">
<resultMap id="BaseResultMap" type="com.supervision.model.DiseasePhysical">
<id property="id" column="id" jdbcType="VARCHAR"/>
<result property="diseaseId" column="disease_id" jdbcType="VARCHAR"/>
<result property="toolId" column="tool_id" jdbcType="VARCHAR"/>
<result property="locationId" column="location_id" jdbcType="VARCHAR"/>
<result property="requireCheckFlag" column="require_check_flag" jdbcType="INTEGER"/>
<result property="primarilyDiagnosisCriteriaFlag" column="primarily_diagnosis_criteria_flag" jdbcType="INTEGER"/>
<result property="basisConfirmFlag" column="basis_confirm_flag" jdbcType="INTEGER"/>
<result property="basisIdentificationFlag" column="basis_identification_flag" jdbcType="INTEGER"/>
<result property="diagnosisAssessmentFlag" column="diagnosis_assessment_flag" jdbcType="INTEGER"/>
<result property="expectedDiagnosisResult" column="expected_diagnosis_result" jdbcType="VARCHAR"/>
<result property="fullCheckFlag" column="full_check_flag" jdbcType="INTEGER"/>
<result property="result" column="result" jdbcType="VARCHAR"/>
<result property="trait" column="trait" jdbcType="VARCHAR"/>
<result property="createUserId" column="create_user_id" jdbcType="VARCHAR"/>
<result property="createTime" column="create_time" jdbcType="TIMESTAMP"/>
<result property="updateUserId" column="update_user_id" jdbcType="VARCHAR"/>
<result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
</resultMap>
<sql id="Base_Column_List">
id,tool_id,location_id,disease_id,
require_check_flag,primarily_diagnosis_criteria_flag,basis_confirm_flag,
diagnosis_assessment_flag,expected_diagnosis_result,full_check_flag,
basis_identification_flag,result,trait,
create_user_id,create_time,update_user_id,
update_time
</sql>
<select id="queryListByDiseaseId" resultType="com.supervision.vo.manage.DiseasePhysicalResVo">
select dp.id,
dp.disease_id as diseaseId,
dp.tool_id as itemId,
dp.location_id as locationId,
cpt.tool_name as toolName,
dp.primarily_diagnosis_criteria_flag as primarilyDiagnosisCriteriaFlag,
dp.basis_confirm_flag as basisConfirmFlag,
dp.basis_identification_flag as basisIdentificationFlag,
dp.full_check_flag as fullCheckFlag,
dp.diagnosis_assessment_flag as diagnosisAssessmentFlag,
dp.expected_diagnosis_result as expectedDiagnosisResult,
dp.require_check_flag as asrequireCheckFlag,
dp.result as result,
dp.trait as trait
from vp_disease_physical dp
left join vp_config_physical_tool cpt on dp.tool_id = cpt.id
where dp.disease_id = #{diseaseId} order by dp.create_time desc
</select>
</mapper>