v3.7.0
This commit is contained in:
parent
56106b8203
commit
c94a94d9d8
12
ZR.Vue/.jsbeautifyrc
Normal file
12
ZR.Vue/.jsbeautifyrc
Normal file
@ -0,0 +1,12 @@
|
||||
{
|
||||
"brace_style": "none,preserve-inline",
|
||||
"indent_size": 2,
|
||||
"indent_char": " ",
|
||||
"jslint_happy": true,
|
||||
"unformatted": [
|
||||
""
|
||||
],
|
||||
"css": {
|
||||
"indent_size": 2
|
||||
}
|
||||
}
|
||||
@ -1,13 +1,9 @@
|
||||
import router from './router'
|
||||
import store from './store'
|
||||
import {
|
||||
Message
|
||||
} from 'element-ui'
|
||||
import { Message } from 'element-ui'
|
||||
import NProgress from 'nprogress'
|
||||
import 'nprogress/nprogress.css'
|
||||
import {
|
||||
getToken
|
||||
} from '@/utils/auth'
|
||||
import { getToken } from '@/utils/auth'
|
||||
|
||||
NProgress.configure({
|
||||
showSpinner: false
|
||||
@ -22,9 +18,7 @@ router.beforeEach((to, from, next) => {
|
||||
if (getToken()) {
|
||||
/* has token*/
|
||||
if (to.path === '/login') {
|
||||
next({
|
||||
path: '/'
|
||||
})
|
||||
next({ path: '/' })
|
||||
NProgress.done()
|
||||
} else {
|
||||
if (store.getters.roles.length === 0) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user