<template>
  <div id="index">
    <el-row>
      <el-col :span="24" class="style">
        <el-col :span="24" class="top">
          <topInfo></topInfo>
        </el-col>
        <el-col :span="24" class="main">
          <classList
            :headNameList="headNameList"
            @assign="clickAssign"
            :assignShow="assignShow"
            :assignForm="assignForm"
            @outForm="outAssignShow"
            @onForm="onAssignShow"
          ></classList>
        </el-col>
        <el-col :span="24" class="foot">
          <footInfo></footInfo>
        </el-col>
      </el-col>
    </el-row>
  </div>
</template>

<script>
import topInfo from '@/layout/common/topInfo.vue';
import footInfo from '@/layout/common/footInfo.vue';
import classList from '@/layout/class/classList.vue';

export default {
  name: 'index',
  props: {},
  components: {
    topInfo, //头部导航
    footInfo, //底部导航
    classList, //班级名单
  },
  data: () => ({
    headNameList: [
      {
        name: '测试人员',
        job: '班长',
      },
      {
        name: '测试人',
        job: '',
      },
      {
        name: '测试人员',
        job: '班长',
      },
      {
        name: '测试人',
        job: '班长',
      },
    ],
    assignShow: false,
    assignForm: {},
  }),
  created() {},
  computed: {},
  methods: {
    clickAssign() {
      this.assignShow = true;
    },
    onAssignShow(assignForm) {
      console.log(assignForm);
      this.assignShow = false;
    },
    outAssignShow() {
      this.assignShow = false;
    },
  },
};
</script>

<style lang="less" scoped>
.style {
  width: 100%;
  min-height: 667px;
  position: relative;
  background-color: #f9fafc;
}
.top {
  height: 46px;
  overflow: hidden;
}
.main {
  min-height: 570px;
}
.foot {
  height: 50px;
  overflow: hidden;
}
</style>
