wangzhuo преди 2 години
родител
ревизия
e3624b1036

+ 6 - 0
ruoyi-warehouse/src/main/java/com/ruoyi/basicData/service/impl/TWarehouseServiceImpl.java

@@ -490,6 +490,9 @@ public class TWarehouseServiceImpl implements ITWarehouseService {
                                                                String level,
                                                                Integer pageNo,
                                                                Integer pageSize){
+        if ("null".equals(warehouseCode)){
+            warehouseCode = null;
+        }
         return tWarehouseMapper.queryGoodsAccountByPageV1(warehouseCode, ownerSocialIdentifier,ownerCode,ownerName, goodsName, specifications,
                 producing, materialQuality, level, pageNo, pageSize);
     }
@@ -498,6 +501,9 @@ public class TWarehouseServiceImpl implements ITWarehouseService {
     public List<Map<String, Object>> queryGoodsAccountDetailByPageV1(String warehouseCode,String ownerName,String ownerCode,String ownerSocialIdentifier,String goodsName,String specifications,
                                                                      String producing,String materialQuality,String level, String receiptDoc,String billOfLading,
                                                                      String areaName,String areaCode,String slotName,String slotCode,Integer pageNo,Integer pageSize){
+        if ("null".equals(warehouseCode)){
+            warehouseCode = null;
+        }
         return tWarehouseMapper.queryGoodsAccountDetailByPageV1(warehouseCode, ownerName, ownerCode, ownerSocialIdentifier, goodsName, specifications,
                 producing, materialQuality, level, receiptDoc, billOfLading, areaName, areaCode, slotName, slotCode, pageNo, pageSize);
     }

+ 1 - 1
ruoyi-warehouse/src/main/resources/mapper/basicData/TWarehouseMapper.xml

@@ -433,7 +433,7 @@
         LEFT JOIN t_warehousebills TWB ON TWG.f_originalbillno = TWB.f_billno
         <where>
             TW.del_flag = '0'
-            <if test="warehouseCode != null  and warehouseCode != ''"> TWG.f_warehouseid = #{warehouseCode}</if>
+            <if test="warehouseCode != null  and warehouseCode != ''"> and TWG.f_warehouseid = #{warehouseCode}</if>
             <if test="ownerName != null  and ownerName != ''"> and TC.f_name like concat('%', #{ownerName}, '%')</if>
             <if test="ownerCode != null  and ownerCode != ''"> and TC.f_id = #{ownerCode}</if>
             <if test="ownerSocialIdentifier != null  and ownerSocialIdentifier != ''"> and TC.uscc = #{ownerSocialIdentifier}</if>