From ddcef762ff4a159e132c68dfec512c60a68a53e6 Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期五, 01 十二月 2023 18:21:24 +0800 Subject: [PATCH] 更新接口 --- DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/UserCouponRecordMapper.xml | 99 ------------------------------------------------- 1 files changed, 0 insertions(+), 99 deletions(-) diff --git a/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/UserCouponRecordMapper.xml b/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/UserCouponRecordMapper.xml index 34d1f95..6ab69e8 100644 --- a/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/UserCouponRecordMapper.xml +++ b/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/UserCouponRecordMapper.xml @@ -19,103 +19,4 @@ <result column="activityType" property="activityType"/> </resultMap> - - - <select id="queryAvailable" resultType="int"> - select - count(a.id) - from t_user_coupon_record a - left join t_company b on (a.companyId = b.id) - where a.expirationTime >= now() - <if test="null != uid"> - and a.userId = #{uid} - </if> - <if test="null != companyId"> - and a.companyId = #{companyId} - </if> - <if test="null != state"> - and a.state = #{state} - </if> - <if test="null != couponUseType"> - and a.couponUseType = #{couponUseType} - </if> - <if test="null != money"> - and if(a.couponType = 1, a.money < #{money}, a.fullMoney < #{money}) - </if> - </select> - - <select id="queryCoupon" resultType="map"> - select - a.id as id, - a.money as money, - a.couponUseType as userType, - DATE_FORMAT(a.expirationTime, '%Y-%m-%d') as time, - a.couponType as `type`, - a.fullMoney as fullMoney, - a.state as state, - b.`name` as `name` - from t_user_coupon_record a - left join t_company b on (a.companyId = b.id) - where a.expirationTime >= now() - <if test="null != uid"> - and a.userId = #{uid} - </if> - <if test="null != companyId"> - and a.companyId = #{companyId} - </if> - <if test="null != state"> - and a.state = #{state} - </if> - <if test="null != couponUseType"> - and a.couponUseType = #{couponUseType} - </if> - <if test="null != money"> - and if(a.couponType = 1, a.money < #{money}, a.fullMoney < #{money}) - </if> - order by a.insertTime desc - <if test="null != pageNum and null != size"> - limit #{pageNum}, #{size} - </if> - </select> - - - - - - - <select id="queryMyCoupons" resultType="map"> - select - a.id as id, - a.money as money, - a.couponUseType as userType, - DATE_FORMAT(a.expirationTime, '%Y-%m-%d') as time, - a.couponType as `type`, - a.fullMoney as fullMoney, - a.state as state, - b.`name` as `name` - from t_user_coupon_record a - left join t_company b on (a.companyId = b.id) - where 1 = 1 - <if test="null != uid"> - and a.userId = #{uid} - </if> - <if test="null != state"> - <if test="state == 1"> - and a.state = 1 - </if> - <if test="state == 2"> - and a.state in (2,3) - </if> - </if> - order by a.insertTime desc - <if test="null != pageNum and null != size"> - limit #{pageNum}, #{size} - </if> - </select> - - - - <update id="updateTimeOut"> - update t_user_coupon_record set state = 3 where now() > expirationTime and state = 1 - </update> </mapper> \ No newline at end of file -- Gitblit v1.7.1