<template>
  <div class="credentials-container">
    <div class="clearfix">
      <el-card class="e-card">
        <p class="title">Diploma of the highest medical degree 最高医学学位毕业证书
        </p>
        <upload-file :doctor-id="doctorId" type="Diploma of the highest medical degree" />
<!--        <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_DiplomaOfTheHighestMedicalDegree_Template')">-->
<!--          <i class="el-icon-view el-icon-download"></i>-->
<!--          Template-->
<!--        </el-button>-->
      </el-card>

      <el-card class="e-card">
        <p class="title">Medical Qualification Certificate 医师资格证
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_MedicalQualificationCertificate_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Medical Qualification Certificate" />
      </el-card>

      <el-card class="e-card">
        <p class="title">Practice License 医师执业证
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_PracticeLicense_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Practice License" />
      </el-card>
    </div>
    <h6 style="line-height:30px;font-size:13px;">Modality Certificate 大型医用设备上岗证</h6>
    <div class="clearfix">
      <el-card class="e-card">
        <p class="title">CT
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_CT_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Modality Certificate(CT)" />
      </el-card>

      <el-card class="e-card">
        <p class="title">MRI
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_MRI_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Modality Certificate(MRI)" />
      </el-card>

      <el-card class="e-card">
        <p class="title">NM
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_NM_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Modality Certificate(NM)" />
      </el-card>

      <el-card class="e-card">
        <p class="title">US
<!--          <el-button size="mini" type="primary" style="position: absolute;bottom:10px;right: 10px;" @click="handleDownload('Reviewer_US_Template')">-->
<!--            <i class="el-icon-view el-icon-download"></i>-->
<!--            Template-->
<!--          </el-button>-->
        </p>
        <upload-file :doctor-id="doctorId" type="Modality Certificate(US)" />
      </el-card>
    </div>
  </div>
</template>
<script>
import UploadFile from '@/components/UploadFile'
import { DownloadCommonDoc } from '@/api/dictionary'
export default {
  components: {
    UploadFile
  },
  data() {
    return {
      doctorId: this.$route.query.Id
    }
  },
  methods: {
    handleDownload(code) {
      this.loading = true
      DownloadCommonDoc(code).then(data => {
        this.loading = false
      }).catch(() => { this.loading = false })
    }
  }
}
</script>
<style lang="scss">
.credentials-container{
  .e-card {
  width: 32.5%;
  height: 180px;
  font-size: 12px;
  position: relative;
  float: left;
  margin: 0px 10px 5px 0px;
  .title{
    font-size: 13px;
    margin-bottom: 15px;
    font-weight: bold;

    }
  }
  h6{
    margin:0;
  }
}
</style>
