From 58788b3e5357e6c6bc3f03cbd433d167acfe424b Mon Sep 17 00:00:00 2001 From: significative <163999932+significative@users.noreply.github.com> Date: Sat, 14 Sep 2024 17:09:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0logo?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jeecgboot-vue3-master/index.html | 16 +++++++++++++++- jeecgboot-vue3-master/src/App.vue | 10 ---------- .../src/store/modules/useSettingStore.ts | 4 ++-- 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/jeecgboot-vue3-master/index.html b/jeecgboot-vue3-master/index.html index ee7e9e31..defc2fe7 100644 --- a/jeecgboot-vue3-master/index.html +++ b/jeecgboot-vue3-master/index.html @@ -161,7 +161,7 @@
- +
@@ -169,6 +169,20 @@
+ diff --git a/jeecgboot-vue3-master/src/App.vue b/jeecgboot-vue3-master/src/App.vue index dd0ee18c..7cb7cca6 100644 --- a/jeecgboot-vue3-master/src/App.vue +++ b/jeecgboot-vue3-master/src/App.vue @@ -11,16 +11,6 @@ import { AppProvider } from '/@/components/Application'; import { useTitle } from '/@/hooks/web/useTitle'; import { useLocale } from '/@/locales/useLocale'; - import { useSettingStore } from '/@/store/modules/useSettingStore'; - const { setting } = useSettingStore(); - (function () { - const link = document.createElement('link'); - link.rel = 'icon'; - link.href = setting.logo; - - const head = document.head || document.getElementsByTagName('head')[0]; - head.appendChild(link); - })(); // 解决日期时间国际化问题 import 'dayjs/locale/zh-cn'; diff --git a/jeecgboot-vue3-master/src/store/modules/useSettingStore.ts b/jeecgboot-vue3-master/src/store/modules/useSettingStore.ts index 68b760e1..31c4ad86 100644 --- a/jeecgboot-vue3-master/src/store/modules/useSettingStore.ts +++ b/jeecgboot-vue3-master/src/store/modules/useSettingStore.ts @@ -25,11 +25,11 @@ async function getSetting(setting) { export const useSettingStore = defineStore('setting', { state: () => { - getSetting(setting); + const isGot = getSetting(setting); const getDescriptor = (prop: string) => { return { get: () => setting[prop] }; }; - return { setting, getDescriptor }; + return { setting, getDescriptor, isGot }; }, });