Commit Graph

7 Commits

Author SHA1 Message Date
wpdev 421a8bc777 docs: CHANGELOG 記錄 3 個 WC runtime 欄位與 integration 測試套件
Tests / PHP Lint (push) Successful in 4s
Tests / Unit Tests (push) Successful in 16s
Tests / Integration Tests (push) Successful in 20s
2026-07-31 10:43:50 +08:00
wpdev 0118fc3a1a feat(fields): 補 3 個 WC runtime usermeta 欄位
Tests / Integration Tests (push) Successful in 1m7s
Tests / Unit Tests (push) Failing after 14m20s
Tests / PHP Lint (push) Failing after 14m28s
wc_last_active / wc_order_count_<prefix> / last_update 先前未註冊,會落回
wp_usermeta。三者皆由 WooCommerce 在 order/session 事件寫入,繁忙商店為高頻。

wc_order_count 走 Users::update_site_user_meta(),key 是
'wc_order_count' . '_' . rtrim( get_blog_prefix(), '_' );來源外掛寫死主站
形式 'wc_order_count_wp',multisite 子站(_wp_2)會漏接,這裡改用同一條運算式。
2026-07-31 10:18:33 +08:00
wpdev b9e24814c8 test: 加入 integration 測試套件(連真實 MariaDB)
Tests / PHP Lint (push) Successful in 4s
Tests / Unit Tests (push) Successful in 16s
Tests / Integration Tests (push) Successful in 18s
從 wp-data-optimizer v3.4.6 移植 1 個 integration 測試檔,並新增
tests/integration/bootstrap.php(複用核心的 integration bootstrap,不重複
 與 WP stub)+ phpunit-integration.xml + CI integration job。
2026-07-31 09:56:48 +08:00
wpdev abe738e900 test,ci: 建立 phpunit 基建 + 移植 WC 測試 + CI workflow
Tests / PHP Lint (push) Successful in 5s
Tests / Unit Tests (push) Successful in 17s
- composer.json / phpunit.xml / tests/bootstrap.php(比照 HP AddOn,
  直接 require 核心 plugin 的 unit bootstrap)
- tests/unit/WooCommerceIntegrationTest.php(自 A 移植,10 tests)
- .gitea/workflows/test.yml:lint + unit(unit job 會一併 checkout 核心 plugin,
  因為測試 bootstrap 依賴它)

10 tests / 33 assertions GREEN

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TbG1keQQ7XBa7qMQY16KCY
2026-07-31 09:20:07 +08:00
wpdev 2f9ed57390 chore(wc): 同步 A v3.4.6 的 WooCommerce 整合 + TablePrefix header(F4/F5)
4 個整合檔(woocommerce / wc-orders-interceptor / wc-term-count-filter /
admin-wc)對齊 A v3.4.6;主檔補 TablePrefix header。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TbG1keQQ7XBa7qMQY16KCY
2026-07-31 06:07:39 +08:00
wpdev 955689ddd2 feat(back-compat): 加入 WPDO_* class alias(E3)
核心的 class-tmdo-back-compat.php 在 plugins_loaded:4 執行,AddOn 於 :6
才載入,所以核心的 alias 表涵蓋不到 AddOn 類別 —— 姊妹外掛或第三方若
以 WPDO_* 名稱引用本 AddOn 的類別會直接 fatal。

新增 includes/back-compat-aliases.php,於 plugins_loaded:7 為本 AddOn
自有類別建立 WPDO_ alias;主檔加入 require。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TbG1keQQ7XBa7qMQY16KCY
2026-07-31 06:03:47 +08:00
wpdev 47288db826 chore: initial snapshot of 2meet-data-optimizer-woocommerce-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
2026-07-31 05:06:36 +08:00