提出api中的model到单独model分组 修改dashboard 拼写错误

This commit is contained in:
QM303176530
2020-04-07 22:26:00 +08:00
parent 6864557df0
commit 5629ad968d
16 changed files with 106 additions and 85 deletions
+1 -1
View File
@@ -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()
}
+1 -1
View File
@@ -51,7 +51,7 @@ export const user = {
if (redirect) {
router.push({ path: redirect })
} else {
router.push({ path: '/layout/dashbord' })
router.push({ path: '/layout/dashboard' })
}
}
},
+1 -1
View File
@@ -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})