From d73a8d6f2e5c93e96c8f73831b8921fdf33428f1 Mon Sep 17 00:00:00 2001
From: dengjie <209192278@qq.com>
Date: Sat, 27 May 2023 21:39:17 +0800
Subject: [PATCH] =?UTF-8?q?=E9=82=93=E6=B4=81=20:=20=E4=BF=AE=E6=94=B9bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
package.json | 1 +
public/index.html | 2 +-
src/assets/index/b1.jpg | Bin 83336 -> 0 bytes
src/components/FastFindProducts.vue | 24 ++-
src/components/NewsCenter.vue | 65 ++++--
src/components/PicturesBox.vue | 6 +
src/main.js | 2 +
src/router/index.js | 6 -
src/views/aboutUs/index.vue | 44 ++--
src/views/attractAndJoin/index.vue | 7 +-
src/views/contactUs/index.vue | 5 +
src/views/header/index.vue | 18 +-
src/views/imageDisplay/index.vue | 17 ++
src/views/index/index.vue | 5 +
src/views/news/detail.vue | 56 ++++--
src/views/news/index.vue | 29 +++
src/views/productsCenter/detail.vue | 148 ++++++++------
src/views/productsCenter/index.vue | 299 +++++++++++++---------------
18 files changed, 452 insertions(+), 282 deletions(-)
delete mode 100644 src/assets/index/b1.jpg
diff --git a/package.json b/package.json
index 0d0ea22..228543a 100644
--- a/package.json
+++ b/package.json
@@ -20,6 +20,7 @@
"script-ext-html-webpack-plugin": "^2.1.5",
"vue": "^2.6.11",
"vue-i18n": "^8.26.7",
+ "vue-meta": "^2.4.0",
"vue-router": "^3.2.0"
},
"devDependencies": {
diff --git a/public/index.html b/public/index.html
index 73928cd..8bbac95 100644
--- a/public/index.html
+++ b/public/index.html
@@ -5,7 +5,7 @@
-
艺鹏瓷砖|广东祥睿陶瓷有限公司
+ 蒙彼利瓷砖 | 广东蒙彼利陶瓷有限公司
diff --git a/src/views/news/detail.vue b/src/views/news/detail.vue
index 0e61916..996688c 100644
--- a/src/views/news/detail.vue
+++ b/src/views/news/detail.vue
@@ -15,15 +15,20 @@
分享到:
-
+
-
+
-
+
+
+ {{ detail_title }}
+
+
+
@@ -35,24 +40,31 @@ import {getArticleInfo} from "@/api";
export default {
name: "detail",
+ metaInfo() {
+ return {
+ title: this.detail_title + " | " + localStorage.getItem("corporate_name")
+ };
+ },
props: {
newsId: Number,
classIndex: Number
},
data() {
return {
- tabs_title: '公司新闻',
- htmlStr: '',
- }
+ tabs_title: "公司新闻",
+ htmlStr: "",
+ detail_title: ""
+ };
},
mounted() {
- if(this.classIndex==1){
- this.tabs_title='行业动态'
- }else if(this.classIndex==2){
- this.tabs_title='瓷砖百科'
+ if (this.classIndex == 1) {
+ this.tabs_title = "行业动态";
+ } else if (this.classIndex == 2) {
+ this.tabs_title = "瓷砖百科";
}
getArticleInfo(this.newsId).then(res => {
- this.htmlStr=res.data.articleinfo.content
+ this.detail_title = res.data.articleinfo.title;
+ this.htmlStr = res.data.articleinfo.content;
});
},
methods: {
@@ -81,26 +93,29 @@ export default {
// "&summary=" +
// this.sysInfo
);
- },
+ }
}
-}
+};
diff --git a/src/views/news/index.vue b/src/views/news/index.vue
index bf340d0..7cfad63 100644
--- a/src/views/news/index.vue
+++ b/src/views/news/index.vue
@@ -29,6 +29,11 @@ import {getArticleList} from "@/api";
export default {
name: "index",
+ metaInfo() {
+ return {
+ title:'新闻资讯 | '+localStorage.getItem('corporate_name')
+ };
+ },
components: {Detail, PicturesBox, Pagination, ProductsTabsItem},
data() {
return {
@@ -71,6 +76,11 @@ export default {
this.$refs.ProductsTabsItem.activeName = i + "";
}
}
+ if(this.$route.query.newsId!==undefined){
+ this.newsId = this.$route.query.newsId;
+ this.showDetail = true;
+ this.showImage = false;
+ }
},
mounted() {
if(this.$route.query.menuDetail){
@@ -110,11 +120,30 @@ export default {
this.classIndex = parseInt(tab.index);
if (tab.index == 0) {
this.getArticleList(5, this.page, this.limit);
+ this.$router.push({
+ path: "/news",
+ query: {
+ menu: 5
+ }
+ });
} else if (tab.index == 1) {
this.getArticleList(6, this.page, this.limit);
+ this.$router.push({
+ path: "/news",
+ query: {
+ menu: 6
+ }
+ });
} else if (tab.index == 2) {
this.getArticleList(7, this.page, this.limit);
+ this.$router.push({
+ path: "/news",
+ query: {
+ menu: 7
+ }
+ });
}
+
},
//新闻分页
handleChangePage(value) {
diff --git a/src/views/productsCenter/detail.vue b/src/views/productsCenter/detail.vue
index 2a14476..3d96c03 100644
--- a/src/views/productsCenter/detail.vue
+++ b/src/views/productsCenter/detail.vue
@@ -10,12 +10,12 @@
- 产品名称:{{detailList.name}}
+ 产品名称:{{ detailList.name }}
-
产品分类:{{classifyName}}
-
适用空间:{{detailList.space}}
-
所属风格:{{detailList.style}}
+
产品分类:{{ classifyName }}
+
适用空间:{{ detailList.space }}
+
所属风格:{{ detailList.style }}
@@ -29,7 +29,7 @@
-
+
@@ -44,10 +44,10 @@
同类产品推荐
- -
+
-
![]()
-
{{item.name}}
+
{{ item.name }}
@@ -63,79 +63,107 @@