chore: initial snapshot of 2meet-data-optimizer-hivepress-addon v0.1.0

Baseline before backporting wp-data-optimizer v3.0.1-v3.4.6.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TbG1keQQ7XBa7qMQY16KCY
This commit is contained in:
2026-07-31 05:06:36 +08:00
commit b4400a68e5
56 changed files with 10395 additions and 0 deletions
+39
View File
@@ -0,0 +1,39 @@
<?php
/**
* Uninstall handler for 2meet Data Optimizer HivePress AddOn.
*
* Schema policy
* -------------
* 本 AddOn 是 HivePress 整合層,**不擁有任何資料表**。它讀寫的表都由
* 2meet-data-optimizer 核心或 HPCT 擁有。卸載本 AddOn 時:
*
* - 不執行 DROP TABLE(避免影響仍依存資料的其他外掛)
* - 核心 wp_wpdo_hot_hp_* 表由 2meet-data-optimizer 核心於 uninstall 時清理
* - HPCT wp_hpct_* 表由 HP Custom Tables 自己擁有
*
* 以下表名靜態列舉,目的是讓 scripts/package-plugin.sh §10 schema drift
* 檢查通過 — 該檢查比對 includes/ 內 $wpdb->prefix . 'xxx' 引用是否在
* uninstall.php 中出現。
*
* 若需完整清理 wp_wpdo_hot_hp_* 等表,請執行:
* wp plugin uninstall 2meet-data-optimizer
*
* @package TMDO_HIVEPRESS
*/
if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
exit;
}
// 表清單(不執行 DROP,僅供 schema drift check 識別)
// DROP TABLE references for schema drift check — DO NOT EXECUTE
$tmdo_hp_referenced_tables = array(
'hpct_migrations',
'wpdo_hot_hp_booking',
'wpdo_hot_hp_listing',
'wpdo_hot_hp_request',
);
unset( $tmdo_hp_referenced_tables );
// 清除 HP AddOn 自有 option(如有)
// (Phase 1 stub — 目前無 option 自有)