MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / updateAutoQuickRefreshButton

Function updateAutoQuickRefreshButton

static/js/accounts.js:480–498  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

478}
479
480function updateAutoQuickRefreshButton() {
481 const btn = elements.autoQuickRefreshSettingsBtn;
482 if (!btn) return;
483 const enabled = Boolean(autoQuickRefreshSettings?.enabled);
484 const interval = Number(autoQuickRefreshSettings?.interval_minutes || 0);
485 const runtime = autoQuickRefreshSettings?.runtime || {};
486 if (runtime.running) {
487 btn.textContent = '⚙️ 运行中';
488 btn.title = '定时自动一键刷新正在执行';
489 return;
490 }
491 if (enabled && interval > 0) {
492 btn.textContent = `⚙️ 定时(${interval}m)`;
493 btn.title = `定时自动一键刷新已启用,每 ${interval} 分钟执行`;
494 return;
495 }
496 btn.textContent = '⚙️ 定时';
497 btn.title = '定时自动一键刷新设置';
498}
499
500function fillAutoQuickRefreshForm(options = {}) {
501 if (!autoQuickRefreshSettings) return;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected