mirror of
https://gitlab.com/omair-personal/exchange.git
synced 2026-08-20 13:04:33 +00:00
b622d81d94
fixed some variable duplication added getcalculationvalue function
12 lines
258 B
JavaScript
12 lines
258 B
JavaScript
import store from '~/store'
|
|
|
|
export default async (to, from, next) => {
|
|
if (!store.getters['auth/check']) {
|
|
next({ name: 'login' })
|
|
} else if (store.getters['auth/user'].role == 'admin') {
|
|
next({ name: 'admin.home' })
|
|
} else {
|
|
next()
|
|
}
|
|
}
|