修复:内测问题修改:免费课程及课程详情代码优化、积分支付默认值、书籍价格显示
This commit is contained in:
@@ -290,7 +290,11 @@ const handlePointsInput = (value: any) => {
|
||||
}
|
||||
|
||||
// 重新计算实付款
|
||||
calculateFinalPrice()
|
||||
const result = Math.max(
|
||||
0,
|
||||
totalAmount.value - pointsDiscounted.value - promotionDiscounted.value - vipDiscounted.value
|
||||
)
|
||||
finalAmount.value = result
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -314,9 +318,11 @@ const calculateFinalPrice = () => {
|
||||
props?.userInfo?.jf || 0,
|
||||
Math.floor(orderAmountAfterDiscount - couponAmount)
|
||||
)
|
||||
|
||||
pointsDiscounted.value = pointsUsableMax.value
|
||||
|
||||
// 限制当前积分不超过最大值
|
||||
if (pointsDiscounted.value > pointsUsableMax.value) {
|
||||
if (pointsDiscounted.value >= pointsUsableMax.value) {
|
||||
pointsDiscounted.value = pointsUsableMax.value
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user