guq преди 7 години
родител
ревизия
2362c15466
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      applications/sale/sale-server/src/main/resources/mapper/ProdInOutMapper.xml

+ 1 - 1
applications/sale/sale-server/src/main/resources/mapper/ProdInOutMapper.xml

@@ -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>