mirror of
https://github.com/flipped-aurora/gin-vue-admin.git
synced 2026-09-23 13:03:07 +00:00
提出api中的model到单独model分组 修改dashboard 拼写错误
This commit is contained in:
@@ -18,7 +18,7 @@ router.beforeEach(async(to, from, next) => {
|
||||
// 在白名单中的判断情况
|
||||
if (whiteList.indexOf(to.name) > -1) {
|
||||
if (token) {
|
||||
next({ path: '/layout/dashbord' })
|
||||
next({ path: '/layout/dashboard' })
|
||||
} else {
|
||||
next()
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ export const user = {
|
||||
if (redirect) {
|
||||
router.push({ path: redirect })
|
||||
} else {
|
||||
router.push({ path: '/layout/dashbord' })
|
||||
router.push({ path: '/layout/dashboard' })
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
import { mapGetters } from 'vuex'
|
||||
import Animition from '@/view/dashboard/component/animition.vue'
|
||||
export default {
|
||||
name: 'Dashbord',
|
||||
name: 'Dashboard',
|
||||
data() {
|
||||
return {
|
||||
drawer: false
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="router-history">
|
||||
<el-tabs v-model="activeValue" type="card" :closable="!(historys.length==1&&this.$route.name=='dashbord')" @tab-click="changeTab" @tab-remove="removeTab">
|
||||
<el-tabs v-model="activeValue" type="card" :closable="!(historys.length==1&&this.$route.name=='dashboard')" @tab-click="changeTab" @tab-remove="removeTab">
|
||||
<el-tab-pane
|
||||
v-for="item in historys"
|
||||
:key="item.name"
|
||||
@@ -17,13 +17,13 @@ export default {
|
||||
data(){
|
||||
return{
|
||||
historys:[],
|
||||
activeValue:"dashbord"
|
||||
activeValue:"dashboard"
|
||||
}
|
||||
},
|
||||
created(){
|
||||
const initHistorys = [
|
||||
{
|
||||
name:"dashbord",
|
||||
name:"dashboard",
|
||||
meta:{
|
||||
title:"仪表盘"
|
||||
}
|
||||
@@ -49,7 +49,7 @@ export default {
|
||||
const index = this.historys.findIndex(item=>item.name == tab)
|
||||
if(this.$route.name == tab){
|
||||
if(this.historys.length==1){
|
||||
this.$router.push({name:"dashbord"})
|
||||
this.$router.push({name:"dashboard"})
|
||||
}else{
|
||||
if(index<this.historys.length-1){
|
||||
this.$router.push({name:this.historys[index+1].name})
|
||||
|
||||
Reference in New Issue
Block a user