解决出入库统计报表计算的bug
This commit is contained in:
@@ -417,7 +417,7 @@
|
||||
</select>
|
||||
|
||||
<select id="findInOutDetailStatistic" parameterType="com.jsh.erp.datasource.entities.DepotItemExample" resultMap="ResultWithInfoExMap">
|
||||
select sum(di.oper_number) operNumber, sum(di.all_price) allPrice
|
||||
select ifnull(sum(di.oper_number),0) operNumber, ifnull(sum(di.all_price),0) allPrice
|
||||
from jsh_depot_head dh
|
||||
left join jsh_depot_item di on di.header_id=dh.id and ifnull(di.delete_flag,'0') !='1'
|
||||
left join jsh_material m on m.id=di.material_id and ifnull(m.delete_flag,'0') !='1'
|
||||
@@ -610,7 +610,7 @@
|
||||
</select>
|
||||
|
||||
<select id="findInOutMaterialCountStatistic" parameterType="com.jsh.erp.datasource.entities.DepotItemExample" resultMap="ResultInOutMaterialCount">
|
||||
select sum(di.basic_number) numSum, sum(di.all_price) priceSum
|
||||
select ifnull(sum(di.basic_number),0) numSum, ifnull(sum(di.all_price),0) priceSum
|
||||
from jsh_depot_head dh
|
||||
left join jsh_depot_item di on dh.id=di.header_id and ifnull(di.delete_flag,'0') !='1'
|
||||
left join jsh_material m on m.id=di.material_id and ifnull(m.delete_flag,'0') !='1'
|
||||
@@ -780,7 +780,7 @@
|
||||
</select>
|
||||
|
||||
<select id="findAllocationStatistic" parameterType="com.jsh.erp.datasource.entities.DepotItemExample" resultMap="ResultWithInfoExMap">
|
||||
select sum(di.oper_number) operNumber, sum(di.all_price) allPrice
|
||||
select ifnull(sum(di.oper_number),0) operNumber, ifnull(sum(di.all_price),0) allPrice
|
||||
from jsh_depot_head dh
|
||||
left join jsh_depot_item di on di.header_id=dh.id and ifnull(di.delete_flag,'0') !='1'
|
||||
left join jsh_material m on m.id=di.material_id and ifnull(m.delete_flag,'0') !='1'
|
||||
|
||||
Reference in New Issue
Block a user