diff --git a/assets/css/routes/user-center/revenue-earnings.css b/assets/css/routes/user-center/revenue-earnings.css index c33d142d..8e211085 100644 --- a/assets/css/routes/user-center/revenue-earnings.css +++ b/assets/css/routes/user-center/revenue-earnings.css @@ -110,13 +110,6 @@ gap: 4px 16px; } -/* 待偿欠款:退款收回不足挂账,副信息里以描边标签弱提示。 */ -.uc-content .uc-commission-card__debt { - padding: 0 8px; - border-radius: 999px; - background: rgba(255, 255, 255, .22); -} - /* 立即提现按钮:贴右居中,对齐参考主题 .abs-right。 */ .uc-content .uc-commission-card__action { position: absolute; diff --git a/inc/helpers/user-center-renderers/profile-revenue.php b/inc/helpers/user-center-renderers/profile-revenue.php index bc39d3f1..ae7638dc 100644 --- a/inc/helpers/user-center-renderers/profile-revenue.php +++ b/inc/helpers/user-center-renderers/profile-revenue.php @@ -121,7 +121,6 @@ $status_labels = [ $pool_amount = $format_amount($commission_stats['pool'] ?? 0); $total_amount = $format_amount($commission_stats['total'] ?? 0); $withdrawn_amount = $format_amount($commission_stats['withdrawn'] ?? 0); -$debt_amount = $format_amount($commission_stats['debt'] ?? 0); $reward_panes = ['detail']; if ($affiliate_on) { $reward_panes[] = 'orders'; @@ -148,7 +147,6 @@ $pane_is_active = static function (string $tab) use ($active_reward_tab): bool {

-

@@ -178,7 +176,7 @@ $pane_is_active = static function (string $tab) use ($active_reward_tab): bool {
%
-
+
diff --git a/tests/widget-system/referral-qr-contract.test.cjs b/tests/widget-system/referral-qr-contract.test.cjs index ab15eaf8..f83a4085 100644 --- a/tests/widget-system/referral-qr-contract.test.cjs +++ b/tests/widget-system/referral-qr-contract.test.cjs @@ -22,6 +22,17 @@ test('QR generator is bundled locally; no external QR CDN in front-end sources', test('revenue detail card is a four-row info list with no standalone QR block', () => { const template = read('inc', 'helpers', 'user-center-renderers', 'profile-revenue.php') + // 待偿欠款不在 UI 暴露:欠款机制(挂账/偿还)照常运行,只是不渲染。 + // 参考主题的佣金卡片也没有这个概念,故不作为平价目标。 + assert.doesNotMatch(template, /待偿欠款/) + assert.doesNotMatch(template, /uc-commission-card__debt/) + assert.doesNotMatch(template, /\$debt_amount/) + const css = read('assets', 'css', 'routes', 'user-center', 'revenue-earnings.css') + assert.doesNotMatch(css, /uc-commission-card__debt/) + // overview() 仍返回 debt(偿还逻辑依赖),fallback 形状必须与之一致。 + assert.match(template, /'debt' => 0/) + const ledger = read('src', 'Payment', 'CommissionLedger.php') + assert.match(ledger, /'debt'\s*=>/) // 二维码不再作为独立行:整行 markup 已删除。 assert.doesNotMatch(template, /data-affiliate-qr-row/) assert.doesNotMatch(template, /data-affiliate-qr(?!-)/)