mirror of
https://github.com/setube/ogame-vue-ts.git
synced 2026-05-12 16:05:12 +08:00
优化webdav相关
This commit is contained in:
@@ -334,7 +334,7 @@
|
||||
<PrivacyDialog v-model:open="showPrivacyDialog" />
|
||||
|
||||
<!-- WebDAV 配置对话框 -->
|
||||
<WebDAVConfigDialog v-model:open="showWebDAVConfig" @saved="onWebDAVConfigSaved" />
|
||||
<WebDAVConfigDialog v-model:open="showWebDAVConfig" />
|
||||
|
||||
<!-- WebDAV 文件列表对话框 -->
|
||||
<WebDAVFileListDialog v-model:open="showWebDAVFiles" :config="webdavConfig" @select="handleWebDAVDownload" />
|
||||
@@ -389,12 +389,7 @@
|
||||
import WebDAVConfigDialog from '@/components/settings/WebDAVConfigDialog.vue'
|
||||
import WebDAVFileListDialog from '@/components/settings/WebDAVFileListDialog.vue'
|
||||
import { useHints } from '@/composables/useHints'
|
||||
import {
|
||||
type WebDAVConfig,
|
||||
getWebDAVConfig,
|
||||
uploadToWebDAV,
|
||||
downloadFromWebDAV
|
||||
} from '@/services/webdavService'
|
||||
import { uploadToWebDAV, downloadFromWebDAV } from '@/services/webdavService'
|
||||
|
||||
const { t } = useI18n()
|
||||
const { hintsEnabled, setHintsEnabled, resetHints } = useHints()
|
||||
@@ -415,7 +410,7 @@
|
||||
// WebDAV 相关状态
|
||||
const showWebDAVConfig = ref(false)
|
||||
const showWebDAVFiles = ref(false)
|
||||
const webdavConfig = ref<WebDAVConfig | null>(getWebDAVConfig())
|
||||
const webdavConfig = computed(() => gameStore.webdavConfig)
|
||||
const isWebDAVUploading = ref(false)
|
||||
|
||||
// 确保通知设置存在
|
||||
@@ -758,11 +753,6 @@
|
||||
gameStore.player.backgroundEnabled = val
|
||||
}
|
||||
|
||||
// WebDAV 配置保存回调
|
||||
const onWebDAVConfigSaved = () => {
|
||||
webdavConfig.value = getWebDAVConfig()
|
||||
}
|
||||
|
||||
// WebDAV 上传
|
||||
const handleWebDAVUpload = async () => {
|
||||
if (!webdavConfig.value) return
|
||||
|
||||
Reference in New Issue
Block a user