<template>
  <div>
    <div class="content-head">
      <dataBreadcrumb :breads="breads"></dataBreadcrumb>
      <h3>澄清确认函</h3>
      <h5>投标方向招标方发送澄清确认函</h5>
    </div>
    <div class="content flex-center">
      <div>
        <h3>这里显示招标方单位名称：</h3>
        <h5>我单位已收到贵公司发出的项目{{detail.projectName}}澄清标题为{{detail.title}}的澄清文件，特此回执</h5>
        <div class="flex">
			<h4 class='adjustment'><span>*</span>回执文件</h4>
			<div class="img">
				<div>{{detail.fileName}}</div>
				 <el-image 
				    style="width: 100px; height: 100px"
				    :src="detail.accessoryUrl" 
				    :preview-src-list="srcList">
				  </el-image>
			</div>
		</div>
        <div class="flex-center" style="margin-top:100px">
          <el-button @click="back">返回</el-button>
        </div>	
      </div>
    </div>
  </div>
</template>

<script>
import {
	 confirmation
} from '@api/purchaser/bid'
import dataBreadcrumb from '@components/dataBreadcrumb.vue'
export default {
  components: {
    dataBreadcrumb
  },
  data() {
    return {
		srcList:[],
		detail:{},
      confirmationId:"" ,
      breads: ['招标管理', '招标项目管理', '工作台']
    }
  },
  created() {
	  let confirmId=this.$route.query.confirmId;
    this.getconfirmationId(confirmId)
  },
  methods: {
    back() {
      this.$router.go(-1)
    },
    // 获取确认函
    async getconfirmationId(confirmId) {
      try {
        const {
          code,
          data
        } = await confirmation(confirmId)
        if (code === 200) {
			let srcList=[];
			srcList.push(data.accessoryUrl)
		   this.srcList=srcList
          this.detail = data
        }
      } catch (err) {
        console.log(err)
      }
    }
  }

}
</script>


<style scoped>
	.img{
		margin-left: 10px;
	}
	.content {
		height: 70%;
	}

	.content h5 {
		margin: 50px 0 80px
	}

	.content h3,
	.content h4 {
		margin-left: -50px;
	}
	span{
		color:#B21F2D
	}
</style>
