入库单优化bug

This commit is contained in:
xuhaihui 2025-10-22 14:16:22 +08:00
parent 69598c46fa
commit 0c152a9e6f
1 changed files with 4 additions and 1 deletions

View File

@ -588,6 +588,9 @@ public class MaterialInBillEditPluginExt extends AbstractEcmaBillPlugin implemen
// BigDecimal notaxamount = EcNumberHelper.toBigDecimal(this.getModel().getValue("notaxamount"), i);//源码
BigDecimal notaxamount = EcNumberHelper.toBigDecimal(this.getModel().getValue("notaxamount", i));//金额 //二开修改
BigDecimal qty = EcNumberHelper.toBigDecimal(this.getModel().getValue("qty", i));// 数量
if (qty.compareTo(BigDecimal.ZERO) == 0) {
return;
}
BigDecimal price = notaxamount.divide(qty, 10, RoundingMode.HALF_UP);//金额 ÷ 数量
this.getModel().setValue("price", price, i);//"入库单价" = 金额 ÷ 数量