zhangyuewww 3 年之前
父节点
当前提交
2df09cb5f5

+ 1 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/java/com/yh/saas/plugin/yiliangyiyun/service/impl/WarehouseInOutInfoServiceImpl.java

@@ -1562,6 +1562,7 @@ public class WarehouseInOutInfoServiceImpl extends ServiceImpl<WarehouseInOutInf
         //  仓库ID
         pageView.put("baseId", warehouseInOutInfo.getBaseId());
         pageView.put("searchType", warehouseInOutInfo.getSearchType());
+        pageView.put("searchKeyWord", warehouseInOutInfo.getSearchKeyWord());
         pageView.put("startDate", warehouseInOutInfo.getStartDate());
         pageView.put("endDate", warehouseInOutInfo.getEndDate());
         pageView.put("pageSize", warehouseInOutInfo.getPageSize());

+ 8 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/resources/mapper/WarehouseInOutInfoMapper.xml

@@ -185,6 +185,10 @@
                 AND w.in_out_flag = '2'
             </if>
         </if>
+        <if test="searchKeyWord != null and searchKeyWord != ''">
+            AND (lower(w.contract_no) like lower(CONCAT('%',#{searchKeyWord},'%'))
+            OR lower(w.car_no) like lower(CONCAT('%',#{searchKeyWord},'%')))
+        </if>
         <if test="startDate != null">
             AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") &gt;=
             DATE_FORMAT(#{startDate},"%Y%m%d"))
@@ -234,6 +238,10 @@
                 AND w.in_out_flag = '2'
             </if>
         </if>
+        <if test="searchKeyWord != null and searchKeyWord != ''">
+            AND (lower(w.contract_no) like lower(CONCAT('%',#{searchKeyWord},'%'))
+            OR lower(w.car_no) like lower(CONCAT('%',#{searchKeyWord},'%')))
+        </if>
         <if test="startDate != null">
             AND (DATE_FORMAT(w.in_out_date,"%Y%m%d") &gt;=
             DATE_FORMAT(#{startDate},"%Y%m%d"))