diff --git a/pages/home/components/slide.vue b/pages/home/components/slide.vue index 6392e6d09aa847d6ca2717742a087e552b183036..7a72dbcfd7850065ae1a345af5d56c1712f818a5 100755 --- a/pages/home/components/slide.vue +++ b/pages/home/components/slide.vue @@ -30,7 +30,15 @@ } }, mounted() { + const goods_type = getCurrentPages()[0]['$route']['query']['goods_type'] || ''; const { infinite } = this.slide_setting; + const list = []; + this.slide_list.map((item, index) => { + if((item.goods_type && item.goods_type === goods_type) || !item.goods_type) { + list.push(item) + } + }); + this.slide_list = list; if(!infinite) { const time = this.interval * this.slide_list.length; setTimeout(() => {