no message

This commit is contained in:
小陌 2023-07-29 20:58:35 +08:00
parent b9ffcd90de
commit 4a77da9283
5 changed files with 7 additions and 15 deletions

View File

@ -4,11 +4,5 @@ NODE_ENV = development
# 标题
VUE_APP_TITLE = Ansnid
# 接口地址
VUE_APP_API_BASEURL = https://www.fastmock.site/mock/5039c4361c39a7e3252c5b55971f1bd3/api
# 本地端口
VUE_APP_PORT = 2800
# 是否开启代理
VUE_APP_PROXY = false
VUE_APP_PORT = 2800

View File

@ -2,7 +2,4 @@
NODE_ENV = production
# 标题
VUE_APP_TITLE = Ansnid
# 接口地址
VUE_APP_API_BASEURL = https://www.fastmock.site/mock/5039c4361c39a7e3252c5b55971f1bd3/api
VUE_APP_TITLE = Ansnid

View File

@ -156,7 +156,7 @@
type: 'warning',
confirmButtonText: '退出',
confirmButtonClass: 'el-button--danger'
}).then(() => {
}).then(() => {
this.$router.replace({
path: '/login',
query: { redirect: this.$route.fullPath }

View File

@ -47,6 +47,8 @@ axios.interceptors.response.use(
message: error.response.data.message || "Status:500服务器发生错误"
});
} else if (error.response.status == 401) {
if (!MessageBox_401_show) {
MessageBox_401_show = true
ElMessageBox.confirm('当前用户已被登出或无权限访问当前资源,请尝试重新登录后再操作。', '无权限访问', {
@ -62,7 +64,7 @@ axios.interceptors.response.use(
router.replace({
path: '/login',
query: {
redirect: router.currentRoute.fullPath
redirect: router.currentRoute._value.fullPath
}
});
}).catch(() => {})

View File

@ -1,10 +1,9 @@
const {
defineConfig
} = require('@vue/cli-service')
module.exports = defineConfig({
//设置为空打包后不分更目录还是多级目录
publicPath: 'https://x--mo.com:8888/admin/',
publicPath: process.env.NODE_ENV === 'production' ? 'https://x--mo.com:8888/admin/' : './',
//build编译后存放静态文件的目录
assetsDir: "static",
// build编译后不生成资源MAP文件