From 9cb0e31627c5050991940d149affc2dbdd86c833 Mon Sep 17 00:00:00 2001
From: qirong <2032486488@qq.com>
Date: 星期四, 15 六月 2023 11:57:47 +0800
Subject: [PATCH] 多选部门标签

---
 src/main/resources/mapper/SubjectMapper.xml |   22 ++++++++++++++++++++++
 1 files changed, 22 insertions(+), 0 deletions(-)

diff --git a/src/main/resources/mapper/SubjectMapper.xml b/src/main/resources/mapper/SubjectMapper.xml
index 9f40fea..2d12715 100644
--- a/src/main/resources/mapper/SubjectMapper.xml
+++ b/src/main/resources/mapper/SubjectMapper.xml
@@ -131,7 +131,29 @@
       <if test="level != null ">
         and level= #{level}
       </if>
+      <if test="name != null ">
+        and level_name like concat('%',#{name},'%')
+      </if>
     </where>
   </select>
 
+  <select id="getName" resultMap="BaseResultMap">
+      SELECT
+      <include refid="Base_Column_List"/>
+      FROM t_subject
+      where name = #{name}
+  </select>
+
+  <select id="getNames" resultMap="BaseResultMap">
+    SELECT
+    <include refid="Base_Column_List"/>
+    FROM t_subject
+    where name in
+    <foreach item="name" collection="names" open="(" separator=","
+             close=")">
+      #{name}
+    </foreach>
+
+  </select>
+
 </mapper>

--
Gitblit v1.8.0