瀏覽代碼

问题修改

xiaochen 2 年之前
父節點
當前提交
f353769545
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. 4 1
      src/main/resources/mapper/DeliveryMapper.xml

+ 4 - 1
src/main/resources/mapper/DeliveryMapper.xml

@@ -172,7 +172,10 @@
     <select id="getScanIsNot" resultType="java.util.Map">
         select
             (select ifnull(amount,0) from tld_inventory where id = #{id}) as amount,
-            (select ifnull(sum(num),0) from tld_ask_goods_vitrual where wbs = #{wbs} and wllb_code = #{wllbCode} and storage_location_code = #{storageLocationCode} and produc_date = #{producDate} and account_sleeve = #{companyNumber}) as vitrualNum
+            (select ifnull(sum(num),0) from tld_ask_goods_vitrual where wbs = #{wbs} and wllb_code = #{wllbCode} and storage_location_code = #{storageLocationCode} and produc_date = #{producDate} and account_sleeve = #{companyNumber}
+              <if test="serial != null and serial !=''">
+                  and serial = #{serial}
+              </if>) as vitrualNum
         from dual
     </select>
     <!-- 查询销售交货单原始数据 -->