|
|
@@ -3274,7 +3274,10 @@ public class OrderDonServiceImpl extends ServiceImpl<OrderDonMapper, OrderDon> i
|
|
|
DateTime offset = DateUtil.offsetMonth(now, goodsDonSku.getMonths());
|
|
|
long totalDays = DateUtil.between(now, offset, DateUnit.DAY) + 1;
|
|
|
//待支付价格
|
|
|
- BigDecimal payUpgradePackagePrice = differPrice.multiply(BigDecimal.valueOf(day)).divide(BigDecimal.valueOf(totalDays), 0, RoundingMode.HALF_UP);
|
|
|
+ //每日单价
|
|
|
+ BigDecimal singlePrice = differPrice.divide(BigDecimal.valueOf(totalDays), 0, RoundingMode.HALF_UP);
|
|
|
+
|
|
|
+ BigDecimal payUpgradePackagePrice = singlePrice.multiply(BigDecimal.valueOf(day));
|
|
|
if (payRequest.getDonMoney().compareTo(payUpgradePackagePrice) < 0) {
|
|
|
payRequest.setDonMoney(payUpgradePackagePrice);
|
|
|
}
|