diff --git a/components/productWindow/index.vue b/components/productWindow/index.vue index f125425..f6b0ea0 100644 --- a/components/productWindow/index.vue +++ b/components/productWindow/index.vue @@ -28,6 +28,7 @@ {{ attr.productSelect.price }} + +积分{{point}} ¥{{attr.productSelect.svip_price}} @@ -59,7 +60,7 @@ 数量 - + ({{minCount}}件起购最多{{maxCount}}件) @@ -161,6 +162,15 @@ domain: { type: String, value: '' + }, + productType:{ + type:null, + value:null + }, + point:{ + type:Number||String, + value:0 + } }, computed: mapGetters(['viewColor']), @@ -169,7 +179,7 @@ }; }, mounted(){ - console.log(this.maxCount) + console.log(this.maxCount,this.attr,"=-") }, methods: { // 查看大图 diff --git a/pages/goods_details/index.vue b/pages/goods_details/index.vue index a0c56c8..29c57fa 100644 --- a/pages/goods_details/index.vue +++ b/pages/goods_details/index.vue @@ -356,7 +356,7 @@ :showAnimate="showAnimate" @boxStatus="boxStatus"> - - + @@ -94,7 +94,7 @@ ¥{{goods.activeSku.active_price}} - ¥{{goods.productAttr.price}} + ¥{{goods.productAttr.price}}+积分{{goods.productAttr.point}} X{{goods.cart_num}} @@ -147,7 +147,8 @@ v-if="order_type != 3 && order_type != 4 && item.order.enabledCoupon"> 店铺优惠券 - + + 优惠¥{{item.order.coupon_price}} 暂未选择优惠券 @@ -425,7 +426,8 @@ v-if="order_type != 3 && order_type != 4 && enabledPlatformCoupon"> 平台优惠券 - + + 优惠¥{{total_platform_coupon_price}} 暂未选择优惠券 @@ -446,6 +448,7 @@ 合计: ¥{{totalPrice || 0}} + +积分{{totalPoint}} 优惠:¥ {{couponData.total_coupon}} @@ -699,6 +702,7 @@ orderType:null, // is_burst:null, productType:null, + totalPoint:0, }; }, computed: { @@ -1179,7 +1183,13 @@ formData.sort(sortNumber); that.$set(that, 'order_form', (that.order_form && that.order_form.length>0) ? that.order_form : formData); } - that.totalPrice = res.data.order_price + that.totalPrice = res.data.order_price; + that.totalPoint = 0 + res.data.order.forEach(item => { + item.list.forEach(i=>{ + that.totalPoint+=i.productAttr.point + }) + }) that.orderStatus = res.data.status that.proPrice = res.data.total_price that.order_type = res.data.order_type