From 624c9eec90d59297800f03276f8518daa1bd9f94 Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期五, 04 八月 2023 09:23:02 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml | 40 ++++++++++++++++++++++++++++++++++++++++ 1 files changed, 40 insertions(+), 0 deletions(-) diff --git a/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml b/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml index 4fab90f..25c46c6 100644 --- a/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml +++ b/cloud-server-course/src/main/resources/mapper/TCoursePackageMapper.xml @@ -52,4 +52,44 @@ and ts.`state` = 1 </select> + + + <select id="queryCoursePackageLists" resultType="map"> + select + a.id, + CONCAT(a.province, a.city) as city, + a.storeId, + b.`name` as coursePackageType, + a.`name`, + a.maxSubscribeNumber, + CONCAT('购买后', a.validDays, '天内有效') as validDays, + a.sort, + a.`status`, + a.state + from t_course_package a + left join t_course_package_type b on (a.coursePackageTypeId = b.id) + where a.state != 3 + <if test="null != item.provinceCode and '' != item.provinceCode"> + and a.provinceCode = #{item.provinceCode} + </if> + <if test="null != item.cityCode and '' != item.cityCode"> + and a.cityCode = #{item.cityCode} + </if> + <if test="null != item.coursePackageTypeId"> + and a.coursePackageTypeId = #{item.coursePackageTypeId} + </if> + <if test="null != item.storeId"> + and a.storeId = #{item.storeId} + </if> + <if test="null != item.name and '' != item.name"> + and a.name line CONCAT('%', #{item.name}, '%') + </if> + <if test="null != item.status"> + and a.status = #{item.status} + </if> + <if test="null != item.state"> + and a.state = #{item.state} + </if> + order by a.insertTime desc + </select> </mapper> -- Gitblit v1.7.1