fix: 修正RJ目录显示前缀
This commit is contained in:
@@ -627,7 +627,7 @@ class AutoScheduler:
|
||||
}
|
||||
combined.update(
|
||||
{
|
||||
f"rj:{name}": item.to_dict()
|
||||
name: item.to_dict()
|
||||
for name, item in rj_status.items()
|
||||
}
|
||||
)
|
||||
|
||||
@@ -606,3 +606,9 @@
|
||||
- `frontend/src/components/HistoryPanel.vue` keeps the processing log at the bottom of the task detail modal, and adds a `详情 / 文件` tab area above it. The file tab shows breadcrumb navigation, parent/refresh controls, directory/file type, size, modified time, and per-item download actions.
|
||||
- `frontend/src/types.ts` defines `HistoryFileEntry` and `HistoryFilesResponse`; `app/main.py` adds Chinese OpenAPI descriptions and examples for the new history file APIs.
|
||||
- Verification performed: `.venv\Scripts\python.exe -m compileall app`, `npm run build`, direct history file listing for `20260519_172434`, path traversal rejection, and single-file download of `log.txt` on a temporary local server all passed. Build output and Python caches were removed after verification.
|
||||
|
||||
## 2026-06-01: RJ scheduler display cleanup
|
||||
|
||||
- `app/services/auto_scheduler.py` now keeps RJ directory status keys clean instead of prefixing them with `rj:` in the combined scheduler response.
|
||||
- `frontend/src/components/SettingsPanel.vue` strips any legacy `rj:` prefix before rendering the scheduler directory name, so the UI shows `RJ/2.6G/...` instead of `rj:RJ/2.6G/...`.
|
||||
- This is display-only cleanup; the underlying RJ directory detection and readiness logic were not changed.
|
||||
|
||||
@@ -229,7 +229,7 @@
|
||||
<p class="form-hint">{{ schedulerStatus?.last_message || '自动调度状态尚未加载' }}</p>
|
||||
<div v-if="schedulerDirectoryRows.length > 0" class="scheduler-directory-list">
|
||||
<div v-for="row in schedulerDirectoryRows" :key="row.name" class="scheduler-directory-row">
|
||||
<span class="scheduler-directory-name">{{ row.name }}</span>
|
||||
<span class="scheduler-directory-name">{{ row.displayName }}</span>
|
||||
<n-tag size="small" :type="row.skipped ? 'info' : row.ready ? 'success' : 'warning'">
|
||||
{{ row.skipped ? '已停推' : row.ready ? '就绪' : `缺 ${row.missing_days.length} 天` }}
|
||||
</n-tag>
|
||||
@@ -560,6 +560,7 @@ const schedulerDirectoryRows = computed(() => {
|
||||
const directoryStatus = schedulerStatus.value?.directory_status || {};
|
||||
return Object.entries(directoryStatus).map(([name, status]) => ({
|
||||
name,
|
||||
displayName: name.replace(/^rj:/i, ''),
|
||||
...status
|
||||
}));
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user