Sfoglia il codice sorgente

修改查询组用户问题

zh 3 anni fa
parent
commit
ecae6e9b7e

+ 3 - 3
boman-modules/boman-system/src/main/resources/mapper/system/BomanGroupMapper.xml

@@ -18,7 +18,7 @@
     </resultMap>
 
     <resultMap type="com.boman.domain.BomanGroupUser" id="BomanGroupUserResult">
-        <id property="id" column="id"/>
+        <id property="id" column="g_u_id"/>
         <result property="userId" column="user_id"/>
         <result property="userName" column="user_name"/>
         <result property="groupId" column="group_id"/>
@@ -37,10 +37,10 @@
     </sql>
 
     <select id="selectGroupList" parameterType="com.boman.domain.BomanGroup" resultMap="BomanGroupResult">
-        select g.id, g.group_name, g.status, g.number,  g.create_by, g.create_time, g.is_del, gu.user_name , gu.id
+        select g.id, g.group_name, g.status, g.number,  g.create_by, g.create_time, g.is_del, gu.user_name , gu.id as g_u_id
         from boman_group g
         left join boman_group_user gu on gu.group_id = g.id
-        where g.is_del = 'N'
+        where gu.is_del = 'N'
         <if test="groupName != null and groupName != ''">
             AND g.group_name like concat('%', #{groupName}, '%')
         </if>