<select id="time" resultType="com.**" parameterType="com.*">
select
<!--这里的update_time和下面两个保持一致,#{这里面是传入的实参} -->
**update_time**
from t_make_title_job a
where
<if test="updateStartTime != null">
and **update_time** >= #{updateStartTime}
</if>
<if test="updateEndTime != null">
and **update_time** <= #{updateEndTime}
</if>
</select>
parameterType里面的参数需写的
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty("更新时间,时间段起始时间")
private Date updateStartTime;
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty("更新时间,时间段结束时间")
private Date updateEndTime;