|
|
|
|
@ -164,15 +164,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
|
|
|
|
|
|
<select id="queryStockDetailList" resultType="com.shkj.wms.vo.SysStockNumDetailVo" parameterType="com.shkj.wms.bo.SysStockNumQueryBo"> |
|
|
|
|
SELECT |
|
|
|
|
item.goods_no, |
|
|
|
|
item.color, |
|
|
|
|
item.vehiche_model, |
|
|
|
|
group_concat( stock.qr_code) as qr_code, |
|
|
|
|
stock.qty, |
|
|
|
|
IFNULL( qty, 0 )+ IFNULL( in_qty, 0 )- IFNULL( out_qty, 0 ) AS useQty, |
|
|
|
|
IFNULL( in_qty, 0 ) AS in_qty, |
|
|
|
|
IFNULL( out_qty, 0 ) AS out_qty, |
|
|
|
|
DATEDIFF( curtime(), stock.batch ) AS storageAge, |
|
|
|
|
branch.branch_name, |
|
|
|
|
loc.layer, |
|
|
|
|
loc.tunnel, |
|
|
|
|
loc.location_code, |
|
|
|
|
con.container_code, |
|
|
|
|
stock.batch |
|
|
|
|
@ -199,7 +196,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
|
and con.container_code= #{containerCode} |
|
|
|
|
</if> |
|
|
|
|
</where> |
|
|
|
|
order by loc.location_name |
|
|
|
|
GROUP BY |
|
|
|
|
item.color, |
|
|
|
|
item.vehiche_model, |
|
|
|
|
stock.qty, |
|
|
|
|
storageAge, |
|
|
|
|
loc.tunnel, |
|
|
|
|
loc.location_code, |
|
|
|
|
con.container_code, |
|
|
|
|
stock.batch |
|
|
|
|
|
|
|
|
|
</select> |
|
|
|
|
|
|
|
|
|
|