2021与蓝度共同重构项目,服务端
zhanzhiqin
2022-09-16 8567b31b38b222426468d1d677fea9cf915fb90e
dao/src/main/resources/mapper/PlatformFileMapper.xml
@@ -24,13 +24,17 @@
        *
        FROM
        platform_file t1
        <where>
            <if test="fileIdList!=null">
                t1.file_id IN
                <foreach collection="fileIdList" open="(" close=")" item="fileId" separator=",">
                    #{fileId}
                </foreach>
            </if>
        </where>
        LEFT JOIN platform_file_user t2 ON t1.file_Id = t2.file_Id
        WHERE
        1 =1
        <if test="userId!=null">
            AND
            t2.user_id = #{userId}
        </if>
        <if test="keyword != null and keyword != ''">
            AND (
            t1.file_name LIKE CONCAT('%', #{keyword},'%')
            )
        </if>
    </select>
</mapper>