yangdamao hai 1 ano
pai
achega
9570ecac03

+ 0 - 2
zhongzheng-system/src/main/java/com/zhongzheng/modules/order/bo/OrderInvoiceQueryBo.java

@@ -118,6 +118,4 @@ public class OrderInvoiceQueryBo extends BaseEntity {
 	private Long applyStartTime;
 	@ApiModelProperty("搜索kEY")
 	private String searchKey;
-	@ApiModelProperty("订单号")
-	private String orderSn;
 }

+ 3 - 5
zhongzheng-system/src/main/resources/mapper/modules/order/OrderInvoiceMapper.xml

@@ -111,10 +111,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="userId != null and userId != ''">
             AND oi.user_id = #{userId}
         </if>
-        <if test="orderSn != null and orderSn != ''">
-            AND (SELECT COUNT(oio.id) FROM order_invoice_order oio
-            LEFT JOIN order_goods og ON oio.order_goods_id = og.order_goods_id WHERE oio.invoice_id = oi.invoice_id AND og.order_sn = #{orderSn}) > 0
-        </if>
         <if test="applyStartTime != null and applyStartTime != ''">
             AND oi.apply_time >= #{applyStartTime}
         </if>
@@ -126,7 +122,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             u.realname like concat('%', #{searchKey}, '%')
             or u.id_card like concat('%', #{searchKey}, '%')
             or oi.invoice_code like concat('%', #{searchKey}, '%')
-            or u.invoice_num like concat('%', #{searchKey}, '%'))
+            or (SELECT COUNT(oio.id) FROM order_invoice_order oio
+            LEFT JOIN order_goods og ON oio.order_goods_id = og.order_goods_id WHERE oio.invoice_id = oi.invoice_id AND og.order_sn = #{searchKey}) > 0
+            )
         </if>
         ORDER BY oi.invoice_id DESC
     </select>