fix: subscription extend instead of overwrite, improve placeholder pages
- Subscription purchase now extends expire_time when user has active subscription, instead of cancelling and replacing - Admin subscription creation uses same extend logic - Subscribe page shows "续费" button and extend message for renewals - Help and contact pages: add pink header, centered icon + text
这个提交包含在:
@@ -118,9 +118,16 @@ Page({
|
||||
return
|
||||
}
|
||||
|
||||
var isRenew = self.data.subscription && self.data.subscription.status === 'active' && self.data.subRemaining > 0
|
||||
var planDays = plan.key === 'yearly' ? 365 : 30
|
||||
var title = isRenew ? '确认续费' : '确认支付'
|
||||
var content = isRenew
|
||||
? '在现有订阅基础上延长' + planDays + '天,模拟支付 ¥' + plan.price + '?(测试环境)'
|
||||
: '模拟支付 ¥' + plan.price + '?(测试环境)'
|
||||
|
||||
wx.showModal({
|
||||
title: '确认支付',
|
||||
content: '模拟支付 ¥' + plan.price + '?(测试环境)',
|
||||
title: title,
|
||||
content: content,
|
||||
success: function (res) {
|
||||
if (res.confirm) {
|
||||
self.doPurchase(plan)
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
</view>
|
||||
|
||||
<button class="btn-primary btn-primary-gold" bindtap="onPurchase" disabled="{{purchasing}}" loading="{{purchasing}}">
|
||||
确认支付
|
||||
{{subscription && subscription.status === 'active' && subRemaining > 0 ? '续费' : '确认支付'}}
|
||||
</button>
|
||||
<view class="agreement">支付即表示同意《订阅协议》</view>
|
||||
</view>
|
||||
|
||||
在新工单中引用
屏蔽一个用户