Update ErpPurchaseReturnServiceImpl.java

This commit is contained in:
zhenxi-he 2024-06-18 09:51:18 +08:00 committed by GitHub
parent 3941e790b6
commit cb1bf8c91a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -136,7 +136,7 @@ public class ErpPurchaseReturnServiceImpl implements ErpPurchaseReturnService {
purchaseReturn.setDiscountPercent(BigDecimal.ZERO);
}
purchaseReturn.setDiscountPrice(MoneyUtils.priceMultiplyPercent(purchaseReturn.getTotalPrice(), purchaseReturn.getDiscountPercent()));
purchaseReturn.setTotalPrice(purchaseReturn.getTotalPrice().subtract(purchaseReturn.getDiscountPrice().add(purchaseReturn.getOtherPrice())));
purchaseReturn.setTotalPrice(purchaseReturn.getTotalPrice().subtract(purchaseReturn.getDiscountPrice()).add(purchaseReturn.getOtherPrice()));
}
private void updatePurchaseOrderReturnCount(Long orderId) {
@ -301,4 +301,4 @@ public class ErpPurchaseReturnServiceImpl implements ErpPurchaseReturnService {
return purchaseReturnItemMapper.selectListByReturnIds(returnIds);
}
}
}