mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-11-19 11:34:59 +03:00
feat(nodes): bulk panel self-update with live online indicator
Adds the ability to update node panels to the latest release from the Nodes page: select online, enabled nodes (checkboxes) and trigger their official self-updater, or use the per-row Update action. A node whose reported panel version trails the latest GitHub release is flagged with an 'update available' tag (compared via lib/panel-version, mirroring the Go isNewerVersion). Backend: Remote.UpdatePanel calls the node's existing POST /panel/api/server/updatePanel; NodeService.UpdatePanels fans out over the selected ids, skipping disabled/offline nodes with a per-node reason; exposed as POST /panel/api/nodes/updatePanel (documented in endpoints.ts + openapi.json). The bulk request sends a JSON body, so it sets Content-Type: application/json explicitly — axios defaults POST to form-urlencoded, which made ShouldBindJSON fail with 'invalid character i'. Also reuses the clients-page online cue on the Nodes page: a pulsing green dot plus green label for an online node. The .online-dot style moved to the shared styles/utils.css so both pages load it. Translations for all new node keys added across every language file.
This commit is contained in:
@@ -832,6 +832,12 @@
|
||||
"panelVersion": "面板版本",
|
||||
"actions": "操作",
|
||||
"probe": "立即探測",
|
||||
"updatePanel": "更新面板",
|
||||
"updateSelected": "更新所選 ({count})",
|
||||
"updateAvailable": "有可用更新",
|
||||
"upToDate": "已是最新",
|
||||
"updateConfirmTitle": "將 {count} 個節點更新到最新版本?",
|
||||
"updateConfirmContent": "每個所選節點會下載最新版本並重新啟動。僅更新已啟用且在線的節點。",
|
||||
"testConnection": "測試連線",
|
||||
"connectionOk": "連線正常 ({ms} ms)",
|
||||
"connectionFailed": "連線失敗",
|
||||
@@ -853,7 +859,10 @@
|
||||
"deleted": "節點已刪除",
|
||||
"test": "測試連線",
|
||||
"fillRequired": "名稱、位址、埠與 API 權杖為必填",
|
||||
"probeFailed": "探測失敗"
|
||||
"probeFailed": "探測失敗",
|
||||
"updateStarted": "已開始更新面板",
|
||||
"updateResult": "已在 {ok} 個節點上觸發更新,{failed} 個失敗",
|
||||
"updateNoneEligible": "請至少選擇一個在線且已啟用的節點"
|
||||
}
|
||||
},
|
||||
"settings": {
|
||||
|
||||
Reference in New Issue
Block a user