From 5a1cc511d0a16970d5d56fad3cfeaab8f0d903d2 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期五, 26 七月 2024 15:19:40 +0800
Subject: [PATCH] 提交

---
 wechat_jiaxuan/components/disProduct/index.js |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/wechat_jiaxuan/components/disProduct/index.js b/wechat_jiaxuan/components/disProduct/index.js
index 88d9997..30e7d2b 100644
--- a/wechat_jiaxuan/components/disProduct/index.js
+++ b/wechat_jiaxuan/components/disProduct/index.js
@@ -22,7 +22,7 @@
     pageSize: 10,
     total: 0,
     query: '',
-    sortType: 'NORMAL',
+    sortType: '',
     catalogCode: ""
   },
   attached() {
@@ -61,10 +61,12 @@
       }).then(res => {
         this.setData({
           secondCateList: res.data || [],
+          activeParam: []
         })
       })
     },
     bindblur() {
+      this.setData({ pageNum: 1,datalist: [],total: 0})
       this.getList()
     },
     getList() {
@@ -93,7 +95,7 @@
     },
     cateClick(e) {
       const catalogCode = e.currentTarget.dataset.code
-      this.setData({ catalogCode })
+      this.setData({ catalogCode, tagCodes: [] })
       this.setData({ pageNum: 1,datalist: [],total: 0})
       this.getTag()
       this.getList()
@@ -135,7 +137,6 @@
         secondCateList[activeIndex].paramIndex = -1
         secondCateList[activeIndex].paramName = ''
       }
-      this.setData({ pageNum: 1,datalist: [],total: 0})
       this.setData({ tagCodes, secondCateList })
     },
     changeShowParams(e){
@@ -151,7 +152,6 @@
           activeParam: secondCateList[activeIndex].valueVos
         })
       }
-      console.log('activeParam', this.data.activeParam);
       // this.setData({showTwo: false})
     },
     cancelParam() {
@@ -160,7 +160,7 @@
         item.paramIndex = -1
         item.paramName = ''
       })
-      this.setData({ tagCodes: [],activeParam: [],cateList,activeIndex: -1 })
+      this.setData({ tagCodes: [],activeParam: [],secondCateList,activeIndex: -1 })
     },
     subParam() {
       this.setData({ activeParam: [] })

--
Gitblit v1.9.3