<template>
  <el-dialog title="详情" :visible.sync="detailOpen" width="1000px" append-to-body destroy-on-close :close-on-click-modal="false">
    <el-form label-width="180px">
      <el-row class="el-row-table">
        <el-col :span="12">
          <el-form-item label="项目编码">
            <span v-if="detailInfo.fProjectCode">{{ detailInfo.fProjectCode }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="外部工程编码">
            <span v-if="detailInfo.fProjectNo">{{ detailInfo.fProjectNo }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工工程项目名称">
            <span v-if="detailInfo.fProjectName">{{ detailInfo.fProjectName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="开工时间">
            <span v-if="detailInfo.fConstructionStart">{{ detailInfo.fConstructionStart }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="计划竣工时间">
            <span v-if="detailInfo.fConstructionEnd">{{ detailInfo.fConstructionEnd }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="项目位置描述">
            <span v-if="detailInfo.fAddress">{{ detailInfo.fAddress }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="所属县级行政区ID">
            <span v-if="detailInfo.fDistrictId">{{ detailInfo.fDistrictId }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="涉气施工点位位置属性">
            <span v-if="detailInfo.fConstructionPointType">{{ detailInfo.fConstructionPointType }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="村级行政区">
            <span v-if="detailInfo.fVillageId">{{ detailInfo.fVillageId }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="管道压力等级分类">
            <span v-if="detailInfo.fPipePress">{{ $parent.fPipePressFormat(detailInfo) }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工是否主动报备">
            <span v-if="detailInfo.fReportFlag == 1">是</span>
            <span v-else-if="detailInfo.fReportFlag == 0">否</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工状态">
            <span v-if="detailInfo.fConstructionStatus == 1">未开工</span>
            <span v-else-if="detailInfo.fConstructionStatus == 2">正在施工</span>
            <span v-else-if="detailInfo.fConstructionStatus == 3">已完工</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="建设单位名称">
            <span v-if="detailInfo.fBuildDepartment">{{ detailInfo.fBuildDepartment }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="建设单位项目负责人姓名">
            <span v-if="detailInfo.fProjectLeader">{{ detailInfo.fProjectLeader }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="建设单位项目负责人电话">
            <span v-if="detailInfo.fProjectLeaderPhone">{{ detailInfo.fProjectLeaderPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="所属行业">
            <span v-if="detailInfo.fIndustry">{{ detailInfo.fIndustry }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="行业安全监管部门名称">
            <span v-if="detailInfo.fDepartmentName">{{ detailInfo.fDepartmentName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工单位名称">
            <span v-if="detailInfo.fConstructDepartment">{{ detailInfo.fConstructDepartment }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工单位项目负责人姓名">
            <span v-if="detailInfo.fBuildProjectLeaderName">{{ detailInfo.fBuildProjectLeaderName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工单位项目负责人电话">
            <span v-if="detailInfo.fBuildProjectLeaderPhone">{{ detailInfo.fBuildProjectLeaderPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工单位技术负责人姓名">
            <span v-if="detailInfo.fTechnicalLeaderName">{{ detailInfo.fTechnicalLeaderName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工单位技术负责人电话">
            <span v-if="detailInfo.fTechnicalLeaderPhone">{{ detailInfo.fTechnicalLeaderPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="监理单位名称">
            <span v-if="detailInfo.fSupervisionUnitName">{{ detailInfo.fSupervisionUnitName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="监理单位总监理工程师姓名">
            <span v-if="detailInfo.fChiefEngineerName">{{ detailInfo.fChiefEngineerName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="监理单位总监理工程师电话">
            <span v-if="detailInfo.fChiefEngineerPhone">{{ detailInfo.fChiefEngineerPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="燃气企业编码">
            <span v-if="detailInfo.fCompanyInfoId">{{ detailInfo.fCompanyInfoId }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工点位巡线员编码">
            <span v-if="detailInfo.fPatrolSafetyOfficerNo">{{ detailInfo.fPatrolSafetyOfficerNo }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工点位巡线员姓名">
            <span v-if="detailInfo.fPartrolSafetyOfficerName">{{ detailInfo.fPartrolSafetyOfficerName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="施工点位巡线员电话">
            <span v-if="detailInfo.fPatrolSafetyOfficerPhone">{{ detailInfo.fPatrolSafetyOfficerPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="驻村安全员编码">
            <span v-if="detailInfo.fResidentSafetyOfficerNo">{{ detailInfo.fResidentSafetyOfficerNo }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>


        <el-col :span="12">
          <el-form-item label="驻村安全员姓名">
            <span v-if="detailInfo.fResidentSafetyOfficerName">{{ detailInfo.fResidentSafetyOfficerName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>


        <el-col :span="12">
          <el-form-item label="驻村安全员电话">
            <span v-if="detailInfo.fResidentSafetyOfficerPhone">{{ detailInfo.fResidentSafetyOfficerPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="燃气企业旁站人员编码">
            <span v-if="detailInfo.fGasCompanyStationNo">{{ detailInfo.fGasCompanyStationNo }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="燃气企业旁站人员姓名">
            <span v-if="detailInfo.fGasCompanyStationName">{{ detailInfo.fGasCompanyStationName }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="燃气企业旁站人员电话">
            <span v-if="detailInfo.fGasCompanyStationPhone">{{ detailInfo.fGasCompanyStationPhone }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>

        <el-col :span="12">
          <el-form-item label="更新时间">
            <span v-if="detailInfo.fUpdateTime">{{ detailInfo.fUpdateTime }}</span>
            <span v-else>-</span>
          </el-form-item>
        </el-col>
      </el-row>
    </el-form>
  </el-dialog>

</template>

<script>
  import { getInfor } from "@/api/thirdbuild/project";
  export default {
    name: "detail-info",
    data(){
        return{
          detailInfo: {},
          detailOpen: false
        }
    },
    methods:{
      getDetailInfo(id){
        getInfor(id).then(res =>{
          if(res.code == 200 && res.data){
            this.detailInfo = res.data;
            this.detailOpen = true;
          }
        })
      }
    }
  }
</script>

<style scoped>

</style>
