fix: 隐私协议合规整改——登录页文案改'我已阅读并同意';订阅支付页新增默认不勾选协议勾选框,未勾选拦截支付并引导(应对审核:不得默认自动同意)

This commit is contained in:
2026-09-13 18:55:14 +08:00
parent c7f879a0cf
commit 336cc3d2c9
2 changed files with 36 additions and 5 deletions
+1 -1
View File
@@ -47,7 +47,7 @@
<text v-if="loginAgreed">✓</text>
</view>
<text class="agreement-text">
登录即表示同意
我已阅读并同意
<text class="agreement-link" @click.stop="openAgreement('terms')">《用户协议》</text>
和
<text class="agreement-link" @click.stop="openAgreement('privacy')">《隐私政策》</text>
+34 -3
View File
@@ -69,13 +69,22 @@
class="pay-btn"
:loading="loading"
:disabled="loading"
:class="{ unagreed: !payAgreed }"
@click="handlePay"
>
<text class="pay-btn-text">立即支付 ¥{{ currentPrice }}</text>
</button>
<text class="pay-agreement">
点击支付即表示同意《用户协议》和《隐私政策》
</text>
<view class="pay-agreement-row">
<view class="pay-checkbox" :class="{ checked: payAgreed }" @click="payAgreed = !payAgreed">
<text v-if="payAgreed">✓</text>
</view>
<text class="pay-agreement-text">
我已阅读并同意
<text class="pay-agreement-link" @click.stop="openAgreement('terms')">《用户协议》</text>
和
<text class="pay-agreement-link" @click.stop="openAgreement('privacy')">《隐私政策》</text>
</text>
</view>
</view>
<view class="footer-spacer"></view>
@@ -127,6 +136,7 @@ const currentPrice = computed(() => PLAN_MAP[selectedPlan.value].price)
const currentProductId = computed(() => PLAN_MAP[selectedPlan.value].productId)
const loading = ref(false)
const payAgreed = ref(false) // 协议勾选:默认不勾选,用户自主选择(审核合规)
// H5 支付相关状态
const h5PayUrl = ref('')
const showH5Fallback = ref(false)
@@ -143,7 +153,15 @@ function isH5() {
return false
}
async function openAgreement(type) {
uni.navigateTo({ url: '/pages/agreement/agreement?type=' + (type || 'terms') })
}
async function handlePay() {
if (!payAgreed.value) {
uni.showToast({ title: '请先阅读并勾选同意《用户协议》和《隐私政策》', icon: 'none' })
return
}
if (!userStore.isLoggedIn) {
uni.showToast({ title: '请先登录', icon: 'none' })
return
@@ -577,3 +595,16 @@ onShareAppMessage(() => ({
}
}
</style>
<style scoped>
.pay-agreement-row { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; }
.pay-checkbox {
width: 18px; height: 18px; border-radius: 4px;
border: 1.5px solid var(--text-muted); background: var(--glass-bg);
display: flex; align-items: center; justify-content: center;
font-size: 12px; color: #fff; flex-shrink: 0;
}
.pay-checkbox.checked { background: var(--color-brand); border-color: var(--color-brand); }
.pay-agreement-text { font-size: 11px; color: var(--text-tertiary); }
.pay-agreement-link { color: var(--color-brand); }
button.unagreed { opacity: 0.55; }
</style>