|
|
@@ -249,16 +249,20 @@ async function goPay() {
|
|
|
title: t('orderDetail.payment.loading'),
|
|
|
mask: true,
|
|
|
})
|
|
|
- const payRes = await payOrder({
|
|
|
- orderId: detail.value?.orderId,
|
|
|
- type: detail.value?.storePink?.kId ? 'join' : 'open',
|
|
|
- })
|
|
|
- console.log(payRes)
|
|
|
- if (payRes.code === '200') {
|
|
|
- toast.success(t('orderDetail.payment.success'))
|
|
|
- getDetail()
|
|
|
+ try {
|
|
|
+ const payRes = await payOrder({
|
|
|
+ orderId: detail.value?.orderId,
|
|
|
+ type: detail.value?.storePink?.kId ? 'join' : 'open',
|
|
|
+ })
|
|
|
+ console.log(payRes)
|
|
|
+ if (payRes.code === '200') {
|
|
|
+ toast.success(t('orderDetail.payment.success'))
|
|
|
+ getDetail()
|
|
|
+ }
|
|
|
+ }
|
|
|
+ finally {
|
|
|
+ uni.hideLoading()
|
|
|
}
|
|
|
- uni.hideLoading()
|
|
|
}
|
|
|
|
|
|
function handleClick() {
|