From 8f2a2f9efb1a361d50d9fa78b5f687710bbd03c2 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期五, 08 三月 2024 18:30:15 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
admin/.env | 2 +-
admin/src/views/login.vue | 2 +-
admin/src/views/business/device.vue | 12 ++++++------
admin/src/components/common/CommonHeader.vue | 11 +++++++----
admin/public/index.html | 4 ++--
admin/vue.config.js | 2 +-
admin/src/router/index.js | 3 ++-
admin/src/store/index.js | 4 ++++
8 files changed, 24 insertions(+), 16 deletions(-)
diff --git a/admin/.env b/admin/.env
index 9b30518..69bdb2d 100644
--- a/admin/.env
+++ b/admin/.env
@@ -10,4 +10,4 @@
VUE_APP_API_PREFIX = '/admin_interface'
# 椤圭洰鍚嶇О
-VUE_APP_TITLE = '鍗庢櫉鍥尯'
+VUE_APP_TITLE = '鍗庢櫉鏅烘収鍥尯绯荤粺'
diff --git a/admin/public/index.html b/admin/public/index.html
index 552a722..7169097 100644
--- a/admin/public/index.html
+++ b/admin/public/index.html
@@ -5,11 +5,11 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
- <title>鍗庢櫉鍥尯</title>
+ <title>鍗庢櫉鏅烘収鍥尯绯荤粺</title>
</head>
<body>
<noscript>
- <strong>We're sorry but 璞嗙背璺宠烦 doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
+ <strong>We're sorry but 鍗庢櫉鏅烘収鍥尯绯荤粺 doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
diff --git a/admin/src/components/common/CommonHeader.vue b/admin/src/components/common/CommonHeader.vue
index 58ec6c6..17685f1 100644
--- a/admin/src/components/common/CommonHeader.vue
+++ b/admin/src/components/common/CommonHeader.vue
@@ -2,7 +2,7 @@
<div class="common-header">
<div class="header">
<div class="logo">
- <div> 鍗庢櫉鍥尯</div>
+ <div>{{title}}</div>
<!-- <div class="title-en">Diagnosis of Intelligent Manufacturing Integrated Service Platfrom</div> -->
</div>
<div class="user">
@@ -55,6 +55,7 @@
},
data () {
return {
+ title: process.env.VUE_APP_TITLE,
visible: {
// 淇敼瀵嗙爜
changePwd: false
@@ -104,7 +105,7 @@
}
},
methods: {
- ...mapMutations(['setUserInfo', 'switchCollapseMenu']),
+ ...mapMutations(['setUserInfo', 'switchCollapseMenu', 'clearUserInfo']),
// 淇敼瀵嗙爜
changePwd () {
this.visible.changePwd = true
@@ -148,8 +149,10 @@
logout () {
logout()
.then(() => {
- this.setUserInfo(null)
- this.$router.push({ name: 'login' })
+ this.clearUserInfo()
+ // window.location.href = process.env.VUE_APP_CONTEXT_PATH
+ // this.$router.push({ name: 'login' })
+ window.location.reload()
})
.catch(e => {
this.$tip.apiFailed(e)
diff --git a/admin/src/router/index.js b/admin/src/router/index.js
index a9d2ce8..abcd0d2 100644
--- a/admin/src/router/index.js
+++ b/admin/src/router/index.js
@@ -9,7 +9,8 @@
Vue.use(VueRouter)
const router = new VueRouter({
- base: process.env.VUE_APP_CONTEXT_PATH + (process.env.VUE_APP_ROUTER_MODE === 'hash' ? '#' : ''),
+ // + (process.env.VUE_APP_ROUTER_MODE === 'hash' ? '#' : '')
+ base: process.env.VUE_APP_CONTEXT_PATH,
mode: process.env.VUE_APP_ROUTER_MODE,
routes: [
// 鐧诲綍
diff --git a/admin/src/store/index.js b/admin/src/store/index.js
index d2f4f72..0782641 100644
--- a/admin/src/store/index.js
+++ b/admin/src/store/index.js
@@ -38,6 +38,10 @@
}
},
+ clearUserInfo: (state) => {
+ state.userInfo = null
+ },
+
// 璁剧疆棣栭〉璺敱淇℃伅
setHomePage (state, homePage) {
state.homePage = homePage
diff --git a/admin/src/views/business/device.vue b/admin/src/views/business/device.vue
index cd26382..097b646 100644
--- a/admin/src/views/business/device.vue
+++ b/admin/src/views/business/device.vue
@@ -23,12 +23,12 @@
:data="tableData.list"
stripe
>
- <el-table-column prop="name" label="璁惧鍚嶇О" min-width="100px"></el-table-column>
- <el-table-column prop="doorName" label="闂ㄧ鐐瑰悕绉�" min-width="100px"></el-table-column>
- <el-table-column prop="regionPathName" label="鍖哄煙鍚嶇О" min-width="100px"></el-table-column>
- <el-table-column prop="doorNo" label="闂ㄧ鐐圭紪鍙�" min-width="100px"></el-table-column>
- <el-table-column prop="manufature" label="鍘傚晢" min-width="100px"></el-table-column>
- <el-table-column prop="no" label="璁惧鍙�" min-width="100px"></el-table-column>
+ <el-table-column prop="name" label="璁惧鍚嶇О"></el-table-column>
+ <el-table-column prop="doorName" label="闂ㄧ鐐瑰悕绉�"></el-table-column>
+ <el-table-column prop="regionPathName" label="鍖哄煙鍚嶇О"></el-table-column>
+ <el-table-column prop="doorNo" label="闂ㄧ鐐圭紪鍙�"></el-table-column>
+ <el-table-column prop="manufature" label="鍘傚晢"></el-table-column>
+ <el-table-column prop="no" label="璁惧鍙�"></el-table-column>
<!-- <el-table-column-->
<!-- v-if="containPermissions(['business:device:update'])"-->
<!-- label="鎿嶄綔"-->
diff --git a/admin/src/views/login.vue b/admin/src/views/login.vue
index fb5c195..c343084 100644
--- a/admin/src/views/login.vue
+++ b/admin/src/views/login.vue
@@ -59,7 +59,7 @@
uuid: this.captcha.uuid
})
.then(() => {
- // window.location.href = process.env.VUE_APP_CONTEXT_PATH
+ // window.location.href = process.env.VUE_APP_CONTEXT_PATH
window.location.reload()
})
.catch(e => {
diff --git a/admin/vue.config.js b/admin/vue.config.js
index 190271f..3635cab 100644
--- a/admin/vue.config.js
+++ b/admin/vue.config.js
@@ -19,7 +19,7 @@
// http://10.10.99.63/admin_interface/ 鏈�鏂版祴璇曟湇锛堝唴缃戯級
// http://218.23.218.228:8018/admin_interface 鏈�鏂版祴璇曟湇锛堝缃戯級
// target: 'http://218.23.218.228:8018/admin_interface',
- target: 'http://localhost:10028',
+ target: 'http://218.23.218.228:8018/admin_interface',
changeOrigin: true,
pathRewrite: {
[`^${[process.env.VUE_APP_API_PREFIX]}`]: ''
--
Gitblit v1.9.3