|
|
@@ -125,6 +125,10 @@
|
|
|
#{subject_id}
|
|
|
</foreach>
|
|
|
</if>
|
|
|
+ <if test="valid == 0 ">
|
|
|
+ and date_format(now(), '%Y-%m-%d') >= DATE_FORMAT(valid_begin_time, '%Y-%m-%d')
|
|
|
+ and date_format(now(), '%Y-%m-%d') <= DATE_FORMAT(valid_end_time, '%Y-%m-%d')
|
|
|
+ </if>
|
|
|
<!-- 数据范围过滤 -->
|
|
|
${params.dataScope}
|
|
|
</where>
|
|
|
@@ -169,7 +173,10 @@
|
|
|
<if test="endTime != null and endTime != ''"><!-- 结束时间检索 -->
|
|
|
AND DATE_FORMAT(t.creat_time,'%Y-%m-%d') <= date_format(#{endTime},'%Y-%m-%d')
|
|
|
</if>
|
|
|
-
|
|
|
+ <if test="valid == 0 ">
|
|
|
+ and date_format(now(), '%Y-%m-%d') >= DATE_FORMAT(valid_begin_time, '%Y-%m-%d')
|
|
|
+ and date_format(now(), '%Y-%m-%d') <= DATE_FORMAT(valid_end_time, '%Y-%m-%d')
|
|
|
+ </if>
|
|
|
<if test="validLength != null "> and valid_length = #{validLength}</if>
|
|
|
<if test="validBeginTime != null "> and valid_begin_time = #{validBeginTime}</if>
|
|
|
<if test="validEndTime != null "> and valid_end_time = #{validEndTime}</if>
|