feat(publish): 推荐押金支持第二件折扣并放宽押金下限
- 推荐押金皮肤规则新增「第2件起计价」比例,组内首件按原价、后续件按比例计入 - 押金低于推荐押金允许发布,弹窗提示并禁用无忧租号保险 - 用户主动改低押金后不再被推荐值覆盖,点「使用推荐」恢复自动跟随
This commit is contained in:
@@ -105,7 +105,10 @@ const {
|
||||
handleFireLevelInput,
|
||||
handleAcceleratedSaleRatioInput,
|
||||
useRecommendedDeposit,
|
||||
handleDepositInput,
|
||||
handleDepositBlur,
|
||||
depositBelowRecommended,
|
||||
selectCompensationPlan,
|
||||
setQuantityMode,
|
||||
clampAcceleratedSaleRatioInput,
|
||||
useReferenceSaleRatio,
|
||||
@@ -128,6 +131,11 @@ const {
|
||||
notifySuccess: message => ElMessage.success(message),
|
||||
notifyWarning: message => ElMessage.warning(message),
|
||||
notifyError: message => ElMessage.error(message),
|
||||
alertDepositBelowRecommended: message =>
|
||||
void ElMessageBox.alert(message, '押金低于推荐押金', {
|
||||
confirmButtonText: '我知道了',
|
||||
type: 'warning',
|
||||
}),
|
||||
})
|
||||
|
||||
const agreementDialogVisible = ref(false)
|
||||
@@ -571,6 +579,7 @@ function selectDailyLoss(value: string | number) {
|
||||
:min="0"
|
||||
:controls="false"
|
||||
:placeholder="priceConfig.deposit_placeholder"
|
||||
@input="handleDepositInput"
|
||||
@blur="handleDepositBlur"
|
||||
/>
|
||||
<button class="recommend-button" type="button" @click="useRecommendedDeposit">
|
||||
@@ -581,7 +590,7 @@ function selectDailyLoss(value: string | number) {
|
||||
<span v-for="item in depositBreakdownItems" :key="`${item.label}-${item.count}`">
|
||||
{{ item.label }}<template v-if="item.count > 1"> x{{ item.count }}</template> ¥{{
|
||||
formatMoney(item.amount)
|
||||
}}
|
||||
}}<template v-if="item.detail">({{ item.detail }})</template>
|
||||
</span>
|
||||
</div>
|
||||
</label>
|
||||
@@ -779,7 +788,7 @@ function selectDailyLoss(value: string | number) {
|
||||
type="button"
|
||||
class="coverage-option"
|
||||
:class="{ active: form.compensation_plan === 'normal' }"
|
||||
@click="form.compensation_plan = 'normal'"
|
||||
@click="selectCompensationPlan('normal')"
|
||||
>
|
||||
<span class="coverage-option-top">
|
||||
<strong>普通赔付</strong>
|
||||
@@ -790,8 +799,12 @@ function selectDailyLoss(value: string | number) {
|
||||
<button
|
||||
type="button"
|
||||
class="coverage-option"
|
||||
:class="{ active: form.compensation_plan === 'insurance' }"
|
||||
@click="form.compensation_plan = 'insurance'"
|
||||
:class="{
|
||||
active: form.compensation_plan === 'insurance',
|
||||
'is-disabled': depositBelowRecommended,
|
||||
}"
|
||||
:aria-disabled="depositBelowRecommended"
|
||||
@click="selectCompensationPlan('insurance')"
|
||||
>
|
||||
<span class="coverage-option-top">
|
||||
<strong>无忧租号保险</strong>
|
||||
@@ -800,6 +813,9 @@ function selectDailyLoss(value: string | number) {
|
||||
</em>
|
||||
</span>
|
||||
<span>额外保障账号市场价值,费率按实际纯币结算金额扣除</span>
|
||||
<em v-if="depositBelowRecommended" class="coverage-disabled-reason">
|
||||
押金低于推荐押金,无法购买无忧租号保险
|
||||
</em>
|
||||
<em v-if="isQualityOwner && form.is_premium" class="coverage-special-rate">
|
||||
已享极品专区专享费率
|
||||
</em>
|
||||
|
||||
Reference in New Issue
Block a user