fix: rename crawler UI to product monitoring
All checks were successful
CD Pipeline / deploy (push) Successful in 1m9s

This commit is contained in:
ogt
2026-06-26 18:08:14 +08:00
parent cb14c74b88
commit d2d798933a
15 changed files with 63 additions and 44 deletions

View File

@@ -255,7 +255,7 @@ let priceChartInstance = null;
const dashboardTaskMap = {
crawler: {
confirmText: '確定要手動執行全站爬蟲嗎?可能需要一段時間。',
confirmText: '確定要手動執行全站商品監控嗎?可能需要一段時間。',
url: '/api/run_task'
},
notification: {

View File

@@ -21,7 +21,7 @@ function getCSRFToken() {
}
function triggerTask() {
if (confirm('確定要手動執行全站爬蟲嗎?(可能需要一段時間)')) {
if (confirm('確定要手動執行全站商品監控嗎?(可能需要一段時間)')) {
fetch('/api/run_task', { method: 'POST', headers: { 'X-CSRFToken': getCSRFToken() } })
.then(r => r.json()).then(d => alert(d.message)).catch(e => alert('錯誤: ' + e));
}

View File

@@ -269,11 +269,11 @@ let campaignPriceChartInstance = null;
const campaignTaskMap = {
edm: {
confirmText: '確定要手動執行 EDM 爬蟲嗎?',
confirmText: '確定要手動執行 EDM 商品監控嗎?',
url: '/api/run_edm_task'
},
festival: {
confirmText: '確定要手動執行節慶活動爬蟲嗎?',
confirmText: '確定要手動執行節慶活動監控嗎?',
url: '/api/run_festival_task'
},
notification: {

View File

@@ -1,5 +1,5 @@
/* ═══════════════════════════════════════════════════════════
* page-settings.js — 爬蟲管理中心
* page-settings.js — 商品監控中心
* 從原 settings.html L1230-L1648 抽出
* 邏輯與原版一致
* ═══════════════════════════════════════════════════════════ */
@@ -51,7 +51,7 @@ async function loadCrawlers() {
showToast('載入失敗: ' + result.message, 'error');
}
} catch (e) {
showToast('載入爬蟲配置時發生錯誤', 'error');
showToast('載入商品監控設定時發生錯誤', 'error');
console.error(e);
}
}
@@ -174,7 +174,7 @@ async function refreshData() {
setTimeout(() => {
btn.classList.remove('spinning');
btn.disabled = false;
showToast('已刷新爬蟲狀態', 'success');
showToast('已刷新商品監控狀態', 'success');
}, 600);
}