jinlin
2024-02-21 b27d06b8f0b805efd16e28fd80a57a0ed8a053ce
zt/core/src/main/resources/mapper/log/SysLogOperationDao.xml
@@ -20,11 +20,8 @@
    </sql>
    <select id="getList" resultType="com.zt.modules.log.model.SysLogOperation">
        select * from (
        select a.*
        ,(SELECT replace(GROUP_CONCAT(aa.name),',',';') FROM sys_role aa,sys_role_user bb WHERE aa.id=bb.role_id AND bb.user_id = a.creator) AS role_names
        from sys_log_operation a
        ) a
            from sys_log_operation a
        <where>
            <if test="whereSql!=null">
                ${whereSql}
@@ -33,32 +30,12 @@
                and 1 = 1
            </if>
            <if test="action == 'xtbmybm'">
                and role_names NOT LIKE '%xtgly%'  OR role_names NOT LIKE '%xtsjy%'
                and request_uri not IN (
                SELECT
                a.dict_label AS urlLabel
                FROM
                sys_dict_data a,
                sys_dict_type b
                WHERE 1=1
                AND b.dict_type = 'adminURL'
                AND b.id = a.dict_type_id
                AND b.is_delete = 0
                )
                and a.creator not in (select user_id from sys_role_user
                where role_id in (select id from sys_role where code in ('xtglybm','xtbmybm','xtsjybm')))
            </if>
            <if test="action == 'xtsjybm'">
                and role_names LIKE '%xtgly%'  OR role_names LIKE '%xtsjy%'
                and request_uri IN (
                SELECT
                a.dict_label AS urlLabel
                FROM
                sys_dict_data a,
                sys_dict_type b
                WHERE 1=1
                AND b.dict_type = 'adminURL'
                AND b.id = a.dict_type_id
                AND b.is_delete = 0
                )
                and a.creator in (select user_id from sys_role_user
                where role_id in (select id from sys_role where code in ('xtglybm','xtbmybm')))
            </if>
            <if test="action == 'other'">
                and a.creator = ${currentUserId}