<template>
    <div class="all">
        <!-- 头部区域上-->
    <div class="head">
        <div class="logo">AI升学测评分析平台</div>
        <div class="headRight">
            <i class="ico"></i> |
            <span class="photo"></span>
            <span class="name">你好</span> |
            <a href="#" class="logout" @click="logout" >退出</a>
        </div>
        </div>
        <!-- 头部菜单栏 -->
        <div class="headf">
           <el-menu  mode="horizontal" >
        <el-submenu index="1">
            <template slot="title">
              <i class="el-icon-menu"></i>
              <span>基础信息</span>
            </template>
             <el-menu-item-group>
              <el-menu-item index="1-1" @click='clickStu' >学生管理</el-menu-item>
              <el-menu-item index="1-2" @click='clickTea'>教师管理</el-menu-item>
            </el-menu-item-group>
        </el-submenu>
        <el-submenu index="2">
            <template slot="title">
              <i class="el-icon-menu"></i>
              <span @click='clickPage'>试题库</span>
            </template>
             <el-menu-item-group>
            
            </el-menu-item-group>
        </el-submenu>
        <el-submenu index="3">
            <template slot="title">
              <i class="el-icon-menu"></i>
              <span @click='clickWork'>作业管理</span>
            </template>
             <el-menu-item-group>
                
            </el-menu-item-group>
        </el-submenu>
        <el-submenu index="4">
            <template slot="title">
              <i class="el-icon-menu"></i>
              <span>学情报告</span>
            </template>
             <el-menu-item-group>
                 <el-menu-item index="1-2" @click='clickRep'>学情分析</el-menu-item>
            </el-menu-item-group>
        </el-submenu>
           </el-menu>
        </div>

        <!-- 视图体区 -->
       
        <el-card class="con">
            <router-view></router-view>
        </el-card>
        <div class="footer"><p>copyright@2013-2019 All Right</p></div>
       
    </div>
</template>
<script>
export default {
    data(){
       return {

       }
    },
    methods:{
        logout(){
            this.$router.push('/login')
        },
        clickTea(){
            this.$router.push('/teacher')
        },
        clickStu(){
            this.$router.push('/student')
        },
        clickRep(){
            this.$router.push('/report')
        },
        clickWork(){
            this.$router.push('/homework')
        },
        clickPage(){
            this.$router.push('/shiti')
        }
    }
}
</script>
<style scoped>

.head {
    overflow: hidden;
    width: 100%;
    height: 68px;
    background-color: #529BFF;
    line-height: 68px;
    color: #fff;
}
.logo {
    font-size:16px;
    float: left;
    width: 20%;
    line-height:40px;
    font-weight: 900;
    height: 40px;
    /* background-color: pink; */
    margin-left: 10px;
   margin-top: 15px;
}

.headRight {
    float: right;
font-size: 12px;

}
.ico {
    display: inline-block;
    vertical-align: middle;
    width: 16px;
    height: 16px;
    background-color: pink;
    
}
.photo {
     display: inline-block;
     vertical-align: middle;
    width: 42px;
    height: 42px;
    background-color: pink;
    margin: 0 5px;
    border-radius: 50%;
}
.logout {
    color: #fff;
    margin-right: 15px;
}
.headf {
    overflow: hidden;
    height: 52px;
    width: 100%;
    background-color: #fff;
    position: relative;
    z-index: 999;
   
   
}
 .el-menu {
    position: absolute;
    left: 50%;
    top: 0;
    transform: translateX(-50%)
 }    
 .el-menu-item {
     margin-right: 20px!important;
 } 
.el-menu--horizontal>.el-menu-item{
    height: 52px;
    line-height: 52px;
}
/* 主体区 */

.con{
    margin:15px auto 0;
    width: 1200px;
    min-width: 800px;
    height: 100%;
    background-color: #fff;
    
}
.all {
 position: relative;
}
.footer {
    color: #B1B9CF;
   position:fixed ;
  bottom: -8px;;
   left: 50%;
   transform: translateX(-50%);
   z-index:-999;

}


</style>