mirror of
https://github.com/BTMuli/TeyvatGuide.git
synced 2025-12-12 09:18:14 +08:00
📦 add(db): 添加数据库路径
This commit is contained in:
@@ -120,6 +120,10 @@
|
|||||||
路径
|
路径
|
||||||
</v-list-subheader>
|
</v-list-subheader>
|
||||||
<v-divider inset class="border-opacity-75" />
|
<v-divider inset class="border-opacity-75" />
|
||||||
|
<v-list-item prepend-icon="mdi-database">
|
||||||
|
<v-list-item-title>本地数据库路径</v-list-item-title>
|
||||||
|
<v-list-item-subtitle>{{ appStore.dataPath.dbDataPath }}</v-list-item-subtitle>
|
||||||
|
</v-list-item>
|
||||||
<v-list-item prepend-icon="mdi-folder">
|
<v-list-item prepend-icon="mdi-folder">
|
||||||
<v-list-item-title>本地临时数据路径</v-list-item-title>
|
<v-list-item-title>本地临时数据路径</v-list-item-title>
|
||||||
<v-list-item-subtitle>{{ appStore.dataPath.tempDataDir }}</v-list-item-subtitle>
|
<v-list-item-subtitle>{{ appStore.dataPath.tempDataDir }}</v-list-item-subtitle>
|
||||||
|
|||||||
@@ -16,6 +16,8 @@ import { path } from "@tauri-apps/api";
|
|||||||
const userDataDir = `${await path.appLocalDataDir()}userData`;
|
const userDataDir = `${await path.appLocalDataDir()}userData`;
|
||||||
// 用于各种临时数据的路径
|
// 用于各种临时数据的路径
|
||||||
const tempDataDir = `${await path.appLocalDataDir()}tempData`;
|
const tempDataDir = `${await path.appLocalDataDir()}tempData`;
|
||||||
|
// 用于存放数据库的路径
|
||||||
|
const dbDataPath = `${await path.appConfigDir()}tauri-genshin.db`;
|
||||||
|
|
||||||
export const useAppStore = defineStore(
|
export const useAppStore = defineStore(
|
||||||
"app",
|
"app",
|
||||||
@@ -44,6 +46,7 @@ export const useAppStore = defineStore(
|
|||||||
const dataPath = reactive({
|
const dataPath = reactive({
|
||||||
userDataDir,
|
userDataDir,
|
||||||
tempDataDir,
|
tempDataDir,
|
||||||
|
dbDataPath,
|
||||||
});
|
});
|
||||||
// 用户数据路径
|
// 用户数据路径
|
||||||
const userPath = ref({
|
const userPath = ref({
|
||||||
|
|||||||
Reference in New Issue
Block a user