feat: unify referral promotion tabs and compact earnings UI

This commit is contained in:
2026-08-16 20:40:21 +08:00
parent 8799063c6c
commit ff730ab593
7 changed files with 144 additions and 52 deletions
+2 -2
View File
@@ -74,10 +74,10 @@ class Invite {
],
]);
}
/** Capture ?ref=XYZ, with legacy ?invite=XYZ support. */
/** Capture the unified ?ref=XYZ referral parameter. */
public function capture_invite_cookie(): void {
if (is_admin()) return;
$raw_code = $_GET['ref'] ?? $_GET['invite'] ?? '';
$raw_code = $_GET['ref'] ?? '';
if ($raw_code === '') return;
// 邀请注册功能关闭时不处理
if (class_exists('\AKSRT\Settings\Settings') && !\AKSRT\Settings\Settings::invite_registration_enabled()) return;