From bf2acefcf5ba801d3e4a4f507c5f064fc93625cc Mon Sep 17 00:00:00 2001 From: Pu Zhibing <393733352@qq.com> Date: 星期四, 21 八月 2025 00:25:09 +0800 Subject: [PATCH] Merge branch 'master' of http://120.76.84.145:10101/gitblit/r/java/QianYunTong --- DriverQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/DriverServiceMapper.xml | 122 +++++----------------------------------- 1 files changed, 17 insertions(+), 105 deletions(-) diff --git a/DriverQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/DriverServiceMapper.xml b/DriverQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/DriverServiceMapper.xml index 08b48b0..f701b96 100644 --- a/DriverQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/DriverServiceMapper.xml +++ b/DriverQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/DriverServiceMapper.xml @@ -78,57 +78,16 @@ </select> <select id="queryOrderMoneyDataFromDriver" resultType="com.stylefeng.guns.modular.system.model.vo.DriverOrderDataNextVo"> - select * from ( select - orderNum, - 1 as type, + orderType as type, insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_private_car - where driverId = #{uid} and state in (8,9) + money as orderMoney + from t_income + where userType =2 and objectId = #{uid} and type =2 <if test="sTime !=null"> and insertTime between #{sTime} and #{eTime} </if> - - union all - - select - orderNum, - 2 as type, - insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_taxi - where driverId = #{uid} and state in (8,9) - <if test="sTime !=null"> - and insertTime between #{sTime} and #{eTime} - </if> - - union all - - select - orderNum, - 3 as type, - insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_cross_city - where driverId = #{uid} and state in (8,9) - <if test="sTime !=null"> - and insertTime between #{sTime} and #{eTime} - </if> - ) t1 - order by t1.orderTime desc + order by insertTime desc @@ -138,65 +97,18 @@ </select> <select id="queryOrderMoneyDataFromDriverAll" resultType="com.stylefeng.guns.modular.system.model.vo.DriverOrderDataNextVo"> - select * from ( select - orderNum, - 1 as type, + orderType as type, insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_private_car - where driverId = #{uid} and state in (8,9) + money as orderMoney + from t_income + where userType =2 and objectId = #{uid} and type =2 <if test="sTime !=null"> and insertTime between #{sTime} and #{eTime} </if> - - union all - - select - orderNum, - 2 as type, - insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_taxi - where driverId = #{uid} and state in (8,9) - <if test="sTime !=null"> - and insertTime between #{sTime} and #{eTime} - </if> - - union all - - select - orderNum, - 3 as type, - insertTime as orderTime, - id as orderId, - boardingAddress as startAddress, - getoffAddress as endAddress, - state, - orderMoney - from t_order_cross_city - where driverId = #{uid} and state in (8,9) - <if test="sTime !=null"> - and insertTime between #{sTime} and #{eTime} - </if> - ) t1 - order by t1.orderTime desc - - - - - - - + order by insertTime desc </select> + <select id="queryOrderPromotionFromDriver" resultType="com.stylefeng.guns.modular.system.model.vo.DriverOrderDataNextVo"> select * from ( select @@ -209,7 +121,7 @@ state, promotionMoney as orderMoney from t_order_private_car - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> @@ -226,7 +138,7 @@ state, promotionMoney as orderMoney from t_order_taxi - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> @@ -243,7 +155,7 @@ state, promotionMoney as orderMoney from t_order_cross_city - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> @@ -270,7 +182,7 @@ state, promotionMoney as orderMoney from t_order_private_car - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> @@ -287,7 +199,7 @@ state, promotionMoney as orderMoney from t_order_taxi - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> @@ -304,7 +216,7 @@ state, promotionMoney as orderMoney from t_order_cross_city - where promotionDriverId = #{uid} and state in (8,9) + where promotionDriverId = #{uid} and state in (8,9) and successTime is not null <if test="sTime !=null"> and successTime between #{sTime} and #{eTime} </if> -- Gitblit v1.7.1