<template>
  <div class='studentDetail'>
    <el-form :inline="true">
      <el-form-item label="学生姓名">
        <el-input disabled
                  :value="studentForm.username"></el-input>
      </el-form-item>
      <el-form-item label="学生性别">
        <el-input :value="studentForm.gender ? '男':'女'"
                  disabled></el-input>
      </el-form-item>
      <el-form-item label="出生年月">
        <el-input :value="studentForm.birthdate"
                  disabled></el-input>
      </el-form-item>
      <el-form-item label="家长姓名">
        <el-input :value="studentForm.realName"
                  disabled></el-input>
      </el-form-item>
      <el-form-item label="联系电话">
        <el-input :value="studentForm.parentsPhone"
                  disabled></el-input>
      </el-form-item>
      <!-- <el-form-item label="所在学校">
        <el-input :value=""
                  disabled></el-input>
      </el-form-item> -->
      <!-- <el-form-item label="所属分部">
        <el-input :value="1"
                  disabled></el-input>
      </el-form-item> -->
      <el-form-item label="年级班级">
        <el-input :value="studentForm.currentGrade + studentForm.currentClass"
                  disabled></el-input>
      </el-form-item>
    </el-form>
    <!-- <div class="teamList">
      <h4>乐团1</h4>
      <el-form :inline="true">
        <el-form-item label="入团日期">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="所在乐团">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="报名声部">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="乐团状态">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="乐器来源">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="所选乐器">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
        <el-form-item label="XX价格">
          <el-input value="2019-09-26"></el-input>
        </el-form-item>
      </el-form>
    </div> -->
  </div>
</template>
<script>
import { findStudentBaseInfo, findStudentMusicGroups } from '@/api/studentManager'
export default {
  name: 'studentInfo',
  data () {
    return {
      userId: null,
      studentForm: {},
      musicGroupInfo: [] // 乐团信息
    }
  },
  mounted () {
    this.__init()
  },
  methods: {
    __init () {
      this.userId = this.$route.query.userId
      findStudentBaseInfo({ userId: this.userId }).then(res => {
        if (res.code == 200) {
          this.studentForm = res.data
        }
      })
      // findStudentMusicGroups(this.userId).then(res => {
      //   if(res.code == 200) {
      //     this.musicGroupInfo.push(...res.data)
      //   }
      // })
    }
  }
}
</script>
<style lang="scss" scope>
.studentDetail {
  .teamList {
    margin-top: 20px;
    h4 {
      margin-bottom: 20px;
    }
  }
}
</style>
