|
|
|
@ -8,7 +8,7 @@ |
|
|
|
<view class="flex justify-between align-start padding-top-sm padding-lr"> |
|
|
|
<image :src="orderDetails.goods.cover" mode="aspectFill" style="width: 240rpx; height: 240rpx;border-radius: 10rpx;"></image> |
|
|
|
<view class="flex-sub padding-left-sm"> |
|
|
|
<view class="bref-box lf-font-32 lf-font-bold" style="height: 88rpx;line-height: 44rpx;color: #222;"> |
|
|
|
<view class="bref-box lf-font-32 lf-line-2 lf-font-bold" style="height: 88rpx;line-height: 44rpx;color: #222;"> |
|
|
|
{{orderDetails.goods.name}} |
|
|
|
</view> |
|
|
|
<view class="flex justify-between align-center text-center"> |
|
|
|
@ -133,9 +133,13 @@ |
|
|
|
methods: { |
|
|
|
changeNum(num) { |
|
|
|
if(num > this.limit) { |
|
|
|
this.$msg('该商品限购'+this.limit+'件') |
|
|
|
this.num = this.limit |
|
|
|
return |
|
|
|
if(this.limit == 0 || this.limit == '') { |
|
|
|
this.num = num |
|
|
|
}else { |
|
|
|
this.$msg('该商品限购'+this.limit+'件') |
|
|
|
this.num = this.limit |
|
|
|
return |
|
|
|
} |
|
|
|
}else if(num < 1) { |
|
|
|
this.num = 1 |
|
|
|
} |
|
|
|
@ -149,12 +153,14 @@ |
|
|
|
}) |
|
|
|
}, |
|
|
|
reduce() { |
|
|
|
if (this.num === 1) return |
|
|
|
if (this.num === 1 || this.num === 0) return |
|
|
|
this.num-- |
|
|
|
}, |
|
|
|
add() { |
|
|
|
if(this.num < this.limit) { |
|
|
|
this.num++ |
|
|
|
}else if(this.limit == 0 || this.limit == ''){ |
|
|
|
this.num++ |
|
|
|
}else { |
|
|
|
this.$msg('该商品限购'+this.limit+'件') |
|
|
|
this.num = this.limit |
|
|
|
|