he2802 1 éve
szülő
commit
7b10b24212

+ 4 - 4
zhongzheng-system/src/main/resources/mapper/modules/order/OrderHandleMapper.xml

@@ -55,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             AND oh.education_type_id = #{educationTypeId}
         </if>
         <if test="searchKey != null and searchKey != ''">
-            AND ((oh.create_username like concat('%', #{searchKey}, '%'))>0 or oh.handle_order_sn = #{searchKey})
+            AND (select count(*) from `order` o left JOIN `user` u  on o.user_id = u.user_id left JOIN order_goods og on o.order_sn = og.order_sn LEFT JOIN goods g on og.goods_id = g.goods_id where  o.handle_order_sn = oh.handle_order_sn and (u.realname like concat('%', #{searchKey}, '%') or (u.id_card = #{searchKey}) or (g.goods_name like concat('%', #{searchKey}, '%'))))>0
         </if>
         <if test="goodsType != null">
             AND oh.goods_type = #{goodsType}
@@ -66,14 +66,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="handleOrderSn != null and handleOrderSn != ''">
             AND oh.handle_order_sn = #{handleOrderSn}
         </if>
-        <if test="refundStatus != null and refundStatus != ''">
+        <if test="refundStatus != null">
             AND oh.refund_status = #{refundStatus}
         </if>
         <if test="startTime != null and startTime != ''">
-            AND oh.check_time &gt;= #{refundStatus}
+            AND oh.check_time &gt;= #{startTime}
         </if>
         <if test="endTime != null and endTime != ''">
-            AND oh.check_time &lt;= #{refundStatus}
+            AND oh.check_time &lt;= #{endTime}
         </if>
         <if test="payStatus != null">
             AND oh.pay_status = #{payStatus}