feat(库存汇总报表-新):新增存汇总报表-新1.6添加大于0

This commit is contained in:
chengzhaofeng 2025-03-14 16:49:03 +08:00
parent cbe70b856d
commit 2f9fc83c3e

View File

@ -1512,6 +1512,9 @@
<if test="dto.item != null and dto.item != ''">
and wi.ITEM_BO = concat('ItemBO:', #{dto.site}, ',', #{dto.item}, ',1')
</if>
<if test="dto.notAllowZero">
and wi.QTY_ON_HAND > 0
</if>
group by wi.SITE,
wi.ERP_STORAGE_LOCATION,
wi.STATUS,
@ -1528,10 +1531,6 @@
from a
left join wip.item i on a.ITEM_BO = i.HANDLE
left join momx.sys_dict_item sdi on sdi.DICT_TYPE = 'INVENTORY_ID_STATUS' and sdi.DEL_FLAG = '0' and sdi.TENANT_ID = a.site and a.status = sdi.ITEM_VALUE
where 1 = 1
<if test="dto.notAllowZero">
and a.qtySum > 0
</if>
order by a.ERP_STORAGE_LOCATION, i.ITEM, a.STATUS
</select>
<select id="pageInventorySummaryReportNewTwo"
@ -1560,9 +1559,14 @@
ELSE sum(wi.QTY_ON_HAND)
END AS qtySum
from wms.wms_inventory wi
where wi.ERP_STORAGE_LOCATION is not null and wi.SITE = #{dto.site} and wi.STATUS = #{dto.status} and
wi.ERP_STORAGE_LOCATION = #{dto.erpStorageLocation} and wi.ITEM_BO = concat('ItemBO:', #{dto.site}, ',',
#{dto.item}, ',1')
where wi.ERP_STORAGE_LOCATION is not null
and wi.SITE = #{dto.site}
and wi.STATUS = #{dto.status}
and wi.ERP_STORAGE_LOCATION = #{dto.erpStorageLocation}
and wi.ITEM_BO = concat('ItemBO:', #{dto.site}, ',', #{dto.item}, ',1')
<if test="dto.notAllowZero">
and wi.QTY_ON_HAND > 0
</if>
group by
wi.QUALITY_INSPECTION_STATUS, wi.QTY_ON_HAND)
select