|
@@ -3265,10 +3265,9 @@
|
|
|
</select>
|
|
|
|
|
|
<!-- 时效性报表-首次病程未在患者入院8小时内完成(杭州七院标准版) -->
|
|
|
- <select id="getUnfinishedFirst_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailaDTO">
|
|
|
+ <select id="getUnfinishedFirst_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailaaDTO">
|
|
|
SELECT DISTINCT
|
|
|
a.behospital_code AS behospitalCode,
|
|
|
- a.hospital_id AS hospitalId,
|
|
|
a.`name` AS name,
|
|
|
a.sex AS sex,
|
|
|
a.file_code AS fileCode,
|
|
@@ -3298,29 +3297,18 @@
|
|
|
AND b.is_deleted = 'N'
|
|
|
AND b.cases_entry_id = '3241'
|
|
|
AND a.hospital_id = '14'
|
|
|
- <if test="isPlacefile != null and isPlacefile == 0">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="startDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
</if>
|
|
|
- <if test="isPlacefile != null and isPlacefile == 1">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="endDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
</if>
|
|
|
</select>
|
|
|
|
|
|
<!-- 时效性报表-入院记录未在患者入院24小时内完成(杭州七院) -->
|
|
|
- <select id="getUnfinishedIn_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailaDTO">
|
|
|
+ <select id="getUnfinishedIn_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailabDTO">
|
|
|
SELECT DISTINCT
|
|
|
a.behospital_code AS behospitalCode,
|
|
|
- a.hospital_id AS hospitalId,
|
|
|
a.`name` AS name,
|
|
|
a.sex AS sex,
|
|
|
a.file_code AS fileCode,
|
|
@@ -3350,29 +3338,18 @@
|
|
|
AND b.is_deleted = 'N'
|
|
|
AND b.cases_entry_id = '3242'
|
|
|
AND a.hospital_id = '14'
|
|
|
- <if test="isPlacefile != null and isPlacefile == 0">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="startDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
</if>
|
|
|
- <if test="isPlacefile != null and isPlacefile == 1">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="endDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
</if>
|
|
|
</select>
|
|
|
|
|
|
<!-- 时效性报表-自杀、冲动、猝死病历入院记录未在患者入院24小时内完成(杭州七院) -->
|
|
|
- <select id="getUnfinishedSuicide_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailaDTO">
|
|
|
+ <select id="getUnfinishedSuicide_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailacDTO">
|
|
|
SELECT DISTINCT
|
|
|
a.behospital_code AS behospitalCode,
|
|
|
- a.hospital_id AS hospitalId,
|
|
|
a.`name` AS name,
|
|
|
a.sex AS sex,
|
|
|
a.file_code AS fileCode,
|
|
@@ -3402,21 +3379,11 @@
|
|
|
AND b.is_deleted = 'N'
|
|
|
AND b.cases_entry_id = '3243'
|
|
|
AND a.hospital_id = '14'
|
|
|
- <if test="isPlacefile != null and isPlacefile == 0">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="startDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
</if>
|
|
|
- <if test="isPlacefile != null and isPlacefile == 1">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="endDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
</if>
|
|
|
</select>
|
|
|
|
|
@@ -3424,14 +3391,13 @@
|
|
|
<select id="getUnfinishedThree_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailbDTO">
|
|
|
SELECT DISTINCT
|
|
|
a.behospital_code AS behospitalCode,
|
|
|
- a.hospital_id AS hospitalId,
|
|
|
a.`name` AS name,
|
|
|
a.sex AS sex,
|
|
|
a.file_code AS fileCode,
|
|
|
a.doctor_name AS doctorName,
|
|
|
a.beh_dept_name AS behDeptName,
|
|
|
b.msg AS ruleName,
|
|
|
- b.remark AS remark,
|
|
|
+ b.info AS remark,
|
|
|
a.behospital_date AS behospitalDate,
|
|
|
a.is_placefile AS isPlacefile
|
|
|
FROM
|
|
@@ -3442,21 +3408,11 @@
|
|
|
AND b.is_deleted = 'N'
|
|
|
AND b.cases_entry_id = '3240'
|
|
|
AND a.hospital_id = '14'
|
|
|
- <if test="isPlacefile != null and isPlacefile == 0">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="startDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
</if>
|
|
|
- <if test="isPlacefile != null and isPlacefile == 1">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="endDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
</if>
|
|
|
</select>
|
|
|
|
|
@@ -3464,14 +3420,13 @@
|
|
|
<select id="getUnfinishedSix_HZQY" parameterType="com.diagbot.vo.QcResultShortPageVO" resultType="com.diagbot.dto.ExportReportDetailbDTO">
|
|
|
SELECT DISTINCT
|
|
|
a.behospital_code AS behospitalCode,
|
|
|
- a.hospital_id AS hospitalId,
|
|
|
a.`name` AS name,
|
|
|
a.sex AS sex,
|
|
|
a.file_code AS fileCode,
|
|
|
a.doctor_name AS doctorName,
|
|
|
a.beh_dept_name AS behDeptName,
|
|
|
b.msg AS ruleName,
|
|
|
- b.remark AS remark,
|
|
|
+ b.info AS remark,
|
|
|
a.behospital_date AS behospitalDate,
|
|
|
a.is_placefile AS isPlacefile
|
|
|
FROM
|
|
@@ -3482,21 +3437,11 @@
|
|
|
AND b.is_deleted = 'N'
|
|
|
AND b.cases_entry_id = '3244'
|
|
|
AND a.hospital_id = '14'
|
|
|
- <if test="isPlacefile != null and isPlacefile == 0">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.behospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="startDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
</if>
|
|
|
- <if test="isPlacefile != null and isPlacefile == 1">
|
|
|
- <if test="startDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date >= #{startDate}]]>
|
|
|
- </if>
|
|
|
- <if test="endDate != null ">
|
|
|
- <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
- </if>
|
|
|
+ <if test="endDate != null ">
|
|
|
+ <![CDATA[ AND a.leave_hospital_date <= #{endDate}]]>
|
|
|
</if>
|
|
|
</select>
|
|
|
|