|
@@ -48,7 +48,7 @@
|
|
|
@click="showCreatedCardMethod = true"
|
|
|
></van-cell>
|
|
|
<div style="height: 10px"></div>
|
|
|
- <van-button type="primary" block @click="confirmAppointment">确认挂号</van-button>
|
|
|
+ <van-button type="primary" block @click="confirmAppointment" :disabled="disableGhBtn">确认挂号</van-button>
|
|
|
<van-dialog
|
|
|
v-model:show="showCreatedCardMethod"
|
|
|
title="请选择绑定方式"
|
|
@@ -112,16 +112,17 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
+ const disableGhBtn = ref(true)
|
|
|
onMounted(() => {
|
|
|
- getGhFee(data.appointment).then((res) => {
|
|
|
- data.appointment.fee = res.data
|
|
|
- if (res.message) {
|
|
|
- Dialog.alert({
|
|
|
- title: '提示',
|
|
|
- message: response.data.message,
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
+ getGhFee(data.appointment)
|
|
|
+ .then((res) => {
|
|
|
+ data.appointment.fee = res
|
|
|
+ disableGhBtn.value = false
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ data.appointment.fee = '获取失败'
|
|
|
+ disableGhBtn.value = true
|
|
|
+ })
|
|
|
})
|
|
|
return {
|
|
|
showCreatedCardMethod,
|
|
@@ -130,6 +131,7 @@ export default {
|
|
|
showAddCard,
|
|
|
addCardText,
|
|
|
confirmAppointment,
|
|
|
+ disableGhBtn,
|
|
|
}
|
|
|
},
|
|
|
}
|