import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
import Table from './views/nav1/Table.vue'
import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import Page4 from './views/nav2/Page4.vue'
import Page5 from './views/nav2/Page5.vue'
import Page6 from './views/nav3/Page6.vue'
import echarts from './views/charts/echarts.vue'

let routes = [

    // 登录界面
    {
        path: '/login',
        component: Login,
        name: '',
        hidden: true
    },

    // 提示404界面
    {
        path: '/404',
        component: NotFound,
        name: '',
        hidden: true
    },

    // 面板页面
    {
        path: '/',
        component: Home,
        name: '',
        iconCls: 'el-icon-setting',
        leaf: true,//只有一个节点
        children: [
            { path: '/user_setting', component: Table, name: 'User Settings' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '功能页一',
        iconCls: 'el-icon-message',//图标样式class
        children: [
            // { path: '/table', component: Table, name: 'Table' },
            { path: '/form', component: Page6, name: '页面3' },
            { path: '/user', component: Page6, name: '页面4' },
        ]
    },
    {
        path: '/',
        component: Home,
        name: '功能页二',
        iconCls: 'el-icon-star-off',
        children: [
            { path: '/page4', component: Page6, name: '页面4' },
            { path: '/page5', component: Page6, name: '页面5' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '图表',
        iconCls: 'el-icon-picture',
        children: [
            { path: '/Page6', component: Page6, name: '页面6' }
        ]
    },

    // 找不到的时候，提示404页面
    {
        path: '*',
        hidden: true,
        redirect: { path: '/404' }
    }
];

export default routes;