@@ -963,7 +963,7 @@
// 渲染 runtime 狀態
function renderPods(pods, envId) {
if (!pods || pods.length === 0) {
- return '
Docker Compose 執行環境;舊叢集資訊不適用
';
+ return '
Docker Compose 執行環境;外部叢集資訊不適用
';
}
return pods.map(pod => `
@@ -1098,7 +1098,7 @@
}
}
- // 完整修復
+ // 部署修復
async function triggerFullRepair() {
const env = prompt('請輸入要修復的環境 (uat 或 prod):', 'uat');
if (!env || !['uat', 'prod'].includes(env)) {
@@ -1106,9 +1106,9 @@
return;
}
- if (!confirm(`確定要對 ${env.toUpperCase()} 執行完整修復嗎?\n這會重啟 Registry 並執行執行環境診斷,不會重啟舊叢集。`)) return;
+ if (!confirm(`確定要對 ${env.toUpperCase()} 執行部署修復嗎?\n這會執行必要服務修復與環境診斷。`)) return;
- showNotification('執行中', '正在執行完整修復...');
+ showNotification('執行中', '正在修復部署狀態...');
try {
const response = await fetch('/api/cicd/auto-fix', {
@@ -1120,13 +1120,13 @@
const data = await response.json();
if (data.success) {
- showNotification('✅ 完整修復完成', `已執行 ${data.results?.length || 0} 個修復動作`);
+ showNotification('✅ 部署修復完成', `已執行 ${data.results?.length || 0} 個修復動作`);
setTimeout(loadDashboard, 5000);
} else {
showNotification('❌ 修復失敗', data.error, true);
}
} catch (error) {
- showNotification('❌ 錯誤', '無法執行完整修復: ' + error, true);
+ showNotification('❌ 錯誤', '無法執行部署修復: ' + error, true);
}
}
diff --git a/templates/daily_sales.html b/templates/daily_sales.html
index 362010f..e392f6f 100644
--- a/templates/daily_sales.html
+++ b/templates/daily_sales.html
@@ -305,7 +305,7 @@
- 左右滑動查看完整圖表
+ 左右滑動看業績趨勢
@@ -499,7 +499,7 @@
- 左右滑動查看完整列表
+ 左右滑動看分類明細
diff --git a/templates/dashboard_v2.html b/templates/dashboard_v2.html
index 5fa32b4..f10509d 100644
--- a/templates/dashboard_v2.html
+++ b/templates/dashboard_v2.html
@@ -354,8 +354,8 @@
{% endfor %}
{% else %}
- 尚無 AI 挑品
- 請先讓 PChome 比對與挑品 Agent 累積資料
+ 尚無挑品建議
+ 先累積 PChome 比價與挑品資料
{% endif %}
diff --git a/templates/sales_analysis.html b/templates/sales_analysis.html
index 10ee92a..48e705d 100644
--- a/templates/sales_analysis.html
+++ b/templates/sales_analysis.html
@@ -390,14 +390,14 @@
自訂日期區間
-
精確指定開始/結束日期進行分析
-
+
鎖定活動或檔期,評估業績變化
+
- 提示:選擇條件後,直接看影響業績的圖表、分類與商品明細。
+ 分析下一步:選擇條件後,直接看影響業績的圖表、分類與商品明細。
@@ -437,7 +437,7 @@
ABC 分析 (80/20 法則)
- 點擊類別查看詳情
+ 選類別看貢獻
{% set abc_classes = [
@@ -565,7 +565,7 @@
| {{ loop.index }} |
-
+
{{ v.name }}
diff --git a/templates/vendor_stockout_import_v2.html b/templates/vendor_stockout_import_v2.html
index 9efe858..3fe2d73 100644
--- a/templates/vendor_stockout_import_v2.html
+++ b/templates/vendor_stockout_import_v2.html
@@ -56,7 +56,7 @@
必要欄位
來源供應商編號、來源供應商名稱、商品ID、商品名稱
- 缺少必要欄位時,API 會拒絕匯入並回傳錯誤原因。
+ 缺少必要欄位時,系統會拒絕匯入並回傳錯誤原因。
欄位範本
@@ -113,7 +113,7 @@
批次編號
- 查看缺貨清單
+ 處理缺貨清單
{% else %}
尚無匯入紀錄
- 資料庫目前沒有缺貨資料
+ 先匯入缺貨批次,確認主推商品供貨風險
{% endif %}
diff --git a/templates/vendor_stockout_vendor_management_v2.html b/templates/vendor_stockout_vendor_management_v2.html
index 2358f28..cd9a8f8 100644
--- a/templates/vendor_stockout_vendor_management_v2.html
+++ b/templates/vendor_stockout_vendor_management_v2.html
@@ -142,8 +142,8 @@
- 拖曳檔案到此處或點擊選擇檔案
- 支援格式: Excel (.xlsx, .xls)
+ 匯入供應商窗口名單
+ 上傳 Excel,讓缺貨通知送到正確窗口。
必要欄位:來源供應商編號、來源供應商名稱
選填欄位:Mail(支援多個郵件用逗號或分號分隔)
@@ -229,7 +229,7 @@
再次匯入
diff --git a/tests/test_pchome_revenue_growth_service.py b/tests/test_pchome_revenue_growth_service.py
index 37e6008..b6e6e82 100644
--- a/tests/test_pchome_revenue_growth_service.py
+++ b/tests/test_pchome_revenue_growth_service.py
@@ -821,3 +821,43 @@ def test_governance_and_low_frequency_pages_avoid_engineering_status_copy():
assert "已整併" in text
for bad in forbidden:
assert bad not in text
+
+
+def test_visible_operations_pages_hide_internal_runtime_terms():
+ from pathlib import Path
+
+ expected = {
+ "templates/ai_recommend.html": ["分析模型", "用量"],
+ "templates/vendor_stockout_index_v2.html": ["先匯入缺貨批次", "供貨風險"],
+ "templates/dashboard_v2.html": ["尚無挑品建議", "先累積 PChome 比價與挑品資料"],
+ "templates/daily_sales.html": ["左右滑動看業績趨勢", "左右滑動看分類明細"],
+ "templates/sales_analysis.html": ["分析下一步", "選類別看貢獻", "適合檔期與活動回顧"],
+ "templates/vendor_stockout_vendor_management_v2.html": ["匯入供應商窗口名單", "確認窗口清單"],
+ "templates/vendor_stockout_import_v2.html": ["系統會拒絕匯入", "處理缺貨清單"],
+ "templates/admin/ppt_audit_history.html": ["產出紀錄", "最近產出", "保存紀錄"],
+ "templates/admin/agent_orchestration.html": ["AI 分工指揮台", "模型、工具與知識命中矩陣", "工具服務明細"],
+ "templates/admin/ai_calls_dashboard.html": ["用量", "AI 上下文", "知識與工具編排矩陣"],
+ "templates/admin/observability_overview.html": ["用量", "知識與工具矩陣"],
+ "templates/cicd_dashboard.html": ["部署流程", "部署歷史", "修復部署", "查看部署紀錄"],
+ }
+ forbidden_by_path = {
+ "templates/ai_recommend.html": ["權杖:", "AI 模型"],
+ "templates/vendor_stockout_index_v2.html": ["資料庫目前沒有缺貨資料"],
+ "templates/dashboard_v2.html": ["尚無 AI 挑品", "挑品 Agent"],
+ "templates/daily_sales.html": ["左右滑動查看完整圖表", "左右滑動查看完整列表"],
+ "templates/sales_analysis.html": ["提示:選擇條件", "點擊類別查看詳情", "點擊篩選此廠商商品"],
+ "templates/vendor_stockout_vendor_management_v2.html": ["拖曳檔案到此處或點擊選擇檔案", "查看廠商清單"],
+ "templates/vendor_stockout_import_v2.html": ["API 會拒絕匯入", "查看缺貨清單"],
+ "templates/admin/ppt_audit_history.html": ["DB 紀錄", "DB / 預覽", "寫入 DB", "DB 產出紀錄", "資料庫快取", "本月尚無 DB"],
+ "templates/admin/agent_orchestration.html": ["Agent 指揮矩陣", "四 Agent 矩陣", "LLM × MCP × RAG 編排矩陣", "權杖"],
+ "templates/admin/ai_calls_dashboard.html": ["權杖量", "權杖/次", ">權杖<", "Agent 上下文", "RAG × MCP"],
+ "templates/admin/observability_overview.html": ["權杖量", "RAG × MCP"],
+ "templates/cicd_dashboard.html": ["Pipeline Flow", "Pipeline History", "完整修復", "一鍵修復", "重啟 Registry", "舊叢集"],
+ }
+
+ for path, markers in expected.items():
+ text = Path(path).read_text(encoding="utf-8")
+ for marker in markers:
+ assert marker in text
+ for bad in forbidden_by_path.get(path, []):
+ assert bad not in text
|