瀏覽代碼

bug修复

ming 1 年之前
父節點
當前提交
d6e7b98b27
共有 1 個文件被更改,包括 7 次插入2 次删除
  1. 7 2
      assets/js/commonVue.js

+ 7 - 2
assets/js/commonVue.js

@@ -113,6 +113,7 @@ var app = new Vue({
 
             // 进入详情页
             if (res.data[i].sname == '/product/index.html' && window.location.pathname == '/product/read.html') {
+              
               getDetailCommon()
             }
             if (res.data[i].sname == '/solution/index.html' && window.location.pathname == '/solution/read.html') {
@@ -127,8 +128,9 @@ var app = new Vue({
               //获取详情相关数据
               setTimeout(() => {
                 _this.requestParams.title = ''
+                _this.requestParams.articleid = 0
                 _this.getArticalData(_this.requestParams, 1)
-              }, 1)
+              }, 100)
               _this.currentPath = res.data[i].sname //产品详情时栏目高亮
               _this.columnImage = res.data[i].imagePath; //栏目图片获取
             }
@@ -178,7 +180,10 @@ var app = new Vue({
           _this.articalArray = aa;
         }
         if (bb) {
-          _this.articalArrayRelated = bb.filter(obj => obj.id != _this.articalArray[0].id);
+          console.log(bb)
+          console.log(_this.articalArray[0])
+          _this.articalArrayRelated = bb.filter(obj => obj.title != _this.articalArray[0].title);
+          // _this.articalArrayRelated = bb
           console.log(_this.articalArrayRelated)
         }
         _this.loading = false;