From 75a2623173bcc4a235aa1f99f7ef28519186160b Mon Sep 17 00:00:00 2001
From: yanghb <yanghb>
Date: 星期五, 21 四月 2023 11:24:25 +0800
Subject: [PATCH] 代码调整

---
 UserTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/crossCity/dao/mapping/OrderCrossCityMapper.xml |   30 ++++++++----------------------
 1 files changed, 8 insertions(+), 22 deletions(-)

diff --git a/UserTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/crossCity/dao/mapping/OrderCrossCityMapper.xml b/UserTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/crossCity/dao/mapping/OrderCrossCityMapper.xml
index 86a9c5f..da5618c 100644
--- a/UserTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/crossCity/dao/mapping/OrderCrossCityMapper.xml
+++ b/UserTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/crossCity/dao/mapping/OrderCrossCityMapper.xml
@@ -32,7 +32,6 @@
         <result column="mileage" property="mileage"/>
         <result column="payManner" property="payManner"/>
         <result column="payType" property="payType"/>
-        <result column="holidayFee" property="holidayFee"/>
         <result column="orderMoney" property="orderMoney"/>
         <result column="redPacketMoney" property="redPacketMoney"/>
         <result column="couponMoney" property="couponMoney"/>
@@ -44,11 +43,7 @@
         <result column="seatNumber" property="seatNumber" />
         <result column="activityId" property="activityId"/>
         <result column="companyId" property="companyId"/>
-        <result column="taxiCardId" property="taxiCardId"/>
-        <result column="userTaxiCardId" property="userTaxiCardId"/>
-        <result column="discountAmount" property="discountAmount"/>
         <result column="payMoney" property="payMoney"/>
-        <result column="thankYouFee" property="thankYouFee"/>
         <result column="passengers" property="passengers"/>
         <result column="passengersPhone" property="passengersPhone"/>
         <result column="sort" property="sort"/>
@@ -346,9 +341,7 @@
 		h.money as cancelMoney,
 		h.reason as cancelReason,
 		h.remark as cancelRemark,
-		CONCAT(j.startTime, '-', j.endTime) as lineShiftTime,
-		a.holidayFee,
-		a.discountAmount as taxiCardMoney
+		CONCAT(j.startTime, '-', j.endTime) as lineShiftTime
         from t_order_cross_city a
 		left join t_driver b on (a.driverId = b.id)
 		left join t_car c on (a.carId = c.id)
@@ -375,8 +368,7 @@
         state as state,
         oldState as oldState,
         remark as remark,
-        peopleNumber as num,
-        thankYouFee
+        peopleNumber as num
         from t_order_cross_city where userId = #{uid} order by insertTime desc limit #{pageNum}, #{size}
     </select>
 
@@ -395,7 +387,7 @@
 
     <select id="queryInvoiceOrder" resultType="map">
         select
-        id as orderId,
+        id as id,
         DATE_FORMAT(travelTime, '%Y-%m-%d %H:%i') as time,
         startAddress as startAddress,
         endAddress as endAddress,
@@ -406,22 +398,16 @@
         (3) as orderType
         from t_order_cross_city where state in (8, 9)
         <if test="type == 1">
-            and (invoiceId is null or invoiceId in (select id from t_invoice where state = 3))
+            and invoiceId is null and invoiceId in (select id from t_invoice where state != 2)
         </if>
         <if test="type == 2">
             and invoiceId in (select id from t_invoice where state = 2)
         </if>
-        <if test="null != startTime">
-            and travelTime >= #{startTime}
+        <if test="null != startTime and null != endTime">
+            and travelTime between #{startTime} and #{endTime}
         </if>
-        <if test="null != startMoney">
-            and payMoney >= #{startMoney}
-        </if>
-        <if test="null != endTime">
-            and  #{endTime}>= travelTime
-        </if>
-        <if test="null != endMoney">
-            and   #{endMoney}>=payMoney
+        <if test="null != startMoney and null != endMoney">
+            and payMoney between #{startMoney} and #{endMoney}
         </if>
         <if test="null !=uid">
             and userId = #{uid}

--
Gitblit v1.7.1