|
|
@ -22,6 +22,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
<result property="responseTime" column="response_time" />
|
|
|
|
<result property="responseTime" column="response_time" />
|
|
|
|
<result property="aiResultReturnTime" column="ai_result_return_time" />
|
|
|
|
<result property="aiResultReturnTime" column="ai_result_return_time" />
|
|
|
|
<result property="aiResultModifyTime" column="ai_result_modify_time" />
|
|
|
|
<result property="aiResultModifyTime" column="ai_result_modify_time" />
|
|
|
|
|
|
|
|
<result property="hospitalName" column="hospital_name" />
|
|
|
|
|
|
|
|
<result property="doctorName" column="doctor_name"/>
|
|
|
|
</resultMap>
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
|
|
<sql id="selectTRecordVo">
|
|
|
|
<sql id="selectTRecordVo">
|
|
|
@ -253,6 +255,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
order by create_time desc
|
|
|
|
order by create_time desc
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectTRecordDoctorHospitalFirst" parameterType="TRecord" resultMap="TRecordResult">
|
|
|
|
|
|
|
|
select
|
|
|
|
|
|
|
|
t.id,
|
|
|
|
|
|
|
|
t.create_time,
|
|
|
|
|
|
|
|
t.doctor_id,
|
|
|
|
|
|
|
|
t.hospital_id,
|
|
|
|
|
|
|
|
c.`name` as hospital_name,
|
|
|
|
|
|
|
|
d.`name` as doctor_name
|
|
|
|
|
|
|
|
from t_record t
|
|
|
|
|
|
|
|
left join t_hospital c on c.id = t.hospital_id
|
|
|
|
|
|
|
|
left join t_doctor d on d.id = t.doctor_id
|
|
|
|
|
|
|
|
<where>
|
|
|
|
|
|
|
|
<if test="patientId != null "> and t.patient_id = #{patientId}</if>
|
|
|
|
|
|
|
|
<if test="doctorId != null "> and t.doctor_id = #{doctorId}</if>
|
|
|
|
|
|
|
|
<if test="hospitalId != null "> and t.hospital_id = #{hospitalId}</if>
|
|
|
|
|
|
|
|
<if test="status != null and status != ''"> and t.status = #{status}</if>
|
|
|
|
|
|
|
|
</where>
|
|
|
|
|
|
|
|
order by t.create_time desc
|
|
|
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectTRecordList" parameterType="TRecord" resultMap="TRecordResult">
|
|
|
|
<select id="selectTRecordList" parameterType="TRecord" resultMap="TRecordResult">
|
|
|
|
<include refid="selectTRecordVo"/>
|
|
|
|
<include refid="selectTRecordVo"/>
|
|
|
|
where tr.del_flag = '0'
|
|
|
|
where tr.del_flag = '0'
|
|
|
|