Browse Source

用户选择不同规格,商品详情页上的价格应根据规格进行变化输入图片说明

zyh
Gao xiaosong 4 years ago
parent
commit
bc02f4d844
  1. 5
      pages/shop/GoodsCon/index.vue

5
pages/shop/GoodsCon/index.vue

@ -9,8 +9,8 @@
<view class="share acea-row row-between row-bottom"> <view class="share acea-row row-between row-bottom">
<view class="money font-color-red"> <view class="money font-color-red">
<text></text> <text></text>
<text class="num">{{ storeInfo.price }}</text> <text class="num">{{ attr.productSelect.price || storeInfo.price }}</text>
<text class="vip-money" v-if="storeInfo.vipPrice && storeInfo.vipPrice > 0">{{ storeInfo.vipPrice }}</text> <text class="vip-money" v-if="storeInfo.vipPrice && storeInfo.vipPrice > 0">{{ attr.productSelect.vipPrice || storeInfo.vipPrice }}</text>
<image src="@/static/images/vip.png" class="image" v-if="storeInfo.vipPrice && storeInfo.vipPrice > 0" /> <image src="@/static/images/vip.png" class="image" v-if="storeInfo.vipPrice && storeInfo.vipPrice > 0" />
</view> </view>
<view class="iconfont icon-fenxiang" @click="listenerActionSheet"></view> <view class="iconfont icon-fenxiang" @click="listenerActionSheet"></view>
@ -615,6 +615,7 @@
// //
let productSelect = this.productValue[res.value]; let productSelect = this.productValue[res.value];
console.log(productSelect)
if (productSelect) { if (productSelect) {
this.attr.productAttr[res.indexw].index = res.indexn; this.attr.productAttr[res.indexw].index = res.indexn;
this.$set(this.attr.productSelect, "image", productSelect.image); this.$set(this.attr.productSelect, "image", productSelect.image);

Loading…
Cancel
Save