refactor(autoload): migrate theme classes to Composer PSR-4
Move 288 types from global AKSRT_* + inc/classes manual requires into
namespace AKSRT\{Domain} under src/AKSRT/, wire composer.json psr-4,
and slim bootstrap to helpers/modules/hooks only. Split multi-class
widget/gateway files, update admin contract audit paths, and document
the layout in ADR/README.
This commit is contained in:
1 parent
8f349b40fb
commit
aaf458af1c
404 files changed
+13602
-7705
No files matched your search
@@ -56,7 +56,7 @@ $need_vip = $gate_code === 'aksrt_need_vip';
|
||||
$priced = function_exists('aksrt_get_user_pay_price') ? aksrt_get_user_pay_price($post) : null;
|
||||
$price = is_array($priced) ? (float) ($priced['amount'] ?? 0) : (float) ($pay_meta['price'] ?? 0);
|
||||
$pay_modo = is_array($priced) ? ((($priced['modo'] ?? '0') === 'points') ? 'points' : '0') : ((($pay_meta['pay_modo'] ?? '0') === 'points') ? 'points' : '0');
|
||||
$order_settings = class_exists('AKSRT_Settings') ? AKSRT_Settings::get_order_settings() : [];
|
||||
$order_settings = class_exists('\AKSRT\Settings\Settings') ? \AKSRT\Settings\Settings::get_order_settings() : [];
|
||||
$free_logged_show = !empty($order_settings['free_logged_show']);
|
||||
if ($price <= 0 && $free_logged_show && !is_user_logged_in()) {
|
||||
$can_dl = false;
|
||||
@@ -64,10 +64,10 @@ if ($price <= 0 && $free_logged_show && !is_user_logged_in()) {
|
||||
$has_access = true; // free "access" but must login to download
|
||||
}
|
||||
|
||||
$currency = class_exists('AKSRT_Settings') ? AKSRT_Settings::get_currency_name() : __('积分', 'aksrt');
|
||||
$currency = class_exists('\AKSRT\Settings\Settings') ? \AKSRT\Settings\Settings::get_currency_name() : __('积分', 'aksrt');
|
||||
$cash_symbol = '¥';
|
||||
if (class_exists('AKSRT_Settings')) {
|
||||
$paid_display = AKSRT_Settings::get_paid_content_settings();
|
||||
if (class_exists('\AKSRT\Settings\Settings')) {
|
||||
$paid_display = \AKSRT\Settings\Settings::get_paid_content_settings();
|
||||
$cash_symbol = (string) ($paid_display['display']['currency_symbol'] ?? '¥');
|
||||
}
|
||||
$price_text = $price <= 0
|
||||
|
||||
Reference in new issue
Block a user