<select id="searchRoutes" parameterType="com.xaeds.taecs.domain.xlzx.TouristRoute"
resultMap="BaseResultMapExt">
select
<include refid="Base_Column_List_Ext" />
from "t_tourist_route" tr
<where>
<if test="departureDate!=null">
<if test="returnDate!=null">
and tr.departure_date BETWEEN #{departureDate,jdbcType=DATE} AND
#{returnDate,jdbcType=DATE}
</if>
</if>
<if test="routeName!=null">
and tr.route_name like '%'||#{routeName,jdbcType=VARCHAR}||'%'
</if>
<if test="routeNumber!=null">
and tr.route_number like '%'||#{routeNumber,jdbcType=VARCHAR}||'%'
</if>
<if test="publisherId!=null">
and tr.publisher_id = #{publisherId,jdbcType=INTEGER}
</if>
</where>
</select>