|
|
@@ -73,13 +73,13 @@
|
|
|
LEFT JOIN ( SELECT headpir, name, code FROM sys_users ) f ON f.code = a.code
|
|
|
<trim prefix="WHERE" prefixOverrides="and | or">
|
|
|
<if test="destination != null and destination != ''">
|
|
|
- a.destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
+ and a.destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
</if>
|
|
|
<if test="titleTravel != null and titleTravel != ''">
|
|
|
- a.title_travel like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
+ and a.title_travel like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
</if>
|
|
|
<if test="jdrq != null and jdrq != ''">
|
|
|
- #{startTime} <![CDATA[ <= ]]> a.jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
+ and #{startTime} <![CDATA[ <= ]]> a.jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
</if>
|
|
|
</trim>
|
|
|
UNION ALL
|
|
|
@@ -113,13 +113,13 @@
|
|
|
LEFT JOIN ( SELECT headpir, name, code FROM sys_supplier ) f ON f.code = a.code
|
|
|
<trim prefix="WHERE" prefixOverrides="and | or">
|
|
|
<if test="destination != null and destination != ''">
|
|
|
- a.destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
+ and a.destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
</if>
|
|
|
<if test="titleTravel != null and titleTravel != ''">
|
|
|
- a.offer_name like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
+ and a.offer_name like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
</if>
|
|
|
<if test="jdrq != null and jdrq != ''">
|
|
|
- #{startTime} <![CDATA[ <= ]]> a.jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
+ and #{startTime} <![CDATA[ <= ]]> a.jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
</if>
|
|
|
</trim>
|
|
|
) e
|
|
|
@@ -294,7 +294,13 @@
|
|
|
and code = #{code}
|
|
|
</if>
|
|
|
<if test="destination != null and destination != ''">
|
|
|
- destination = #{destination}
|
|
|
+ and destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
+ </if>
|
|
|
+ <if test="titleTravel != null and titleTravel != ''">
|
|
|
+ and title_travel like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
+ </if>
|
|
|
+ <if test="jdrq != null and jdrq != ''">
|
|
|
+ and #{startTime} <![CDATA[ <= ]]> jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
</if>
|
|
|
</trim>
|
|
|
UNION ALL
|
|
|
@@ -311,7 +317,13 @@
|
|
|
and code = #{code}
|
|
|
</if>
|
|
|
<if test="destination != null and destination != ''">
|
|
|
- destination = #{destination}
|
|
|
+ and destination like CONCAT(CONCAT('%', #{destination}), '%')
|
|
|
+ </if>
|
|
|
+ <if test="titleTravel != null and titleTravel != ''">
|
|
|
+ and offer_name like CONCAT(CONCAT('%', #{titleTravel}), '%')
|
|
|
+ </if>
|
|
|
+ <if test="jdrq != null and jdrq != ''">
|
|
|
+ and #{startTime} <![CDATA[ <= ]]> jdrq and #{endTime} <![CDATA[ > ]]> jdrq
|
|
|
</if>
|
|
|
</trim>
|
|
|
) a
|
|
|
@@ -359,6 +371,7 @@
|
|
|
a.jdrq,
|
|
|
a.look_num,
|
|
|
a.destination,
|
|
|
+ a.people_num as peopleAll,
|
|
|
b.name,
|
|
|
b.headpir,
|
|
|
c.countNum,
|
|
|
@@ -427,4 +440,22 @@
|
|
|
LEFT JOIN sys_supplier b ON a.code = b.code
|
|
|
LEFT JOIN (SELECT count(*) AS routeNum,code FROM bus_supplier_route GROUP BY code) c ON a.code = c.code
|
|
|
</select>
|
|
|
+ <!-- 查询指定报价单的状态是否是2跟3 -->
|
|
|
+ <select id="getReleseType" resultType="Map">
|
|
|
+ SELECT
|
|
|
+ b.orderTypeCount
|
|
|
+ FROM
|
|
|
+ bus_supplier_release a
|
|
|
+ join (select count(*) as orderTypeCount,code,demand_uuid from bus_private_ordering_type where order_type = '2' or order_type = '3' GROUP BY code,demand_uuid) b on a.code = b.code and a.demand_uuid = b.demand_uuid
|
|
|
+ where a.uuid = #{uuid}
|
|
|
+ </select>
|
|
|
+ <!-- 查询指定游记的收藏 -->
|
|
|
+ <select id="getTravelConllection" resultType="OrderingConllection">
|
|
|
+ SELECT
|
|
|
+ b.code,b.headpir
|
|
|
+ FROM
|
|
|
+ bus_collection a
|
|
|
+ left join sys_users b on a.code = b.code
|
|
|
+ where ordering_uuid = #{uuid}
|
|
|
+ </select>
|
|
|
</mapper>
|