From fdc3fe8b7e0cf97b225ecc9135a05f4bb2090518 Mon Sep 17 00:00:00 2001
From: tangzy <tangzy123456>
Date: Fri, 03 Sep 2021 17:53:21 +0800
Subject: [PATCH] 1.注册

---
 src/main/java/org/springblade/modules/zc/mapper/ZcMapper.xml |   14 ++++++++++----
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/src/main/java/org/springblade/modules/zc/mapper/ZcMapper.xml b/src/main/java/org/springblade/modules/zc/mapper/ZcMapper.xml
index 22bdc0e..3b806cb 100644
--- a/src/main/java/org/springblade/modules/zc/mapper/ZcMapper.xml
+++ b/src/main/java/org/springblade/modules/zc/mapper/ZcMapper.xml
@@ -3,7 +3,7 @@
 <mapper namespace="org.springblade.modules.zc.mapper.ZcMapper">
 
     <!-- 通用查询映射结果 -->
-    <resultMap id="zcResultMap" type="org.springblade.modules.zc.entity.Zc">
+    <resultMap id="zcResultMap" type="org.springblade.modules.zc.vo.ZcVO">
         <id column="id" property="id"/>
         <result column="username" property="username"/>
         <result column="password" property="password"/>
@@ -13,6 +13,7 @@
         <result column="zctime" property="zctime"/>
         <result column="type" property="type"/>
         <result column="deptid" property="deptid"/>
+        <result column="parentId" property="parentId"/>
     </resultMap>
 
 
@@ -23,13 +24,18 @@
         z.sname,
         z.cardid,
         z.type,
-        d.dept_name AS deptid
+        z.deptid
         FROM
-        act_zc z
-        LEFT JOIN blade_dept d ON d.id = z.deptid where 1=1
+        act_zc z where 1=1
         <if test="zc.type!=null and zc.type!=''">
             and z.type=#{zc.type}
         </if>
+        <if test="zc.sname!=null and zc.sname!=''">
+            and z.sname like concat(concat('%', #{zc.sname}),'%')
+        </if>
+        <if test="zc.username!=null and zc.username!=''">
+            and z.username like concat(concat('%', #{zc.username}),'%')
+        </if>
     </select>
 
 

--
Gitblit v1.9.3