需求-78-增加门诊医生开立检验申请单的开立与删除功能以及页面的调整。
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
<?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.openhis.web.doctorstation.mapper.DoctorStationLabApplyMapper">
|
||||
|
||||
<!-- 根据申请单号查询检验申请单 -->
|
||||
<select id="getInspectionApplyByApplyNo" resultType="com.openhis.web.doctorstation.dto.DoctorStationLabApplyDto">
|
||||
SELECT apply_no AS applyNo
|
||||
FROM lab_apply
|
||||
WHERE apply_no = #{applyNo}
|
||||
AND delete_flag = '0'
|
||||
</select>
|
||||
|
||||
<!-- 分页查询检验申请单列表(根据就诊ID查询,按申请时间降序)
|
||||
encounterId: 就诊ID作为查询条件查出患者id(patient_id)再以患者id对申请单进行查询
|
||||
对申请单表(lab_apply)、申请单明细表(lab_apply_item)和就诊表(adm_encounter)进行联合查询(申请单号,检验项目,申请医生,申请单优先级码,申请单状态,金额)-->
|
||||
<select id="getInspectionApplyListPage" resultType="com.openhis.web.doctorstation.dto.DoctorStationLabApplyDto">
|
||||
SELECT t1.apply_no AS applyNo,
|
||||
t1.inspection_item AS inspectionItem,
|
||||
t1.apply_doc_name AS applyDocName,
|
||||
t1.priority_code AS priorityCode,
|
||||
t2.item_name AS itemName,
|
||||
t1.apply_status AS applyStatus,
|
||||
t2.item_amount AS itemAmount
|
||||
FROM lab_apply AS t1
|
||||
INNER JOIN adm_encounter AS t3 ON t1.patient_id::bigint = t3.patient_id
|
||||
LEFT JOIN lab_apply_item AS t2
|
||||
ON t1.apply_no = t2.apply_no
|
||||
WHERE t1.delete_flag = '0'
|
||||
AND t3.id = #{encounterId}
|
||||
ORDER BY t1.apply_time DESC
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user