mirror of
https://gitee.com/js-yhsec/energy_storage.git
synced 2026-05-27 18:59:26 +08:00
系统总览布局,场站运行模式
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import axios from 'axios'
|
||||
import openNotification from '../utils/notification'
|
||||
// import { message } from 'ant-design-vue'
|
||||
|
||||
import router from 'vue-router'
|
||||
const service = axios.create({
|
||||
baseURL: '/api',
|
||||
timeout: 120000
|
||||
@@ -17,13 +17,14 @@ service.interceptors.response.use(
|
||||
const res = response.data
|
||||
|
||||
if (res.errCode !== 0) {
|
||||
console.log(res, 'res')
|
||||
if ((res.ERR_TOKEN = 2 || res.errmsg == '校验token过期')) {
|
||||
setTimeout(() => {
|
||||
// router.push({ path: '/login' })
|
||||
}, 1000)
|
||||
} else {
|
||||
console.log(res.errmsg, 'res.errmsg')
|
||||
message.error(res.errmsg)
|
||||
// message.error(res.errmsg)
|
||||
// openNotification({
|
||||
// status: 'error',
|
||||
// desc: res.tip
|
||||
|
||||
Reference in New Issue
Block a user