Parcourir la source

停车缴费快捷支付跳转

tianhui il y a 3 ans
Parent
commit
8425af1038
4 fichiers modifiés avec 48 ajouts et 4 suppressions
  1. 10 1
      pages.json
  2. 0 1
      pages/index/index.vue
  3. 23 0
      pages/payLists/pay.vue
  4. 15 2
      pages/payLists/payLists.vue

+ 10 - 1
pages.json

@@ -133,7 +133,16 @@
                 "navigationBarTextStyle": "white"
                 "navigationBarTextStyle": "white"
             }
             }
             
             
-        }
+        },
+		{
+		    "path" : "pages/payLists/pay",
+		    "style" :                                                                                    
+		    {
+		        "navigationStyle":"custom",// 隐藏系统导航栏
+		        "navigationBarTitleText":"支付"
+		    }
+		    
+		}
     ],
     ],
 	"globalStyle": {
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
 		"navigationBarTextStyle": "black",

+ 0 - 1
pages/index/index.vue

@@ -74,7 +74,6 @@
 								<span class="pending-order-body-left-label">停车费用:</span>
 								<span class="pending-order-body-left-label">停车费用:</span>
 								<span>
 								<span>
 									<span class="number">¥{{item.payAmount}}</span>
 									<span class="number">¥{{item.payAmount}}</span>
-									元
 								</span>
 								</span>
 							</view>
 							</view>
 						</view>
 						</view>

Fichier diff supprimé car celui-ci est trop grand
+ 23 - 0
pages/payLists/pay.vue


+ 15 - 2
pages/payLists/payLists.vue

@@ -39,6 +39,7 @@
 		mixins: [MescrollMixin], // 使用mixin
 		mixins: [MescrollMixin], // 使用mixin
 		data() {
 		data() {
 			return {
 			return {
+				currentPayUrl: "",
 				payList: [],
 				payList: [],
 				list: [
 				list: [
 					{index:0,name: '未缴费',orderStatu:3,pageNum:1,total:null}
 					{index:0,name: '未缴费',orderStatu:3,pageNum:1,total:null}
@@ -130,11 +131,23 @@
 						this.orderList.push(item.orderId)
 						this.orderList.push(item.orderId)
 					}
 					}
 				});
 				});
-				console.log(this.orderList)
 				
 				
 				this.$u.api.payGzbank({orderList: this.orderList}).then(res=>{
 				this.$u.api.payGzbank({orderList: this.orderList}).then(res=>{
 					let payUrl = res.data.url;
 					let payUrl = res.data.url;
-					window.open(payUrl);
+					this.currentPayUrl=res.data.url;
+					
+					// uni.navigateTo({
+					//     url: '/pages/payLists/pay',
+					// 	fail:function(err){
+					// 		console.log('err',err)
+					// 	}
+					// });
+					this.$u.route({
+						url: 'pages/payLists/pay',
+						params: {
+							currentPayUrl: res.data.url
+						}
+					});
 				}).catch(err=>{
 				}).catch(err=>{
 					this.$refs.uToast.show({
 					this.$refs.uToast.show({
 						title: err.msg,
 						title: err.msg,