Ver Fonte

opt:小程序创建的订单跳转至选择房间,pms预订单跳转至查询订单

Shu há 3 meses atrás
pai
commit
90acb388f4
1 ficheiros alterados com 52 adições e 22 exclusões
  1. 52 22
      subpkg_checkin/confirmOrder/confirmOrder.vue

+ 52 - 22
subpkg_checkin/confirmOrder/confirmOrder.vue

@@ -287,18 +287,33 @@
 				// console.log("获取预付号",alipayRes.data)
 				if (!alipayRes.data.success) {
 					console.log("获取预付号失败");
-					uni.showModal({
-						content: '房间已被占用,请重新选房',
-						showCancel: false,
-						success: (res) => {
-							if (res.confirm) {
-								uni.navigateTo({
-									url: '/subpkg_checkin/selectRoom/selectRoom?roomType=' +
-										this.order.roomType
-								})
+					//小程序创建的订单跳转至选择房间,pms预订单跳转至查询订单
+					if (this.order.orderSource === 'MINI_APP') {
+						uni.showModal({
+							content: '房间已被占用,请重新选房',
+							showCancel: false,
+							success: (res) => {
+								if (res.confirm) {
+									uni.navigateTo({
+										url: '/subpkg_checkin/selectRoom/selectRoom?roomType=' +
+											this.order.roomType
+									})
+								}
 							}
-						}
-					})
+						})
+					} else {
+						uni.showModal({
+							content: '订单不可用,请重新选择订单',
+							showCancel: false,
+							success: (res) => {
+								if (res.confirm) {
+									uni.navigateTo({
+										url: '/subpkg_checkin/queryOrder/queryOrder?'
+									})
+								}
+							}
+						})
+					}
 					return
 				}
 
@@ -351,18 +366,33 @@
 
 				if (!alipayRes.data.success) {
 					console.log("获取签名字符串失败");
-					uni.showModal({
-						content: '房间已被占用,请重新选房',
-						showCancel: false,
-						success: (res) => {
-							if (res.confirm) {
-								uni.navigateTo({
-									url: '/subpkg_checkin/selectRoom/selectRoom?roomType=' +
-										this.order.roomType
-								})
+					//小程序创建的订单跳转至选择房间,pms预订单跳转至查询订单
+					if (this.order.orderSource === 'MINI_APP') {
+						uni.showModal({
+							content: '房间已被占用,请重新选房',
+							showCancel: false,
+							success: (res) => {
+								if (res.confirm) {
+									uni.navigateTo({
+										url: '/subpkg_checkin/selectRoom/selectRoom?roomType=' +
+											this.order.roomType
+									})
+								}
 							}
-						}
-					})
+						})
+					} else {
+						uni.showModal({
+							content: '订单不可用,请重新选择订单',
+							showCancel: false,
+							success: (res) => {
+								if (res.confirm) {
+									uni.navigateTo({
+										url: '/subpkg_checkin/queryOrder/queryOrder?'
+									})
+								}
+							}
+						})
+					}
 					return
 				}