diff --git a/pages/columnGoods/goods_area_list/index.vue b/pages/columnGoods/goods_area_list/index.vue index 275e6b8..f81ebd8 100644 --- a/pages/columnGoods/goods_area_list/index.vue +++ b/pages/columnGoods/goods_area_list/index.vue @@ -15,13 +15,11 @@ - - {{downMenu[downKey].title}} - - - - 销量 + 上架 + + + 价格 @@ -29,11 +27,6 @@ - - - 筛选 - - @@ -173,10 +166,13 @@ // price_off: '', // brand_id: '', // keyword:'', + priceSort:'', + timeSort:'', page:1, limit:10 }, price: 0, + time: 0, stock: 0, nows: false, loadend: false, @@ -289,38 +285,38 @@ this.storeMerchantList() }, // 右侧切换 - bindRight(){ - this.price = 0; - this.firstKey = 4 - this.getBrandlist() + // bindRight(){ + // this.price = 0; + // this.firstKey = 4 + // this.getBrandlist() - }, + // }, // 品牌列表 - getBrandlist(){ - let temp = [] - getBrandlist({ - // cate_pid:this.where.cate_pid, - keyword:this.where.keyword - }).then(res=>{ - temp = res.data.list.map(item=>{ - return { - ...item, - check:false - } - }) - if(this.where.brand_id.length>0){ - this.where.brand_id.forEach((ids,index)=>{ - temp.forEach(el=>{ - if(ids == el.brand_id){ - el.check = true - } - }) - }) - } - this.brandList = temp - this.rightBox = true - }) - }, + // getBrandlist(){ + // let temp = [] + // getBrandlist({ + // // cate_pid:this.where.cate_pid, + // keyword:this.where.keyword + // }).then(res=>{ + // temp = res.data.list.map(item=>{ + // return { + // ...item, + // check:false + // } + // }) + // if(this.where.brand_id.length>0){ + // this.where.brand_id.forEach((ids,index)=>{ + // temp.forEach(el=>{ + // if(ids == el.brand_id){ + // el.check = true + // } + // }) + // }) + // } + // this.brandList = temp + // this.rightBox = true + // }) + // }, // 去详情页 godDetail(item) { goShopDetail(item, this.uid).then(res => { @@ -429,13 +425,13 @@ this.firstKey = e if (this.price == 0){ this.price = 1; - this.where.order = 'price_asc' + this.where.priceSort = 1; }else if (this.price == 1){ this.price = 2; - this.where.order = 'price_desc' + this.where.priceSort = 2; }else if (this.price == 2){ this.price = 0; - this.where.order = '' + this.where.priceSort = '' } this.$set(this.where, 'page', 1) this.get_product_list(true); @@ -443,10 +439,19 @@ case 3: this.price = 0; this.loadend = false; - this.$set(this.where, 'order', 'sales') + + if (this.time == 0){ + this.time = 1; + this.where.timeSort = 1; + }else if (this.time == 1){ + this.time = 2; + this.where.timeSort = 2; + }else if (this.time == 2){ + this.time = 0; + this.where.timeSort = '' + } this.$set(this.where, 'page', 1) this.get_product_list(true); - this.firstKey = e break; } this.loadend = false;