From 23c4967b4cb8dbce8277f830f7152d315c5a4a57 Mon Sep 17 00:00:00 2001 From: luo <2855143437@qq.com> Date: 星期一, 25 十二月 2023 09:25:17 +0800 Subject: [PATCH] 12.25 --- guns-management/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/BannerMapper.xml | 13 +++++++++++++ 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/guns-management/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/BannerMapper.xml b/guns-management/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/BannerMapper.xml index 56abc0c..2f6a4e5 100644 --- a/guns-management/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/BannerMapper.xml +++ b/guns-management/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/BannerMapper.xml @@ -7,4 +7,17 @@ <select id="getBanners" resultType="com.stylefeng.guns.modular.system.warpper.res.BannerRes"> select id, img_url as imgUrl, content from t_banner where `position` = #{position} order by `sort` desc </select> + <select id="list" resultType="com.stylefeng.guns.modular.system.dto.BannerVo"> + SELECT tb.id,tb.position,tb.sort,tb.img_url as imgUrl,su.`name` as createBy,tb.insert_time as insertTime + from t_banner tb + LEFT JOIN sys_user su on tb.insert_user_id = su.id + <where> + <if test="null != position"> + and tb.position = #{position} + </if> + <if test="null != sort"> + and tb.sort = #{sort} + </if> + </where> + </select> </mapper> \ No newline at end of file -- Gitblit v1.7.1