|
|
@ -32,7 +32,7 @@ |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="width94 concont mart10 backcorfff"> |
|
|
|
<view class="width94 concont mart10 backcorfff marb100"> |
|
|
|
<view class="height50 width100 paddtop5 backcorfff" @click="showPopup()"> |
|
|
|
<view class="height50 width100 paddtop5 backcorfff" @click="showPopup()"> |
|
|
|
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> |
|
|
|
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> |
|
|
|
优惠抵扣<text class="yhqky">{{OrderPreList.length}}张可用</text> |
|
|
|
优惠抵扣<text class="yhqky">{{OrderPreList.length}}张可用</text> |
|
|
@ -86,7 +86,7 @@ |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" |
|
|
|
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" |
|
|
|
style="align-items: center;" v-if="isUse"> |
|
|
|
style="align-items: center;" v-if="isUse"> |
|
|
|
<radio :checked="paytype=='2'" color="#c72a20"/> |
|
|
|
<radio :checked="paytype=='2'" color="#c72a20" /> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="width94 line1 mart5 marb5" v-if="item == 3"></view> |
|
|
|
<view class="width94 line1 mart5 marb5" v-if="item == 3"></view> |
|
|
@ -153,7 +153,8 @@ |
|
|
|
findUser, |
|
|
|
findUser, |
|
|
|
qianzhuorderToPayByWx, |
|
|
|
qianzhuorderToPayByWx, |
|
|
|
czhltUnionCardPay, |
|
|
|
czhltUnionCardPay, |
|
|
|
getUserOrderPreList |
|
|
|
getUserOrderPreList, |
|
|
|
|
|
|
|
thirdCancelOrder |
|
|
|
} from '../../Utils/Api.js'; |
|
|
|
} from '../../Utils/Api.js'; |
|
|
|
// #ifdef H5 |
|
|
|
// #ifdef H5 |
|
|
|
var jweixin = require('jweixin-module'); |
|
|
|
var jweixin = require('jweixin-module'); |
|
|
@ -203,9 +204,9 @@ |
|
|
|
this.totalprice = options.price; |
|
|
|
this.totalprice = options.price; |
|
|
|
this.payPrice = options.price; |
|
|
|
this.payPrice = options.price; |
|
|
|
this.goodName = options.name; |
|
|
|
this.goodName = options.name; |
|
|
|
this.customerMobile = app.globalData.userInfo.phone; |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
onShow() { |
|
|
|
onShow() { |
|
|
|
|
|
|
|
this.customerMobile = app.globalData.userInfo.phone; |
|
|
|
this.findUser(); |
|
|
|
this.findUser(); |
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
@ -284,10 +285,12 @@ |
|
|
|
blockEnd() { |
|
|
|
blockEnd() { |
|
|
|
this.isDiscount = 1; |
|
|
|
this.isDiscount = 1; |
|
|
|
if (this.deductionPrice == 0) { |
|
|
|
if (this.deductionPrice == 0) { |
|
|
|
this.payPrice = Math.abs(parseFloat(this.totalprice - parseFloat(this.priceValue[1] / 100).toFixed(2)).toFixed( |
|
|
|
this.payPrice = Math.abs(parseFloat(this.totalprice - parseFloat(this.priceValue[1] / 100).toFixed(2)) |
|
|
|
2)); |
|
|
|
.toFixed( |
|
|
|
|
|
|
|
2)); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
this.payPrice = Math.abs(parseFloat(this.orderPrice - parseFloat(this.priceValue[1] / 100).toFixed(2) - this |
|
|
|
this.payPrice = Math.abs(parseFloat(this.orderPrice - parseFloat(this.priceValue[1] / 100).toFixed(2) - |
|
|
|
|
|
|
|
this |
|
|
|
.deductionPrice).toFixed(2)); |
|
|
|
.deductionPrice).toFixed(2)); |
|
|
|
} |
|
|
|
} |
|
|
|
if (this.payPrice == 0) { |
|
|
|
if (this.payPrice == 0) { |
|
|
@ -368,7 +371,7 @@ |
|
|
|
"openIdType": this.showType |
|
|
|
"openIdType": this.showType |
|
|
|
} |
|
|
|
} |
|
|
|
this.qianzhuorderToPayByWx(params); |
|
|
|
this.qianzhuorderToPayByWx(params); |
|
|
|
}else { |
|
|
|
} else { |
|
|
|
uni.showToast({ |
|
|
|
uni.showToast({ |
|
|
|
title: res.return_msg, |
|
|
|
title: res.return_msg, |
|
|
|
icon: 'none', |
|
|
|
icon: 'none', |
|
|
@ -452,10 +455,12 @@ |
|
|
|
//计算支付价格 |
|
|
|
//计算支付价格 |
|
|
|
calculatepayPrice() { |
|
|
|
calculatepayPrice() { |
|
|
|
if (this.deductionPrice == 0) { |
|
|
|
if (this.deductionPrice == 0) { |
|
|
|
this.payPrice = Math.abs(parseFloat(this.totalprice - (parseFloat(this.priceValue[1] / 100).toFixed(2))) |
|
|
|
this.payPrice = Math.abs(parseFloat(this.totalprice - (parseFloat(this.priceValue[1] / 100).toFixed( |
|
|
|
|
|
|
|
2))) |
|
|
|
.toFixed(2)); |
|
|
|
.toFixed(2)); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
this.payPrice = Math.abs(parseFloat(this.orderPrice - (parseFloat(this.priceValue[1] / 100).toFixed(2)) - this |
|
|
|
this.payPrice = Math.abs(parseFloat(this.orderPrice - (parseFloat(this.priceValue[1] / 100).toFixed( |
|
|
|
|
|
|
|
2)) - this |
|
|
|
.deductionPrice).toFixed(2)); |
|
|
|
.deductionPrice).toFixed(2)); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
@ -522,12 +527,14 @@ |
|
|
|
title: '工会卡余额不足', |
|
|
|
title: '工会卡余额不足', |
|
|
|
duration: 2000, |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
that.thirdCancelOrder(); |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
if (!that.user.isSetPayPwd) { |
|
|
|
if (!that.user.isSetPayPwd) { |
|
|
|
uni.navigateTo({ |
|
|
|
uni.navigateTo({ |
|
|
|
url: '../../pages/login/updatePas/updatePas' |
|
|
|
url: '../../pages/login/updatePas/updatePas' |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
that.thirdCancelOrder(); |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
if (!that.user.isSetHltCard) { |
|
|
|
if (!that.user.isSetHltCard) { |
|
|
@ -543,6 +550,7 @@ |
|
|
|
}, 1000) |
|
|
|
}, 1000) |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
that.thirdCancelOrder(); |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
that.$refs.paymentPassword.modalFun('show'); |
|
|
|
that.$refs.paymentPassword.modalFun('show'); |
|
|
@ -554,6 +562,17 @@ |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
//取消订单 |
|
|
|
|
|
|
|
thirdCancelOrder() { |
|
|
|
|
|
|
|
let params = { |
|
|
|
|
|
|
|
orderId: this.orderId, |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
thirdCancelOrder(params).then(res => { |
|
|
|
|
|
|
|
if (res.return_code == '000000') { |
|
|
|
|
|
|
|
this.orderId = ''; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}, |
|
|
|
submitHandle(e) { |
|
|
|
submitHandle(e) { |
|
|
|
uni.showLoading({ |
|
|
|
uni.showLoading({ |
|
|
|
title: '支付中...' |
|
|
|
title: '支付中...' |
|
|
@ -595,6 +614,7 @@ |
|
|
|
}) |
|
|
|
}) |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
this.thirdCancelOrder(); |
|
|
|
uni.showToast({ |
|
|
|
uni.showToast({ |
|
|
|
title: res.return_msg, |
|
|
|
title: res.return_msg, |
|
|
|
icon: 'none', |
|
|
|
icon: 'none', |
|
|
|