diff --git a/buyer/src/main.js b/buyer/src/main.js index a94b89ea..9b737c99 100644 --- a/buyer/src/main.js +++ b/buyer/src/main.js @@ -1,5 +1,3 @@ -// The Vue build version to load with the `import` command -// (runtime-only or standalone) has been set in webpack.base.conf with an alias. import Vue from 'vue'; import App from './App'; import router from './router'; diff --git a/buyer/src/pages/Cart.vue b/buyer/src/pages/Cart.vue index 73e655b4..4c452885 100644 --- a/buyer/src/pages/Cart.vue +++ b/buyer/src/pages/Cart.vue @@ -219,8 +219,8 @@ export default { } }); }, + // 清空购物车 clearCart () { - // 清空购物车 this.$Modal.confirm({ title: '提示', content: '
确定要清空购物车吗?清空后不可恢复
', @@ -248,8 +248,8 @@ export default { showCoupon (storeId, index) { this.couponAvailable = index; }, + // 设置购买数量 changeNum (val, id) { - // 设置购买数量 console.log(val, id); APICart.setCartGoodsNum({ skuId: id, num: val }).then((res) => { console.log(res); @@ -258,8 +258,8 @@ export default { } }); }, + // 设置商品选中状态 async changeChecked (status, type, id) { - // 设置商品选中状态 const check = status ? 1 : 0; if (type === 'all') { // 全选 @@ -274,9 +274,8 @@ export default { this.getCartList(); }, - + // 领取优惠券 async receiveShopCoupon (item) { - // 领取优惠券 let res = await APIMember.receiveCoupon(item.id); if (res.success) { this.$set(item, 'disabled', true); @@ -285,8 +284,8 @@ export default { this.$Message.error(res.message); } }, + // 购物车列表 async getCartList () { - // 购物车列表 this.loading = true; try { let res = await APICart.cartGoodsAll(); diff --git a/buyer/src/pages/GoodsDetail.vue b/buyer/src/pages/GoodsDetail.vue index 4613c017..f4e664b7 100644 --- a/buyer/src/pages/GoodsDetail.vue +++ b/buyer/src/pages/GoodsDetail.vue @@ -54,6 +54,7 @@ export default { }; }, methods: { + // 获取商品详情 getGoodsDetail () { this.isLoading = true; const params = this.$route.query @@ -142,12 +143,6 @@ export default { color: #2c2c2c; } -.like { - width: 100%; - padding: 20px 0; - @include white_background_color(); -} - .shop-nav-container { width: 1200px; margin: 0 auto; diff --git a/buyer/src/pages/GoodsList.vue b/buyer/src/pages/GoodsList.vue index fc0d3ae2..31f2b9c3 100644 --- a/buyer/src/pages/GoodsList.vue +++ b/buyer/src/pages/GoodsList.vue @@ -77,6 +77,7 @@