refactor: rename the theme brand and every identifier from AKSRT to Jio

Full-project rename. `git grep -i aksrt` is now empty apart from the
DBMigrator 3.3.0 changelog note that documents the rename itself.

Code identifiers
- PHP namespace AKSRT\ -> Jio\ (composer PSR-4 + 378 declarations)
- global constants AKSRT_* -> JIO_* (VERSION/DIR/URI, PAY_TYPE_*, CAPTCHA_*)
- procedural functions, hooks, options, meta keys, table names,
  cookies, query vars, ajax actions and nonces: aksrt_ -> jio_
- text domain aksrt -> jio; Theme Name -> Jio
- JS globals: aksrtData/aksrtAdminData/... -> jioData/jioAdminData/...,
  window.AKSRTCaptcha & friends -> window.JioCaptcha, Aksrt* -> Jio*
- Vue components Aks*.vue -> Jio*.vue (15 files renamed + imports)
- CSS classes/data-attrs/custom properties: aksrt- -> jio-
- REST namespace aksrt/v1 -> jio/v1 (incl. payment gateway callbacks)

Storage layer
- DB tables {prefix}aksrt_* -> {prefix}jio_*; SCHEMA_VERSION 3.2.0 -> 3.3.0
  so dbDelta creates the new names on install
- widget id_base aksrt_widget_* -> jio_widget_*
- uninstall.php drop list rebuilt from the actual migrator tables
  (dropped 3 stale entries, added the 17 missing ones)

Removed
- hardcoded https://api.aksrt.com/version.json default update endpoint;
  get_endpoint() now reads the 「更新端点」 setting and do_check() no-ops
  when it is empty

Files renamed: inc/helpers/aksrt-*.php -> jio-*.php (54),
assets/admin/src/components/form/Aks*.vue -> Jio*.vue (15).
Build artifacts regenerated: assets/css/build, assets/js/runtime,
assets/admin/build.

Verified: audit-psr4-paths errors=0, audit-admin-contracts errors=0
(warnings=56, unchanged baseline), 813/813 widget-system tests,
44/44 phpunit, php -l clean across all PHP.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
kate522andClaude Opus 5 committed 2026-11-01 20:05:04 +08:00
1 parent 5b16bc6e15
commit 35bb96e82f
997 files changed
+28216 -28188

No files matched your search

+59 -40
View File
@@ -1,11 +1,11 @@
<?php
/**
* AKSRT Theme — Uninstall Handler
* Jio Theme — Uninstall Handler
*
* Runs when the theme is deleted via the WordPress admin.
* Optionally cleans up custom database tables and options.
*
* @package AKSRT
* @package Jio
*/
// Abort if not called by WordPress
@@ -15,7 +15,7 @@ if (!defined('WP_UNINSTALL_PLUGIN') && !defined('ABSPATH')) {
// Only run if the user has opted in to data deletion.
// Check for a specific option flag; if not set, preserve data.
$should_cleanup = get_option('aksrt_cleanup_on_uninstall', false);
$should_cleanup = get_option('jio_cleanup_on_uninstall', false);
if (!$should_cleanup) {
return;
}
@@ -23,33 +23,52 @@ if (!$should_cleanup) {
global $wpdb;
// ── Drop custom tables ──
// 与 Jio\Core\DBMigrator(DBMigratorPart2 / Identity / Vip / Ticket)创建的
// 表一一对应;新增表时同步这里。
$tables = [
'aksrt_financial_flow_entry',
'aksrt_financial_flow',
'aksrt_asset_entry',
'aksrt_asset_transaction',
'aksrt_asset_account',
'aksrt_signin_log',
'aksrt_dl_token',
'aksrt_notification',
'aksrt_report',
'aksrt_follow',
'aksrt_user_restriction',
'aksrt_product_variant',
'aksrt_order_shipping',
'aksrt_card_key',
'aksrt_revenue',
'aksrt_withdrawal',
'aksrt_charge_card',
'jio_ticket_reply',
'jio_ticket_note',
'jio_ticket_prereply',
'jio_ticket_status',
'jio_ticket_type',
'jio_ticket',
'jio_order_item',
'jio_order',
'jio_coupon_usage',
'jio_coupon',
'jio_charge_card',
'jio_invite_code_usage',
'jio_invite_code',
'jio_affiliate_relation',
'jio_commission_adjustment',
'jio_commission_debt',
'jio_commission_ledger',
'jio_payout_account',
'jio_revenue',
'jio_withdrawal',
'jio_identity_event',
'jio_identity_application',
'jio_vip_membership_event',
'jio_financial_flow_entry',
'jio_financial_flow',
'jio_asset_entry',
'jio_asset_transaction',
'jio_asset_account',
'jio_signin_log',
'jio_dl_token',
'jio_notification',
'jio_report',
'jio_follow',
'jio_user_restriction',
];
foreach ($tables as $table) {
$wpdb->query("DROP TABLE IF EXISTS {$wpdb->prefix}{$table}");
}
// ── Delete AKSRT options ──
// ── Delete Jio options ──
$options = $wpdb->get_col(
"SELECT option_name FROM {$wpdb->options} WHERE option_name LIKE 'aksrt_%'"
"SELECT option_name FROM {$wpdb->options} WHERE option_name LIKE 'jio_%'"
);
if ($options) {
foreach ($options as $option) {
@@ -57,24 +76,24 @@ if ($options) {
}
}
// ── Delete AKSRT user meta ──
// ── Delete Jio user meta ──
$meta_keys = [
'aksrt_avatar_attachment_id',
'aksrt_background_attachment_id',
'aksrt_background_image',
'jio_avatar_attachment_id',
'jio_background_attachment_id',
'jio_background_image',
'phone_number',
'aksrt_phone_verified',
'aksrt_profile_details',
'aksrt_phone',
'aksrt_email_verified',
'aksrt_unread_message_count',
'_aksrt_active_restrictions',
'_aksrt_is_banned',
'_aksrt_no_appeal',
'aksrt_user_ban_state',
'_aksrt_favorite_posts',
'aksrt_wechat_openid',
'aksrt_wechat_subscriptions',
'jio_phone_verified',
'jio_profile_details',
'jio_phone',
'jio_email_verified',
'jio_unread_message_count',
'_jio_active_restrictions',
'_jio_is_banned',
'_jio_no_appeal',
'jio_user_ban_state',
'_jio_favorite_posts',
'jio_wechat_openid',
'jio_wechat_subscriptions',
];
foreach ($meta_keys as $key) {
@@ -82,5 +101,5 @@ foreach ($meta_keys as $key) {
}
// ── Delete transients ──
$wpdb->query("DELETE FROM {$wpdb->options} WHERE option_name LIKE '_transient_aksrt_%'");
$wpdb->query("DELETE FROM {$wpdb->options} WHERE option_name LIKE '_transient_timeout_aksrt_%'");
$wpdb->query("DELETE FROM {$wpdb->options} WHERE option_name LIKE '_transient_jio_%'");
$wpdb->query("DELETE FROM {$wpdb->options} WHERE option_name LIKE '_transient_timeout_jio_%'");