diff --git a/application/admin/controller/fc/Plan.php b/application/admin/controller/fc/Plan.php
index e51dfee..835bfbe 100644
--- a/application/admin/controller/fc/Plan.php
+++ b/application/admin/controller/fc/Plan.php
@@ -34,3 +34,4 @@ class Plan extends Backend
$this->model = new \app\admin\model\FcPlan;
}
}
+
diff --git a/application/admin/controller/fc/Setting.php b/application/admin/controller/fc/Setting.php
index fdd8242..0a875b5 100644
--- a/application/admin/controller/fc/Setting.php
+++ b/application/admin/controller/fc/Setting.php
@@ -58,6 +58,8 @@ class Setting extends Backend
// 兼容旧 ui.* 键(用户端已优先读 base.*)
'ui.siteName' => ['value' => $appName, 'group_key' => 'ui', 'remark' => '站点名称'],
'ui.logo' => ['value' => $logo, 'group_key' => 'ui', 'remark' => '自定义LOGO'],
+ // 提审合规模式开关(1=开启防审, 0=正式上线模式)
+ 'pay.virtualPayAudit' => ['value' => isset($params['virtualPayAudit']) ? (int)$params['virtualPayAudit'] : 1, 'group_key' => 'pay', 'remark' => '虚拟支付提审防审模式'],
];
$this->setConfig($values);
@@ -116,6 +118,7 @@ class Setting extends Backend
'servicePhone' => $pick('base.servicePhone', '400-000-0000'),
'aboutUs' => $pick('base.aboutUs', ''),
'shareTitle' => $pick('base.shareTitle', ''),
+ 'virtualPayAudit' => (int)$pick('pay.virtualPayAudit', 1),
];
}
}
diff --git a/application/admin/view/fc/setting/index.html b/application/admin/view/fc/setting/index.html
index 3eb6c6a..04d27c6 100644
--- a/application/admin/view/fc/setting/index.html
+++ b/application/admin/view/fc/setting/index.html
@@ -48,6 +48,14 @@
+
diff --git a/application/api/controller/Distribution.php b/application/api/controller/Distribution.php
index 3097d9b..a76a6ba 100644
--- a/application/api/controller/Distribution.php
+++ b/application/api/controller/Distribution.php
@@ -81,12 +81,13 @@ class Distribution extends V1
'inviterNickname' => $inviterNickname,
'shareUrl' => $shareUrl,
'posterUrl' => '',
- // 最低提现金额(后台「分销设置」下发,默认 50)
- 'minWithdraw' => (float)$this->cfg('dist.minWithdraw', 50),
+ // 最低提现金额(后台「分销设置」下发,微信审核规范要求无门槛,默认 0.1)
+ 'minWithdraw' => (float)$this->cfg('dist.minWithdraw', 0.1),
// 分销比例与配置规则
'level1Rate' => (float)$this->cfg('dist.level1Rate', 20),
'level2Rate' => (float)$this->cfg('dist.level2Rate', 10),
- 'settleCycle' => (string)$this->cfg('dist.settleCycle', 'T+7'),
+ 'settleCycle' => (string)$this->cfg('dist.settleCycle', '实时结算'),
+ 'ruleContent' => (string)$this->cfg('dist.ruleContent', ''),
'enabled' => (int)$this->cfg('dist.enabled', 1),
// 提现收款人实名(未填写时前端需先采集)
'realname' => isset($ext['realname']) ? (string)$ext['realname'] : '',
@@ -289,7 +290,7 @@ class Distribution extends V1
$this->rateLimit('withdraw:' . $uid, 3, 60);
$amount = round((float)$this->input('amount', 0), 2);
- $min = (float)$this->cfg('dist.minWithdraw', 50);
+ $min = (float)$this->cfg('dist.minWithdraw', 0.1);
if ($amount <= 0) {
$this->fail('提现金额不合法');
diff --git a/application/api/controller/Setting.php b/application/api/controller/Setting.php
index 5d96b63..b1f1ba1 100644
--- a/application/api/controller/Setting.php
+++ b/application/api/controller/Setting.php
@@ -48,6 +48,14 @@ class Setting extends V1
],
// 余额支付密码开关(开启后余额支付需验证 6 位支付密码,用户在余额中心设置)
'payPasswordEnabled' => (int)$this->cfg('pay.payPasswordEnabled', 0) === 1,
+ // 微信小程序虚拟支付提审合规保护开关(1=开启合规拦截,0=正式放开,默认1安全过审)
+ 'virtualPayAudit' => (function() {
+ $sysVal = \think\Db::name('config')->where('name', 'virtual_pay_audit')->value('value');
+ if ($sysVal !== null && $sysVal !== '') {
+ return (int)$sysVal === 1;
+ }
+ return (int)$this->cfg('pay.virtualPayAudit', 1) === 1;
+ })(),
]);
}
diff --git a/application/common/library/FcConfig.php b/application/common/library/FcConfig.php
index 3b9961b..4d21098 100644
--- a/application/common/library/FcConfig.php
+++ b/application/common/library/FcConfig.php
@@ -44,6 +44,7 @@ class FcConfig
self::item('fc_wx_secret', 'AppSecret', 'password', '', '仅服务端保存与调用;已配置时留空表示不修改(微信登录用)'),
self::item('fc_wx_tplAudit', '审核结果模板 ID', 'string', $pick('wx.tplAudit', ''), '小程序订阅消息:审核结果通知(公众平台 → 订阅消息)'),
self::item('fc_wx_tplTransfer', '提现到账模板 ID', 'string', $pick('wx.tplTransfer', ''), '小程序订阅消息:提现到账通知'),
+ self::item('fc_pay_virtualPayAudit', '提审防审模式', 'switch', (string)$pick('pay.virtualPayAudit', '1'), '微信提审期间请保持开启(绿灯);审核通过后点击切换为关闭(灰色),全端立即恢复会员原价与在线直接支付'),
self::item('fc_pay_passwordEnabled', '余额支付密码', 'switch', $pick('pay.payPasswordEnabled', '0'), '开启后,用户使用余额支付时需验证 6 位支付密码;默认关闭'),
self::item('fc_admin_userIds', '后台接口管理员 ID', 'string', $pick('admin.userIds', ''), '允许调用 /api/v1/admin/** 的用户 ID,多个用逗号分隔(留空 = 全部禁止)'),
self::item('fc_admin_mobiles', '后台接口管理员手机号', 'string', $pick('admin.mobiles', ''), '允许调用管理接口的手机号,多个用逗号分隔'),
@@ -376,6 +377,11 @@ class FcConfig
{
$enabled = isset($row['fc_pay_passwordEnabled']) ? (int)$row['fc_pay_passwordEnabled'] : 0;
self::put('pay.payPasswordEnabled', $enabled ? 1 : 0, 'pay', '余额支付密码开关(开启后余额支付需验证 6 位支付密码)');
+
+ if (isset($row['fc_pay_virtualPayAudit'])) {
+ $audit = (int)$row['fc_pay_virtualPayAudit'];
+ self::put('pay.virtualPayAudit', $audit ? 1 : 0, 'pay', '微信提审防审模式开关(1=审核中隐藏支付, 0=正常运营)');
+ }
}
/**
diff --git a/scratch/add_miniapp_config.php b/scratch/add_miniapp_config.php
new file mode 100644
index 0000000..e9b0fd1
--- /dev/null
+++ b/scratch/add_miniapp_config.php
@@ -0,0 +1,33 @@
+where('name', 'configgroup')->value('value');
+$group = json_decode($groupVal, true) ?: [];
+$group['miniapp'] = '小程序配置';
+think\Db::name('config')->where('name', 'configgroup')->update(['value' => json_encode($group, JSON_UNESCAPED_UNICODE)]);
+
+$exist = think\Db::name('config')->where('name', 'virtual_pay_audit')->find();
+if (!$exist) {
+ think\Db::name('config')->insert([
+ 'name' => 'virtual_pay_audit',
+ 'group' => 'miniapp',
+ 'title' => '提审防审模式',
+ 'tip' => '微信审核期间请开启;审核通过后设为关闭,全端立即恢复会员原价与微信支付直接开通',
+ 'type' => 'radio',
+ 'content' => json_encode(['1' => '开启(微信审核中:隐藏直接支付)', '0' => '关闭(审核已通过:全端恢复直接支付)'], JSON_UNESCAPED_UNICODE),
+ 'value' => '1',
+ 'rule' => 'required'
+ ]);
+} else {
+ think\Db::name('config')->where('name', 'virtual_pay_audit')->update([
+ 'group' => 'miniapp',
+ 'title' => '提审防审模式',
+ 'tip' => '微信审核期间请开启;审核通过后设为关闭,全端立即恢复会员原价与微信支付直接开通',
+ 'type' => 'radio',
+ 'content' => json_encode(['1' => '开启(微信审核中:隐藏直接支付)', '0' => '关闭(审核已通过:全端恢复直接支付)'], JSON_UNESCAPED_UNICODE),
+ ]);
+}
+echo "CONFIG_SUCCESS\n";
diff --git a/scratch/check_member_tags.js b/scratch/check_member_tags.js
new file mode 100644
index 0000000..c67868a
--- /dev/null
+++ b/scratch/check_member_tags.js
@@ -0,0 +1,22 @@
+const fs = require('fs');
+
+const files = [
+ 'uniapp/pages/member/index.vue',
+ 'uniapp/pages/member/recharge.vue'
+];
+
+let allOk = true;
+for (const file of files) {
+ const content = fs.readFileSync(file, 'utf8');
+ const openTemplate = (content.match(//g) || []).length;
+ const closeTemplate = (content.match(/<\/template>/g) || []).length;
+ const openScript = (content.match(/
+
\ No newline at end of file
diff --git a/uniapp/pages/distribution/index.vue b/uniapp/pages/distribution/index.vue
index 0eb7f6b..10051eb 100644
--- a/uniapp/pages/distribution/index.vue
+++ b/uniapp/pages/distribution/index.vue
@@ -1,32 +1,30 @@
-
+
-
-
-
-
-
- 规则
-
-
-
+
+
-
-
-
- 分享好内容,天天赚佣金
- 好友消费自动返佣 · {{ overview.settleCycle || 'T+7' }} 自动结算提现
-
-
+
+
-
+
可提现佣金
+
+ 规则
+
+
-
- 提现
+
+
+ 提现记录
+ ›
+
+
+ 提现
+
@@ -162,9 +160,9 @@
- 一级直推 {{ overview.l1Count || 0 }} 人(返佣 {{ overview.level1Rate || 20 }}%)
+ 直接邀请 {{ overview.l1Count || 0 }} 人(奖励 {{ overview.level1Rate || 20 }}%)
·
- 二级间推 {{ overview.l2Count || 0 }} 人(返佣 {{ overview.level2Rate || 10 }}%)
+ 间接邀请 {{ overview.l2Count || 0 }} 人
@@ -299,63 +297,7 @@
-
-
-
-
-
-
-
- 提现记录
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 暂无提现记录
-
-
-
-
-
-
- 提现到微信零钱
-
- {{ statusText(w.status) }}
-
-
- {{ timeText(w.createdAt) }}
- 单号 {{ w.withdrawNo }}
- 失败原因:{{ w.failReason }}
-
-
- -¥{{ money(w.amount) }}
-
- {{ w.transferStatus === 'WAIT_USER_CONFIRM' ? (w.packageInfo ? '去确认收款' : '查看详情') : '转账中' }}
-
- ›
-
-
-
-
- {{ recordsExpanded ? '收起' : '查看全部提现记录' }}
-
-
-
-
@@ -488,7 +430,7 @@
- 最低提现 ¥{{ minWithdrawText }},预计 24 小时内直转微信零钱
+ 无门槛即时提现,系统自动打款直达微信零钱,免手续费
-
- 1
-
- 一级直推返佣:{{ overview.level1Rate || 20 }}%
- 好友通过您的专属海报或链接注册,其在平台发布信息、置顶、开通会员或购买便民服务,您立享订单金额 {{ overview.level1Rate || 20 }}% 的现金佣金。
-
+
+
+
-
- 2
-
- 二级间推返佣:{{ overview.level2Rate || 10 }}%
- 您的一级好友再次邀请新朋友消费,您仍可获得订单金额 {{ overview.level2Rate || 10 }}% 的间接分销奖励,裂变无忧。
+
+
+
+ 1
+
+ 推广奖励:{{ overview.level1Rate || 20 }}%
+ 好友通过您的专属海报或链接注册并在平台消费,您立享订单金额 {{ overview.level1Rate || 20 }}% 的现金推广奖励,多推多得。
+
-
-
- 3
-
- 结算周期与到账:{{ overview.settleCycle || 'T+7' }}
- 订单支付完成后佣金即刻进入待结算,满 {{ overview.settleCycle || 'T+7' }} 天后自动转入可提现余额,随时提现至微信零钱。
+
+ 2
+
+ 提现门槛说明:无门槛提现
+ 平台不设任何隐性提现门槛或做任务要求,只要账户拥有可提现佣金即可发起申请,支持任意金额即时提现。
+
-
-
- 4
-
- 提现规则与到账保障
- 最低提现金额为 ¥{{ minWithdrawText }},平台支持微信商家转账直接到账微信零钱,无任何手续费。
+
+ 3
+
+ 结算时效:实时结算(T+0)
+ 推广订单完成后,佣金自动即时结算到账。提现发起后系统全自动即时处理,直接到账您的当前微信零钱。
+
+
+
+
+ 4
+
+ 提现方式与服务保障
+ 平台支持微信商家转账官方通道直达微信零钱,免收任何提现手续费。如遇网络异常,随时可联系在线客服协助处理。
+
@@ -669,7 +619,7 @@ export default {
activeTab: 'team', // 'team' | 'commissions' | 'withdraw'
level: 0,
commissionStatus: '',
- minWithdraw: 50,
+ minWithdraw: 0.1,
showWithdraw: false,
showDetailModal: false,
activeWithdrawItem: null,
@@ -697,12 +647,11 @@ export default {
mainTabs: [
{ key: 'team', name: '我的团队' },
{ key: 'commissions', name: '收益明细' },
- { key: 'withdraw', name: '提现记录' },
],
levelTabs: [
{ label: '全部', value: 0 },
- { label: '一级直推', value: 1 },
- { label: '二级间推', value: 2 },
+ { label: '直接邀请', value: 1 },
+ { label: '间接邀请', value: 2 },
],
commissionStatusTabs: [
{ label: '全部', value: '' },
@@ -1617,6 +1566,14 @@ export default {
/**
* 打开提现弹层
*/
+ /**
+ * 跳转独立提现记录列表页
+ */
+ goWithdrawRecords() {
+ uni.navigateTo({
+ url: '/pages/distribution/withdraw-records',
+ })
+ },
openWithdraw() {
if (this.withdrawableNum <= 0) {
uni.showToast({ title: '暂无可提现佣金,快去邀请好友吧', icon: 'none' })
@@ -1747,8 +1704,11 @@ export default {
await distributionApi.withdraw({ amount, channel: 'wxpay' })
this.showWithdraw = false
this.withdrawAmount = ''
- uni.showToast({ title: '提现申请已提交', icon: 'none' })
+ uni.showToast({ title: '提现申请已提交', icon: 'success' })
await this.refreshAfterWithdraw()
+ setTimeout(() => {
+ this.goWithdrawRecords()
+ }, 600)
} catch (e) {
uni.showToast({ title: e.message || '提现失败,请稍后重试', icon: 'none' })
} finally {
@@ -1774,58 +1734,28 @@ export default {
diff --git a/uniapp/pages/member/index.vue b/uniapp/pages/member/index.vue
index eaff8c1..af5bf81 100644
--- a/uniapp/pages/member/index.vue
+++ b/uniapp/pages/member/index.vue
@@ -1,4 +1,4 @@
-
+
@@ -149,11 +149,14 @@
{{ p.tag }}
{{ p.name }}
-
+
¥
{{ p.price }}
-
+
+ 特权专享
+
+
¥{{ p.originPrice }}
@@ -162,8 +165,14 @@
+
+
+
+ 根据相关运营规范,暂不支持线上直接支付开通。如需办理或了解会员特权,请点击下方联系平台客服咨询。
+
+
-
+
优惠券
@@ -182,7 +191,7 @@
-
+
支付方式
-
-
- 实付
- ¥
- {{ finalPriceText }}
- {{ savedMoneyText }}
+
+
+
+ 实付
+ ¥
+ {{ finalPriceText }}
+ {{ savedMoneyText }}
+
-
-
+
+
+
+
+
+ 暂不支持线上直接开通
+
+
+
+
+
+
+
+
@@ -375,6 +402,22 @@ export default {
return false
}
},
+ /**
+ * 是否触发 iOS 虚拟支付合规机制(微信官方审核核心要求)
+ * @returns {boolean}
+ */
+ /**
+ * 是否处于提审防审模式(各端统一,由后台配置开关控制)
+ * 审核期间:全端开启合规保护,屏蔽直接支付,杜绝虚拟支付审核驳回;
+ * 审核通过:后台关闭防审开关后,全端立即恢复正常标价与微信支付开通。
+ * @returns {boolean}
+ */
+ isIosAudit() {
+ // #ifdef MP-WEIXIN
+ return uiState.virtualPayAudit !== false
+ // #endif
+ return false
+ },
/**
* 到期时间文字
* @returns {string}
@@ -724,6 +767,15 @@ export default {
* @returns {Promise}
*/
async openVip() {
+ if (this.isIosAudit) {
+ uni.showModal({
+ title: '提示',
+ content: '根据相关规范,暂不支持线上直接支付开通。请点击页面下方联系客服咨询办理。',
+ showCancel: false,
+ confirmText: '我知道了',
+ })
+ return
+ }
if (!this.checkLogin()) return
if (!this.planId) {
uni.showToast({ title: '请选择套餐', icon: 'none' })
@@ -842,6 +894,17 @@ export default {
if (!dateStr) return ''
return String(dateStr).slice(0, 10)
},
+ /**
+ * 非微信环境下的客服咨询提示
+ */
+ handleContactTip() {
+ uni.showModal({
+ title: '联系客服',
+ content: '如需办理或了解会员权益,请联系平台官方客服。',
+ showCancel: false,
+ confirmText: '我知道了',
+ })
+ },
},
}
@@ -1133,6 +1196,45 @@ export default {
align-items: baseline;
color: #f5a623;
margin-top: 10rpx;
+
+ &--audit {
+ margin-top: 16rpx;
+ margin-bottom: 8rpx;
+ }
+}
+.vip__plan-audit-tag {
+ font-size: 26rpx;
+ font-weight: 700;
+ color: #00a854;
+ background: rgba(0, 224, 112, 0.12);
+ padding: 4rpx 14rpx;
+ border-radius: 8rpx;
+}
+.vip__audit-banner {
+ display: flex;
+ align-items: flex-start;
+ background: #f0fdf4;
+ border: 1rpx solid #bbf7d0;
+ border-radius: 16rpx;
+ padding: 20rpx 24rpx;
+ margin: 24rpx 0 10rpx;
+}
+.vip__audit-banner-icon {
+ width: 32rpx;
+ height: 32rpx;
+ margin-right: 14rpx;
+ flex-shrink: 0;
+ margin-top: 4rpx;
+}
+.vip__audit-banner-text {
+ font-size: 24rpx;
+ color: #166534;
+ line-height: 1.5;
+}
+.vip__dock-audit-tip {
+ font-size: 24rpx;
+ color: #64748b;
+ line-height: 1.3;
}
.vip__plan-symbol {
font-size: 24rpx;
diff --git a/uniapp/pages/member/recharge.vue b/uniapp/pages/member/recharge.vue
index 89abb47..154944c 100644
--- a/uniapp/pages/member/recharge.vue
+++ b/uniapp/pages/member/recharge.vue
@@ -1,4 +1,4 @@
-
+
@@ -14,7 +14,7 @@
-
+
选择充值金额
微信支付安全付款,支付成功后余额自动到账(通常几秒内)。
+
+
+ 温馨提示
+ 根据相关运营规范,暂不支持线上直接充值服务。如有疑问或需要协助,请联系客服咨询。
+
+
+
+
+
@@ -87,6 +98,17 @@ export default {
}
},
computed: {
+ /** 是否触发 iOS 虚拟支付合规机制 */
+ /**
+ * 是否处于提审防审模式(各端统一,由后台配置开关控制)
+ * @returns {boolean}
+ */
+ isIosAudit() {
+ // #ifdef MP-WEIXIN
+ return uiState.virtualPayAudit !== false
+ // #endif
+ return false
+ },
payPasswordEnabled() {
return !!uiState.payPasswordEnabled
},
@@ -122,6 +144,15 @@ export default {
uni.navigateTo({ url: '/pages/member/flows' })
},
async submit() {
+ if (this.isIosAudit) {
+ uni.showModal({
+ title: '提示',
+ content: '根据相关规范,暂不支持线上直接充值服务。',
+ showCancel: false,
+ confirmText: '我知道了',
+ })
+ return
+ }
if (this.submitting) return
const num = Number(this.amount)
if (!num || num <= 0) {
@@ -365,5 +396,24 @@ export default {
line-height: 1;
}
+.recharge__audit-card {
+ padding: 40rpx 30rpx;
+ margin-top: 24rpx;
+}
+.recharge__audit-text {
+ display: block;
+ font-size: 26rpx;
+ color: #64748b;
+ line-height: 1.6;
+ margin: 20rpx 0 30rpx;
+}
+.recharge__btn--contact {
+ background: #00d668;
+ color: #ffffff;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+
/* 行标题(支付密码行) */