补齐SSH引导私钥名称联动

补充内嵌SSH引导默认私钥名称的联动逻辑,并保留用户手工指定名称不被覆盖的行为。测试顺序将在后续检查点中对齐真实页面流程。
This commit is contained in:
xuans committed 2026-09-26 13:42:23 +08:00
1 parent 661e074926
commit 121be43b1b
2 files changed
+14

No files matched your search

@@ -316,6 +316,13 @@ export function useDashboard() {
() => String(serverForm.value.address || "").trim() || "服务器地址",
);
watch(sshKeyFileName, (fileName, previousFileName) => {
if (!showEmbeddedSSHKeyGuide.value) return;
const currentName = String(sshKeyForm.value.name || "").trim();
if (!currentName || currentName === previousFileName) {
sshKeyForm.value.name = fileName;
}
});
async function fetchAdmin(path, options = {}) {
const response = await fetch(path, {
...options,