|
|
@@ -709,6 +709,36 @@
|
|
|
</where>
|
|
|
</select>
|
|
|
|
|
|
+ <select id="selectDriverCountById" resultType="com.sckw.transport.model.vo.DriverListVo">
|
|
|
+ SELECT
|
|
|
+ count(1) AS count,
|
|
|
+ b.truck_no AS truckNo
|
|
|
+ FROM
|
|
|
+ kwt_waybill_order b
|
|
|
+ <where>
|
|
|
+ b.del_flag = 0
|
|
|
+ AND b.type = '1'
|
|
|
+ AND b.status in (7, 8, 13)
|
|
|
+ <if test="driverParam.lOrderId != null and driverParam.lOrderId != ''">
|
|
|
+ AND b.l_order_id =#{driverParam.lOrderId}
|
|
|
+ </if>
|
|
|
+ <if test="driverParam.driverName != null and driverParam.driverName != '' or ( driverParam.driverPhone != null and driverParam.driverPhone != '' ) or ( driverParam.truckNo != null and driverParam.truckNo != '' ) ">
|
|
|
+ <!-- and (-->
|
|
|
+ <if test="driverParam.driverName != null and driverParam.driverName != ''">
|
|
|
+ and b.driver_name like concat('%',#{driverParam.driverName},'%')
|
|
|
+ </if>
|
|
|
+ <if test="driverParam.driverPhone != null and driverParam.driverPhone != ''">
|
|
|
+ and b.driver_phone like concat('%',#{driverParam.driverPhone},'%')
|
|
|
+ </if>
|
|
|
+ <if test="driverParam.truckNo != null and driverParam.truckNo != ''">
|
|
|
+ and b.truck_no like concat('%',#{driverParam.truckNo},'%')
|
|
|
+ </if>
|
|
|
+ </if>
|
|
|
+ GROUP BY
|
|
|
+ b.truck_no
|
|
|
+ </where>
|
|
|
+ </select>
|
|
|
+
|
|
|
<select id="selectLogisticOrderList" resultType="com.sckw.transport.api.model.dto.LogisticsOrderDTO">
|
|
|
SELECT
|
|
|
DISTINCT a.id AS lOrderId,
|