From ec91ffc8e7fa8c2cf455b71765166f8f0f749247 Mon Sep 17 00:00:00 2001
From: 侯瑞军 <411269194@kidgrow.com>
Date: Wed, 15 Apr 2020 20:01:00 +0800
Subject: [PATCH] 1.修改医院状态,删除医院功能 2.增加字典按分类查询下拉框通用控件 3.增加自动完成控件(未完成) 4.修改字典展示数据的字段 5.部门数据增加按照医院id查询 6.增加全局静态变量类 DictionariesConstants

---
 kidgrow-business/kidgrow-usercenter/kidgrow-usercenter-biz/src/main/resources/mapper/SysHospitalMapper.xml |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 55 insertions(+), 0 deletions(-)

diff --git a/kidgrow-business/kidgrow-usercenter/kidgrow-usercenter-biz/src/main/resources/mapper/SysHospitalMapper.xml b/kidgrow-business/kidgrow-usercenter/kidgrow-usercenter-biz/src/main/resources/mapper/SysHospitalMapper.xml
index 0026ee8..3a9f902 100644
--- a/kidgrow-business/kidgrow-usercenter/kidgrow-usercenter-biz/src/main/resources/mapper/SysHospitalMapper.xml
+++ b/kidgrow-business/kidgrow-usercenter/kidgrow-usercenter-biz/src/main/resources/mapper/SysHospitalMapper.xml
@@ -129,4 +129,59 @@
         <include refid="where"/>
         order by id desc
     </select>
+    <sql id="whereList">
+        <where>
+            DEP.is_del = 0
+            AND HOS.is_del = 0
+            <if test="p.isScreen != null and p.isScreen !=''">
+                and is_screen = #{p.isScreen}
+            </if>
+            <if test="p.isAnswer != null and p.isAnswer !=''">
+                and is_answer = #{p.isAnswer}
+            </if>
+            <if test="p.hospitalState != null and p.hospitalState !=''">
+                and hospital_state = #{p.hospitalState}
+            </if>
+            <if test="p.hospitalProvince != null and p.hospitalProvince !=''">
+                and hospital_province = #{p.hospitalProvince}
+            </if>
+            <if test="p.hospitalCity != null and p.hospitalCity !=''">
+                and hospital_city = #{p.hospitalCity}
+            </if>
+            <if test="p.hospitalArea != null and p.hospitalArea !=''">
+                and hospital_area = #{p.hospitalArea}
+            </if>
+            <if test="p.hospitalName != null and p.hospitalName !=''">
+                and hospital_name LIKE concat('%',#{p.hospitalName},'%')
+            </if>
+        </where>
+    </sql>
+    <select id="findHospitalList" resultType="com.kidgrow.usercenter.vo.HospitalListVo">
+        SELECT
+        DEP.department_name,
+        DEP.id department_id,
+        DEP.server_user_name,
+        DEP.server_user_id,
+        DEP.org_id,
+        DEP.is_del,
+        DEP.enabled,
+        HOS.id hospital_id,
+        HOS.hospital_name,
+        HOS.hospital_code,
+        HOS.hospital_province,
+        HOS.hospital_city,
+        HOS.hospital_area,
+        HOS.hospital_tel,
+        HOS.hospital_state,
+        HOS.hospital_link,
+        HOS.is_screen,
+        HOS.is_answer,
+        HOS.tenant_id,
+        HOS.create_time
+        FROM
+	sys_department DEP
+	LEFT JOIN sys_hospital HOS ON DEP.hospital_id = HOS.id
+        <include refid="whereList"/>
+        order by create_time  desc
+    </select>
 </mapper>
\ No newline at end of file

--
Gitblit v1.8.0