diff --git a/frontend/src/stores/configStore.ts b/frontend/src/stores/configStore.ts index 6f4b1e4..cd9ea54 100644 --- a/frontend/src/stores/configStore.ts +++ b/frontend/src/stores/configStore.ts @@ -415,9 +415,10 @@ export const useConfigStore = defineStore('config', () => { // 开机启动配置相关方法 setStartAtLogin: async (value: boolean) => { await safeCall(async () => { - // 先调用系统设置 + // 先更新配置文件 + await updateGeneralConfig('startAtLogin', value); + // 再调用系统设置API await StartupService.SetEnabled(value); - state.config.general.startAtLogin = value; }, 'config.startupFailed', 'config.startupSuccess'); } }; diff --git a/frontend/src/views/settings/Settings.vue b/frontend/src/views/settings/Settings.vue index 92c67d8..7223386 100644 --- a/frontend/src/views/settings/Settings.vue +++ b/frontend/src/views/settings/Settings.vue @@ -73,7 +73,7 @@ const goBackToEditor = async () => {