@@ -540,7 +540,7 @@
</select>
<update id="updatePiTotal" parameterType="long">
update ProdInOut SET
- pi_total = ( select IFNULL(sum(IFNULL(pd_total,0)),0) FROM ProdIODetail WHERE pd_piid=#{id}),
+ pi_total = ( select IFNULL(sum(IFNULL(pd_ordertotal,0)),0) FROM ProdIODetail WHERE pd_piid=#{id}),
pi_nettotal = ( select IFNULL(sum(IFNULL(pd_nettotal,0)),0) FROM ProdIODetail WHERE pd_piid=#{id})
where pi_id =#{id}
</update>