From 23b5ff20a202e1bc3cc4d44e05f84ff713090de9 Mon Sep 17 00:00:00 2001 From: zpc Date: Mon, 29 Sep 2025 19:01:18 +0800 Subject: [PATCH] 321 --- components/com/index/ReservationPopup.vue | 11 ++--- components/com/page/qiandao-popup.vue | 1 - pages/appointment/appointment-page.vue | 59 +++++++++++++++++++---- 3 files changed, 55 insertions(+), 16 deletions(-) diff --git a/components/com/index/ReservationPopup.vue b/components/com/index/ReservationPopup.vue index 9895909..40c8a5f 100644 --- a/components/com/index/ReservationPopup.vue +++ b/components/com/index/ReservationPopup.vue @@ -105,12 +105,11 @@ style="height: 80rpx; flex: 3; background-color: #1989FA; border-radius: 10rpx; margin-left: 20rpx;"> 取消组局 - - 分享 - - + + - diff --git a/pages/appointment/appointment-page.vue b/pages/appointment/appointment-page.vue index 616abbf..b8c4718 100644 --- a/pages/appointment/appointment-page.vue +++ b/pages/appointment/appointment-page.vue @@ -101,7 +101,8 @@ 发起预约 - + + 组局成功后,发起者可通过店员领取线下红包 @@ -111,6 +112,32 @@ + + + + + + + 发起预约成功! + + + + + + 关闭 + + + + + + + @@ -137,6 +164,11 @@ import { forEach, union } from 'lodash'; +import { + + getDetail +} from '@/common/server/index' + import TimeSelectCell from '@/components/com/appointment/time-select-cell.vue' import LabelField from '@/components/com/appointment/label-field.vue' import LabelSlectField from '@/components/com/appointment/label-slect-field.vue' @@ -148,11 +180,12 @@ import { getReservationRoomList, addSQReservation, cancelReservation, canCreateSQReservation } from '@/common/server/interface/sq' const _containerBase = ref(null) +const submitPopupRef = ref(null) // 年龄选择器状态 const agePickerVisible = ref(false) const agePickerColumns = ref([[], []]) const agePickerDefaultIndex = ref([0, 0]) - +const reservationData = ref(null) const lineHeight = ref("15rpx") const timeRange = ref(["2小时", "3小时", "4小时", "自定义"]) const timeRangeValue = ref("") @@ -200,6 +233,9 @@ const onTimeRangeChange = async (val) => { const getRoomPickerName = () => { return reservationInfo.value.room_name; } +const tipsShow = () => { + submitPopupRef.value.open() +} const openUpDatesTimePicker = async (isManual = true) => { var now = reservationInfo.value.start_time * 1000; @@ -513,8 +549,6 @@ const submitReservation = async () => { return } - - var resPay = null; if (submitData.deposit_fee > 0) { resPay = await usePay(submitData.deposit_fee); @@ -561,12 +595,19 @@ const submitReservation = async () => { } console.log("payRes", payRes); } - // 提交成功 - uni.showToast({ - title: '预约提交成功', - icon: 'success' - }) + var share_id = result.data; + var detailData = await getDetail(share_id); + if (detailData != null) { + reservationData.value = detailData; + tipsShow(); + } else { + // 提交成功 + uni.showToast({ + title: '预约提交成功', + icon: 'success' + }) + } // 可以跳转到其他页面或重置表单 // uni.navigateBack() // 返回上一页 // 或者重置表单