|
@@ -1,6 +1,5 @@
|
|
|
<template>
|
|
|
<div style="background-color: #f4f7ff">
|
|
|
- <!-- <LoginDom></LoginDom>-->
|
|
|
<scroll-view class="wrap-box">
|
|
|
<div class="parkingFee" ref="parkingFee">
|
|
|
<div class="parkingFee-top bg">
|
|
@@ -214,15 +213,10 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-// import authorize from '../../components/authorize/authorize.vue';
|
|
|
import plateNumber from '../../components/plate-number/plateNumber.vue';
|
|
|
import { REG_SOURCE } from '@/constants';
|
|
|
import LoginDom from '@/components/Login/Login.vue';
|
|
|
import { mapState } from 'vuex';
|
|
|
-import MemberCacheTool from '../../utils/member-cache-tool.js';
|
|
|
-import { Decrypt, Encrypt } from '@/utils/crypto.js';
|
|
|
-// import ws from '@/utils/websocket';
|
|
|
-// const app = getApp()
|
|
|
const app = {
|
|
|
globalData: {
|
|
|
regSource: '',
|
|
@@ -232,7 +226,6 @@ import uni from '../../utils/uniHooks';
|
|
|
|
|
|
export default {
|
|
|
components: {
|
|
|
- // authorize,
|
|
|
plateNumber,
|
|
|
LoginDom,
|
|
|
},
|
|
@@ -277,24 +270,8 @@ export default {
|
|
|
member: (state) => state.member,
|
|
|
mobile: (state) => state.mobile,
|
|
|
}),
|
|
|
- /* groupId: (state) => state.groupId,
|
|
|
- openid: (state) => state.openid,
|
|
|
- mallId: (state) => state.mallId,
|
|
|
- kipUserId: (state) => state.kipUserId,
|
|
|
- userInfo: (state) => state.userInfo,
|
|
|
- member: (state) => state.member, */
|
|
|
},
|
|
|
- // beforeRouteLeave(to, from, next) {
|
|
|
- // // 设置下一个路由的 meta
|
|
|
- // to.meta.keepAlive = false; // 让 A 缓存,即不刷新
|
|
|
- // next();
|
|
|
- // },
|
|
|
beforeRouteLeave(to, from, next) {
|
|
|
- // 设置下一个路由的 meta
|
|
|
- // if (/index|home/.test(to.name)) {
|
|
|
- // // 不在缓存列表中,从cachedViews缓存列表中移除
|
|
|
- // this.$store.commit('cachedViews/DEL_CACHED_VIEW', from);
|
|
|
- // }
|
|
|
this.$store.commit('cachedViews/DEL_CACHED_VIEW', to);
|
|
|
next();
|
|
|
},
|
|
@@ -316,10 +293,7 @@ export default {
|
|
|
title: '停车缴费',
|
|
|
});
|
|
|
}, 300);
|
|
|
- // console.log(286, this.openid);
|
|
|
- // this.getParkInfo();
|
|
|
if (this.openid) {
|
|
|
- // this.openId = this.openid;
|
|
|
this.getParkInfo();
|
|
|
this.showSq = false;
|
|
|
} else {
|
|
@@ -331,14 +305,6 @@ export default {
|
|
|
if (this.options?.tpName) {
|
|
|
app.globalData.tpName = this.options?.tpName;
|
|
|
}
|
|
|
- /*this.$refs.authorize.login('/pages/parkingFee/parkingFee', () => {
|
|
|
- const openId =
|
|
|
- uni.getStorageSync('openId') ||
|
|
|
- uni.getStorageSync('member').openid ||
|
|
|
- app.globalData.openId;
|
|
|
- _this.openId = openId;
|
|
|
- _this.getParkInfo();
|
|
|
- });*/
|
|
|
this.showSq = true;
|
|
|
}
|
|
|
},
|
|
@@ -362,15 +328,15 @@ export default {
|
|
|
// app.globalData.isNewMember = '';
|
|
|
// 场景二维码记录(是否扫码进入)
|
|
|
// app.globalData.paramsScene = {};
|
|
|
- ths.$saveSceneQrcodeDetail(
|
|
|
- 'page',
|
|
|
- 'parkingFee',
|
|
|
- '停车缴费',
|
|
|
- '',
|
|
|
- '',
|
|
|
- '',
|
|
|
- ''
|
|
|
- );
|
|
|
+ // this.$saveSceneQrcodeDetail(
|
|
|
+ // 'page',
|
|
|
+ // 'parkingFee',
|
|
|
+ // '停车缴费',
|
|
|
+ // '',
|
|
|
+ // '',
|
|
|
+ // '',
|
|
|
+ // ''
|
|
|
+ // );
|
|
|
}
|
|
|
// 埋点本地化
|
|
|
this.preUrl = uni.getStorageSync('previousUrl');
|
|
@@ -426,11 +392,9 @@ export default {
|
|
|
header: JSON.parse(uni.getStorageSync('handleUser')),
|
|
|
})
|
|
|
.then((res) => {
|
|
|
- uni.hideLoading();
|
|
|
if (res.data.code === 0) {
|
|
|
const data = res.data.data || {};
|
|
|
this.carList = data.carList;
|
|
|
- // this.carList = ['辽A98G89', '沪A98GHJ', '陕A98GHJ0', '沪A98GHJ0', '陕A98GHJ', '辽A98G89'];
|
|
|
this.parkInfoEntity = data.parkInfoEntity;
|
|
|
this.hourMoney =
|
|
|
parseFloat(this.parkInfoEntity.needmoney) /
|
|
@@ -449,7 +413,6 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
.catch((err) => {
|
|
|
- uni.hideLoading();
|
|
|
uni.showToast({
|
|
|
title: '网络超时请稍后再试',
|
|
|
duration: 2000,
|
|
@@ -544,10 +507,6 @@ export default {
|
|
|
// 查询车费信息
|
|
|
handleSearch(carno, clickEvent = '$ClickQueryAndPayment') {
|
|
|
this.vehicleNumber = carno;
|
|
|
- uni.showLoading({
|
|
|
- title: '加载中',
|
|
|
- });
|
|
|
-
|
|
|
const params = {
|
|
|
carno,
|
|
|
mallid: this.mallId,
|
|
@@ -581,11 +540,16 @@ export default {
|
|
|
data: params,
|
|
|
method: 'POST',
|
|
|
header: JSON.parse(uni.getStorageSync('handleUser')),
|
|
|
- timeout: 10000,
|
|
|
+ timeout: 60000 * 2, // 120S
|
|
|
+ showLoading: {
|
|
|
+ title: '加载中',
|
|
|
+ duration: 0,
|
|
|
+ },
|
|
|
})
|
|
|
.then((res) => {
|
|
|
// console.log(555555, res);
|
|
|
- uni.hideLoading();
|
|
|
+ // ToastObj.clear();
|
|
|
+ // uni.hideLoading();
|
|
|
if (res.data.code === 0) {
|
|
|
// 清理旧数据
|
|
|
this.parkingFeeDetailInit();
|
|
@@ -635,7 +599,7 @@ export default {
|
|
|
});
|
|
|
})
|
|
|
.catch((err) => {
|
|
|
- uni.hideLoading();
|
|
|
+ // uni.hideLoading();
|
|
|
uni.showToast({
|
|
|
title: '网络超时请稍后再试',
|
|
|
duration: 2000,
|
|
@@ -795,6 +759,7 @@ page {
|
|
|
flex-direction: column;
|
|
|
width: 100%;
|
|
|
font-size: 14px;
|
|
|
+
|
|
|
.parkingFee {
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
@@ -1187,6 +1152,7 @@ page {
|
|
|
|
|
|
.info {
|
|
|
// padding-left: 18px;
|
|
|
+ white-space: break-spaces;
|
|
|
font-size: 30px;
|
|
|
width: 100%;
|
|
|
color: #999999;
|