<template>
    <div>
      <h3 style="text-align: center">{{ inspectDetailInfo.inspectName }}</h3>
      <div>检查时间: {{ parseTime(inspectDetailInfo.createTime, '{y}年{m}月{d}日') }}</div>
      <table class="inspect" border="1" cellspacing="0" cellpadding="0">
        <tr>
          <td style="width: 20%">检查项</td>
          <td>检查内容</td>
          <td style="width: 15%">检查结果</td>
        </tr>

        <tr v-for="item in inspectDetailInfo.inspectContent">
          <td>{{ item.itemName }}</td>
          <td style="text-align: left">
            <div v-for="content in item.content">{{ content }}</div>
          </td>
          <td>
            正常<input :checked="item.value == 0" type="checkbox" class="input-disabled"/>
            异常<input :checked="item.value == 1" type="checkbox" class="input-disabled"/>
          </td>
        </tr>

      </table>
      <div>检查人: {{ inspectDetailInfo.inspectorName }}</div>

    </div>
</template>

<script>
  export default {
    name: "inspect-detail",
    data(){
        return{
          inspectDetailInfo:{
            inspectName: "",
            inspectContent:[
              {
                value: 0,
                itemName: "",
                content:[""]
              }
            ]
          }

        }
    }
  }
</script>

<style scoped lang="scss">
  .inspect{
    width: 100%;
    td{
      text-align: center;
      height: 29px;
    }
  }

  .input-disabled{
    pointer-events: none;
  }
</style>
