Feat: 折扣对接
This commit is contained in:
@@ -95,6 +95,13 @@
|
||||
<u-switch v-model="canTransfer" ></u-switch>
|
||||
</view>
|
||||
</view>
|
||||
<view class="price-wrap">
|
||||
<view class="v12-font-28 v12-dark-text v12-font-bold">价格明细</view>
|
||||
<view class="v12-justify-between v12-align-center v12-font-28 v12-mt-1">
|
||||
<view>商品总价:</view>
|
||||
<view>1224</view>
|
||||
</view>
|
||||
</view>
|
||||
<button v-if="isPayOk" open-type="share" class="share-btn" >
|
||||
<view class="v12-font-28 v12-primary-text v12-align-center">
|
||||
<u-icon :name="webUrl + '/icon/gift-primary.png'" size="18"></u-icon>
|
||||
@@ -181,12 +188,14 @@ export default {
|
||||
giftKey: '',
|
||||
payPrice: 0,
|
||||
orderId: '',
|
||||
defaultIndex:0
|
||||
defaultIndex:0,
|
||||
discount: null
|
||||
}
|
||||
},
|
||||
onLoad(opts) {
|
||||
this.cartId = opts.cartId
|
||||
this.couponId = opts.couponId
|
||||
this.discount = opts.discount
|
||||
this.getGift()
|
||||
},
|
||||
computed: mapGetters(["userInfo"]),
|
||||
@@ -248,7 +257,10 @@ export default {
|
||||
const params = {
|
||||
cartId: this.cartId,
|
||||
couponId: this.couponId,
|
||||
cartNum : num,
|
||||
cartNum : num
|
||||
}
|
||||
if(this.discount) {
|
||||
params.discount = this.discount
|
||||
}
|
||||
getGiftCardSendOrderAmount(this.orderKey, params).then(res => {
|
||||
this.payPrice = res.data.result.payPrice
|
||||
@@ -553,4 +565,13 @@ export default {
|
||||
.share-btn::after {
|
||||
border: none;
|
||||
}
|
||||
.price-wrap{
|
||||
width: 100%;
|
||||
height: 320rpx;
|
||||
background: #fff;
|
||||
border-radius: 20rpx;
|
||||
margin-top: 30rpx;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user