From b4f20598c80a6a3a706ecb6292cea5f2ddbd27c8 Mon Sep 17 00:00:00 2001 From: A1300399510 Date: Fri, 28 Jul 2023 18:06:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/seachPage/input.vue | 2 +- src/main.js | 30 ++++++++++++------------------ src/views/seachIndex.vue | 3 ++- 3 files changed, 15 insertions(+), 20 deletions(-) diff --git a/src/components/seachPage/input.vue b/src/components/seachPage/input.vue index be03b0f..32eed59 100644 --- a/src/components/seachPage/input.vue +++ b/src/components/seachPage/input.vue @@ -797,7 +797,7 @@ img { .img { width: 20px; height: 20px; - margin-left: 10px; + margin-right: 6px; } } diff --git a/src/main.js b/src/main.js index d8d21ee..65d43d6 100644 --- a/src/main.js +++ b/src/main.js @@ -44,19 +44,6 @@ import api from "./utils/api"; import Axios from '@/utils/axios'; -api.index().then(res => { - if (res.code === 200) { - store.state.seachTypeData = res.data.combination - store.state.indexData = res.data - store.state.ListSelectBtn = res.data.recommendedTab - store.state.user = res.data.user - store.state.nav = res.data.nav - store.state.wechat = res.data.wechat - store.state.apartment = res.data.config.apartment - } -}) - - const app = createApp(App) app.use(ElButton) @@ -82,9 +69,16 @@ app.use(ElAffix) app.use(lazyPlugin) +app.use(store).use(router).use(Axios) -app.use(store).use(router).use(Axios).mount('#app') -// app.use(store).use(router).use(Axios).use(ElementPlus, { -// locale: zhCn -// }).mount('#app') - +api.index().then(res => { + store.state.seachTypeData = res.data.combination + store.state.indexData = res.data + store.state.ListSelectBtn = res.data.recommendedTab + store.state.user = res.data.user + store.state.nav = res.data.nav + store.state.wechat = res.data.wechat + store.state.apartment = res.data.config.apartment +}).finally(()=>{ + app.mount('#app') +}) \ No newline at end of file diff --git a/src/views/seachIndex.vue b/src/views/seachIndex.vue index c731232..7d91053 100644 --- a/src/views/seachIndex.vue +++ b/src/views/seachIndex.vue @@ -24,7 +24,8 @@ - + +