陶杰
2024-09-10 ddd049fd5e732828bc5b739d9cc270ac707d1dbc
src/main/resources/mapper/coupon/CouponTemplateMapperCustom.xml
@@ -76,8 +76,11 @@
        SELECT *
        FROM t_coupon_template t
        WHERE t.deleted = FALSE
        AND t.get_start_date <= NOW()
        AND NOW() <= t.get_end_date
        <if test="param.category != null and param.category != '' and param.category == 'activity' ">
            AND t.get_start_date &lt;= NOW()
            AND NOW() &lt;= t.get_end_date
        </if>
        <if test="param.category != null and param.category != ''">
            AND category =  #{param.category}
        </if>