From 51963550b2d517791403d54b8035426225a917e7 Mon Sep 17 00:00:00 2001
From: XiaoXinPro 14 IAH5R <568170040@qq.com>
Date: Thu, 29 Jun 2023 23:19:30 +0800
Subject: [PATCH] upload
---
config/config.js | 4 +
pages/Appointment/appointment.js | 25 ++++-
pages/Appointment/appointment.ttml | 14 ++-
pages/Appointment/appointment.ttss | 7 +-
pages/appointDetail/appointDetail.js | 149 ++++++++++++++++++++++++-
pages/appointDetail/appointDetail.ttml | 48 ++++++--
pages/appointDetail/appointDetail.ttss | 50 ++++++++-
7 files changed, 268 insertions(+), 29 deletions(-)
diff --git a/config/config.js b/config/config.js
index 08aa8dc..44164cd 100644
--- a/config/config.js
+++ b/config/config.js
@@ -137,6 +137,10 @@ let config = {
* 预约确认
*/
appointConfirm: "/api/wxCouponOrderReservation/updateStatus",
+ /**
+ * 预约确认
+ */
+ appointSetDate: "/api/wxCouponOrderReservation/update",
/**
* 获得openId
*/
diff --git a/pages/Appointment/appointment.js b/pages/Appointment/appointment.js
index a6247c0..4e4abb2 100644
--- a/pages/Appointment/appointment.js
+++ b/pages/Appointment/appointment.js
@@ -23,7 +23,7 @@ Page({
const that = this
const data = {
pageNum: this.data.pageNum,
- pageSize: 20,
+ pageSize: 200,
}
if (startTime && endTime) {
@@ -31,7 +31,7 @@ Page({
data.serchEndDate = endTime
}
- if (status) {
+ if (status || status === 0) {
data.status = status
}
@@ -44,7 +44,12 @@ Page({
res.data.list.forEach(item => {
const appointStart = util.timestampToTime(item.startDate, 'YYYY-MM-DD hh:mm:ss')
const appointEnd = util.timestampToTime(item.endDate, 'hh:mm:ss')
- item.appointTime = appointStart + ' - ' + appointEnd
+ if (item.startDate && item.endDate) {
+ item.appointTime = appointStart + ' - ' + appointEnd
+ } else {
+ item.appointTime = "暂无";
+ }
+
})
that.setData({
list: res.data.list,
@@ -64,11 +69,21 @@ Page({
},
setType(e) {
- const type = e.currentTarget.dataset.type * 1
+ const type = e.currentTarget.dataset.type
+
this.setData({
currentID: '',
})
- this.getList(type)
+
+ if (type === 'X') {
+ this.getList(false)
+ } else if (type === 'Y') {
+ this.getList(0)
+ } else {
+ this.getList(type * 1)
+ }
+
+
},
setStartTime(e) {
diff --git a/pages/Appointment/appointment.ttml b/pages/Appointment/appointment.ttml
index 683eff5..979bc28 100644
--- a/pages/Appointment/appointment.ttml
+++ b/pages/Appointment/appointment.ttml
@@ -12,8 +12,9 @@
- 全部
- 未确认
+ 全部
+ 待确认
+ 未预约
已确认
已完成
@@ -27,19 +28,20 @@
- 订单编号:{{ item.couponOrderId }}
- 未确认
+ 券码:{{ item.couponOrderId }}
+ 待确认
已取消
已退款
已确认
+ 未预约
已完成
已评价
商品名称:{{ item.couponTitle }}
用户手机号码:{{ item.userPhone }}
- 服务预约时间:
- {{ item.appointTime }}
+ 服务预约时间:暂无
+ {{ item.appointTime }}