From d57ce639eeb06a1a1e92fa66ac2b100f8ffac253 Mon Sep 17 00:00:00 2001 From: aBin Date: Wed, 23 Feb 2022 15:28:41 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=84=E7=A7=8D=E7=BB=86=E8=8A=82=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 +- .env.production | 2 +- src/components/BayWindow/BayWindow.vue | 2 +- src/components/Carousel/Carousel.vue | 1 + src/components/Footer/Footer.vue | 34 +- src/components/HeadNav/HeadNav.vue | 13 +- src/components/LeftNav/LeftNav.vue | 81 +++- src/components/RichText/Relevant.vue | 4 +- src/views/OtherPages/Department.vue | 544 +++++++++++++++++++++++++ src/views/OtherPages/Information.vue | 44 ++ 10 files changed, 687 insertions(+), 40 deletions(-) diff --git a/.env.development b/.env.development index 75d458d..77d49e7 100644 --- a/.env.development +++ b/.env.development @@ -1,7 +1,7 @@ VUE_APP_MODE=development VUE_APP_NODE_ENV=development VUE_APP_SCENE=/datang/ -VUE_APP_BASE_URL=http://test.tall.wiki/ +VUE_APP_BASE_URL=http://test.tall.wiki VUE_APP_API_URL=http://test.tall.wiki/datang/v1.0 VUE_APP_PROXY_URL=/datang/v1.0 VUE_APP_PUBLIC_PATH=/datang diff --git a/.env.production b/.env.production index 44a0ffe..cf94baf 100644 --- a/.env.production +++ b/.env.production @@ -1,7 +1,7 @@ VUE_APP_MODE=production VUE_APP_NODE_ENV=production VUE_APP_SCENE=/datang/ -VUE_APP_BASE_URL=http://test.tall.wiki/ +VUE_APP_BASE_URL=http://test.tall.wiki VUE_APP_API_URL=http://test.tall.wiki/datang/v1.0 VUE_APP_PROXY_URL=/datang/v1.0 VUE_APP_PUBLIC_PATH=/datang diff --git a/src/components/BayWindow/BayWindow.vue b/src/components/BayWindow/BayWindow.vue index 6ba6b1c..94e5081 100644 --- a/src/components/BayWindow/BayWindow.vue +++ b/src/components/BayWindow/BayWindow.vue @@ -87,7 +87,7 @@ export default { openPage() { this.$router.push({ path: '/notice', - query: { code: '0505' }, + query: { code: '0505', introId: this.content.content.id }, }); }, }, diff --git a/src/components/Carousel/Carousel.vue b/src/components/Carousel/Carousel.vue index e7af86a..e385fa6 100644 --- a/src/components/Carousel/Carousel.vue +++ b/src/components/Carousel/Carousel.vue @@ -47,6 +47,7 @@ export default { methods: { async getImg() { try { + if (this.code.length !== 4) return; const params = { param: { showPage: this.code } }; const res = await carouselQuery(params); const { data, code, msg } = res.data; diff --git a/src/components/Footer/Footer.vue b/src/components/Footer/Footer.vue index 99bf767..e945417 100644 --- a/src/components/Footer/Footer.vue +++ b/src/components/Footer/Footer.vue @@ -8,21 +8,23 @@
-
- - -
- +
@@ -394,10 +394,15 @@ export default { }, ], showPage: 0, + text: '', }; }, watch: { '$route.path'(val) { + if (this.$route.query.text) { + console.log('this.$route.query.text: ', this.$route.query.text); + this.text = this.$route.query.text; + } for (let i = 0; i < this.tabList.length; i++) { const item = this.tabList[i]; if (val === item.url) { @@ -410,6 +415,10 @@ export default { }, }, created() { + if (this.$route.query.text) { + console.log('this.$route.query.text: ', this.$route.query.text); + this.text = this.$route.query.text; + } setTimeout(() => { for (let i = 0; i < this.tabList.length; i++) { if (this.tabList[i].url && this.$route.path === this.tabList[i].url) { @@ -420,7 +429,7 @@ export default { }, methods: { onSearch(e) { - window.open(`http://${window.location.host}/search?text=${e}`); + window.open(`${process.env.VUE_APP_BASE_URL + process.env.VUE_APP_PUBLIC_PATH}/search?text=${e}`); }, jumpPage(index, url, children) { if (this.showPage === index) { diff --git a/src/components/LeftNav/LeftNav.vue b/src/components/LeftNav/LeftNav.vue index a5f3321..96e4221 100644 --- a/src/components/LeftNav/LeftNav.vue +++ b/src/components/LeftNav/LeftNav.vue @@ -3,15 +3,27 @@
{{ list.title }}
-
- {{ item.title }} -
+