quote_feedback_comments

狀態:PHP 8 本地實作與測試完成,Staging 尚未驗證。
最後更新:2026-07-31

API狀態文件
POST /quote_feedback_comments/save/{feedback_id}.jsonPHP 8 本地完成save.md
GET/POST /quote_feedback_comments/delete/id:{comment_id}.jsonPHP 8 本地完成delete.md

共用重點:兩支 PHP 8 API 都要求 URL 以 .json 結尾,並要求有效 API key 與使用者 session;session cache、blocked-user、access update、returned-service queue 及 endpoint request log 必須先對齊 Legacy,不能直接套用 PHP 8 共用 session validator。

Migration decision(2026-07-31,reviewer 已接受):不搬 Legacy 透過 Accept header 接受無 .json URL 的行為。已確認 Web caller 使用 .json;無副檔名請求即使帶 Accept: application/json 也回 invalid request。

Production 最近 30 天:save 751 calls;delete 10 calls。全部仍走 Legacy。

2026-07-31 在 Legacy host ip-10-5-2-19 掃描全部保留的 get-lancer_access.log*:查詢有命中實際 savedelete 流量,非 .json 為 0 筆。這是單機 retained-log 證據;其他 Legacy instances 或 ALB logs 尚待確認。

本地驗證:專用測試中的全域 core3 tests / 36 assertions;排除 core 的 other 為 16 tests / 97 assertions,合計 19 / 133quote_feedbacks/sent regression 10 / 76quote_feedback_tags/index regression 12 / 68,PHP 8.2 syntax 全部通過。

測試範圍指令
Corevendor/bin/phpunit --group core
Othervendor/bin/phpunit --exclude-group core
全部vendor/bin/phpunit

這是全專案規則:只有關鍵測試標 core,未標記的測試全部屬於 other。此 API 的 core 只保留有效新增、owner 更新與 ownership guard、GET/POST owner hard delete;其他輸入邊界、驗證、cache、log 與 route negative 沒有刪除。

待確認:其他 Production instances/ALB 的非 .json 流量、Staging DB/Redis 共享狀態,以及 Router generic log/client_usage_users 額外 side effect與 Legacy CORS Origin warning log缺失的 migration decision。