From 9d632cab9edfbddebac035d5b3400a9620d3793b Mon Sep 17 00:00:00 2001
From: liugongyu <290219706@qq.com>
Date: Tue, 20 Sep 2022 14:57:41 +0800
Subject: [PATCH] 购买卡券接口添加plNo参数
---
common/common.js | 2 +-
pages/businessCard/provideCard.vue | 21 ++++++++++++++++++++-
pages/index/index.vue | 2 +-
pages/parkPay/parkPay.vue | 568 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
4 files changed, 314 insertions(+), 279 deletions(-)
diff --git a/common/common.js b/common/common.js
index e2c4620..14f44a8 100644
--- a/common/common.js
+++ b/common/common.js
@@ -1,7 +1,7 @@
import md5 from './md5.min.js';
// 江阴正式环境
var serverUrl = "https://bus.jycrtc.com";
-// 测试 http://test.jycrtc.com:8096 正式 https://bus.jycrtc.com
+// 测试 http://221.228.70.87:8096 正式 https://bus.jycrtc.com
var serverPayUrl = ''
// 测试环境
// var serverUrl = "http://test.jycrtc.com:8096";
diff --git a/pages/businessCard/provideCard.vue b/pages/businessCard/provideCard.vue
index 46bb463..3e0beb9 100644
--- a/pages/businessCard/provideCard.vue
+++ b/pages/businessCard/provideCard.vue
@@ -65,15 +65,34 @@ export default {
this.getCouponDynamicQR()
that.timer = setInterval(() => {
// 业务逻辑
- console.log('11')
+ console.log(that.dateFormat(Date.parse(new Date())))
that.getCouponDynamicQR() //调用二维码方法
}, 60000)
},
+ onUnload() {
+ if(this.timer) {
+ clearTimeout(this.timer);
+ this.timer = null;
+ }
+ },
onShow() {
var me = this;
},
computed: {},
methods: {
+ dateFormat(time) {
+ let date = new Date(time);
+ let year = date.getFullYear();
+ // 在日期格式中,月份是从0开始的,因此要加0,使用三元表达式在小于10的前面加0,以达到格式统一 如 09:11:05
+ let month = date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1;
+ let day = date.getDate() < 10 ? "0" + date.getDate() : date.getDate();
+ let hours = date.getHours() < 10 ? "0" + date.getHours() : date.getHours();
+ let minutes = date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
+ let seconds = date.getSeconds() < 10 ? "0" + date.getSeconds() : date.getSeconds();
+ // 拼接
+ return year + "年" + month + "月" + day + "日" + hours + ":" + minutes + ":" + seconds;
+ // return year + "-" + month + "-" + day;
+ },
getCouponDynamicQR() {
let that = this
let paramsData = {
diff --git a/pages/index/index.vue b/pages/index/index.vue
index d66555a..065ee6a 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -21,7 +21,7 @@
diff --git a/pages/parkPay/parkPay.vue b/pages/parkPay/parkPay.vue
index 67b256b..5359894 100644
--- a/pages/parkPay/parkPay.vue
+++ b/pages/parkPay/parkPay.vue
@@ -1,311 +1,327 @@
-
+
-
-
- 订单详情
-
-
- 车牌号:{{mycarNumber | tranNull}}
-
-
-
- 停车场:{{parkName | tranNull}}
-
-
-
- 进场时间:{{parkInTime | tranNull}}
-
-
-
- 停车时间:{{staytime | timeFormatter}}
-
-
-
- 总计费用:{{due |toFixed2}}元
-
-
+
+ 订单详情
+
+
+ 车牌号:{{mycarNumber | tranNull}}
+
+
+
+ 停车场:{{parkName | tranNull}}
+
+
+
+ 进场时间:{{parkInTime | tranNull}}
+
+
+
+ 停车时间:{{staytime | timeFormatter}}
+
+
+
+ 总计费用:{{due |toFixed2}}元
+
+
-
-
- 需支付金额
-
-
-
- {{orderFee | toFixed2}}
-
-
- 元
-
-
-
-
-
+
+
+ 需支付金额
+
+
+
+ {{orderFee | toFixed2}}
+
+
+ 元
+
+
+
+
+
-
- 支付方法
-
-
+
+ 支付方法
+
+
-
-
-
- 商户余额
-
-
+
+
+
+ 商户余额
+
+
-
+
-
-
+
+
-
+
--
libgit2 0.21.4