fix: expose affiliate promotion center
This commit is contained in:
@@ -218,8 +218,11 @@ $hmb_js = get_template_directory() . '/assets/js/header-newadd.js';
|
||||
$balance_on = is_user_logged_in()
|
||||
&& class_exists('\AKSRT\Credits\Balance')
|
||||
&& \AKSRT\Credits\Balance::enabled();
|
||||
$affiliate_on = is_user_logged_in()
|
||||
&& class_exists('\\AKSRT\\Settings\\Settings')
|
||||
&& !empty(\AKSRT\Settings\Settings::get_affiliate_settings()['enabled']);
|
||||
$vip_coordinator = get_template_directory() . '/assets/js/vip-purchase-coordinator.js';
|
||||
if (($vip_on || $credits_on) && file_exists($vip_coordinator)) {
|
||||
if (($vip_on || $credits_on || $affiliate_on) && file_exists($vip_coordinator)) {
|
||||
wp_enqueue_script(
|
||||
'aksrt-vip-coordinator',
|
||||
$base_uri . '/assets/js/vip-purchase-coordinator.js',
|
||||
@@ -821,7 +824,7 @@ $hmb_js = get_template_directory() . '/assets/js/header-newadd.js';
|
||||
}
|
||||
|
||||
// 积分相关:已登录 + 启用积分功能时全站加载
|
||||
if ($credits_on || $balance_on) {
|
||||
if ($credits_on || $balance_on || $affiliate_on) {
|
||||
$enqueue_module('credits');
|
||||
|
||||
// profile 页:加载 credits.js(签到 + 邀请 + 提现交互)
|
||||
|
||||
Reference in New Issue
Block a user