From 558dcc7a2a0f739ee178436728161d54c1fd365d Mon Sep 17 00:00:00 2001
From: kongdeqiang <123456>
Date: 星期四, 22 十二月 2022 13:46:33 +0800
Subject: [PATCH] 修改前端页面
---
vue.config.js | 5 +++--
package-lock.json | 6 ++++++
src/components/page/Index2.vue | 30 +++++++++++++++++++++++++++---
src/main.js | 2 +-
4 files changed, 37 insertions(+), 6 deletions(-)
diff --git a/package-lock.json b/package-lock.json
index f47c07b..5408ad3 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -7862,6 +7862,12 @@
"invert-kv": "^1.0.0"
}
},
+ "lib-flexible": {
+ "version": "0.3.2",
+ "resolved": "https://mirrors.cloud.tencent.com/npm/lib-flexible/-/lib-flexible-0.3.2.tgz",
+ "integrity": "sha1-BvWnSDIxSi01wSA5vJw8otrqpCY=",
+ "dev": true
+ },
"lighthouse-logger": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/lighthouse-logger/-/lighthouse-logger-1.2.0.tgz",
diff --git a/src/components/page/Index2.vue b/src/components/page/Index2.vue
index fa4cf23..953f13f 100644
--- a/src/components/page/Index2.vue
+++ b/src/components/page/Index2.vue
@@ -81,7 +81,9 @@
//this.outParkId = cs.code;
this.code2 = cs.code;
this.$byutil.postData(this, this.$systemconfig.basePath + '/outPark/findByBarrierCode', {code:cs.code}, res => {
- this.statisticData = res.obj;
+ this.statisticData = res.data;
+ this.statisticData.enterTime = this.dateFormat('yyyy-MM-dd HH:mm:ss',this.statisticData.enterTime)
+ this.statisticData.createTime = this.dateFormat('yyyy-MM-dd HH:mm:ss',this.statisticData.createTime)
this.outParkId = this.statisticData.id;
this.status3 = this.statisticData.status3;
if(this.status3==1){
@@ -109,7 +111,7 @@
type: 'success',
duration:10000,
});
- setTimeout(function(){window.location.href = res.obj;},10000);
+ setTimeout(function(){window.location.href = res.data.obj;},10000);
this.showFlag = false;
})
},
@@ -117,7 +119,7 @@
if(this.carNo){
this.$byutil.postData(this, this.$systemconfig.basePath + '/outPark/outPark2', {code2:this.code2,carNo:this.carNo}, res => {
if(res.success){
- this.outParkId = res.obj.id;
+ this.outParkId = res.data.id;
this.pay();
this.showFlag = false;
}else{
@@ -135,7 +137,29 @@
});
}
+ },
+ dateFormat(fmt, date) {
+ let ret
+ const opt = {
+ 'y+': date.getFullYear().toString(), // 骞�
+ 'M+': (date.getMonth() + 1).toString(), // 鏈�
+ 'd+': date.getDate().toString(), // 鏃�
+ 'H+': date.getHours().toString(), // 鏃�
+ 'm+': date.getMinutes().toString(), // 鍒�
+ 's+': date.getSeconds().toString(), // 绉�
+ // 鏈夊叾浠栨牸寮忓寲瀛楃闇�姹傚彲浠ョ户缁坊鍔狅紝蹇呴』杞寲鎴愬瓧绗︿覆
}
+ for (let k in opt) {
+ ret = new RegExp('(' + k + ')').exec(fmt)
+ if (ret) {
+ fmt = fmt.replace(
+ ret[1],
+ ret[1].length == 1 ? opt[k] : opt[k].padStart(ret[1].length, '0')
+ )
+ }
+ }
+ return fmt
+ },
}
}
diff --git a/src/main.js b/src/main.js
index 18a59d1..ebd343b 100644
--- a/src/main.js
+++ b/src/main.js
@@ -44,7 +44,7 @@
Vue.prototype.$systemconfig = {
// 鏈嶅姟绔矾寰�
basePath: 'http://183.196.93.178:8089',
- //basePath:'http://localhost:8088'
+ //basePath:'http://127.0.0.1:8089'
}
Vue.prototype.$byutil = byUtils
Vue.prototype.$stringUtil = StringUtil
diff --git a/vue.config.js b/vue.config.js
index 419778d..5921df5 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -5,7 +5,8 @@
devServer: {
proxy: {
'/api':{
- target:'http://192.168.0.146',
+ target:'http://183.196.93.178',
+ //target:'http://127.0.0.1',
changeOrigin:true,
pathRewrite:{
'/api':''
@@ -13,4 +14,4 @@
}
}
}
-}
\ No newline at end of file
+}
--
Gitblit v1.9.1