<template>
  <div>
    <el-tabs v-model="activeName" style="margin-left: 30px">
      <el-tab-pane label="企业信息" name="first">
        <el-form
          class="content-main"
          label-width="200px"
          :data="formQuery"
          ref="detailForm"
        >
          <el-row>
            <el-col :span="8">
              <el-form-item label="企业名称:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qymc"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="统一社会信用代码:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.tyshxydm"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="单位代码:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.dwdm"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="库点类型:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.dwlx"
                  placeholder="请选择"
                  multiple
                >
                  <el-option
                    v-for="item in options"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="单位类型:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.lx"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in lxOptions"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="单位性质:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyxz"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options1"
                    :key="item.value"
                    :label="item.label"
                    :value="item.label"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="注册日期:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="zcrq"
                  value-format="yyyy-MM-dd HH:mm:ss"
                  format="yyyy-MM-dd"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="24">
              <el-form-item label="所在地:">
                <!--          <el-input-->
                <!--            :disabled="showLock"-->
                <!--            v-model="formQuery.qytxdz"-->
                <!--            style="width: 154%"-->
                <!--          ></el-input>-->
                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.txprovince"
                  placeholder="省"
                  style="width: 10%"
                  @change="initszdCity"
                >
                  <el-option
                    v-for="item in szdProvince"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>
                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.txcity"
                  placeholder="市"
                  style="width: 10%"
                >
                  <el-option
                    v-for="item in szdCity"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>
                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.txcounty"
                  placeholder="地区"
                  style="width: 10%"
                >
                  <el-option
                    v-for="item in szdCityQ"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>
                <el-input
                  :disabled="showLock"
                  style="width: 55%"
                  maxlength="50"
                  v-model="formQuery.qytxdz"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="法定代表人:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.fddbr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="是否独立法人资格:">
                <el-radio-group
                  :disabled="showLock"
                  v-model="formQuery.sfdlfrzg"
                >
                  <el-radio :label="1">是</el-radio>
                  <el-radio :label="0">否</el-radio>
                </el-radio-group>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="联系人:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qylxr"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="法人联系方式:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.frsjh"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="办公电话:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.bgdh"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="传真:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyczhm"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="邮政编码:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyyb"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="电子邮箱:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qydzyx"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="法人身份证号:" prop="frsfzh">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.frsfzh"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="经度:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyjd"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="纬度:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qywd"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="占地面积(平方米):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zdmj"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="设计仓容(吨)">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sjcr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="有效仓容(吨):" prop="zcr">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zcr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="有效罐容(吨):" prop="gr">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.gr"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="24">
              <el-form-item label="单位主要业务:" class="chb_box">
                <el-checkbox-group
                  style="width: 90%"
                  v-model="dwzyywArr"
                  :disabled="showLock"
                >
                  <el-checkbox
                    v-for="(d, i) in dwzyywOpts"
                    :key="i"
                    :label="d.dictCode"
                    >{{ d.dictName }}</el-checkbox
                  >
                  <!-- <el-checkbox :label="'粮油质检'">粮油质检</el-checkbox>
						<el-checkbox :label="'粮油科研'">粮油科研</el-checkbox>
						<el-checkbox :label="'中央储备粮承储'">中央储备粮承储</el-checkbox>
						<el-checkbox :label="'地方储备粮承储'">地方储备粮承储</el-checkbox>
						<el-checkbox :label="'粮油机械制造'">粮油机械制造</el-checkbox>
						<el-checkbox :label="'其他'">其他</el-checkbox>
						<el-checkbox :label="'行政管理'">行政管理</el-checkbox>
						<el-checkbox :label="'粮油转化'">粮油转化</el-checkbox>-->
                </el-checkbox-group>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="24">
              <el-form-item label="企业类型:">
                <el-checkbox-group
                  style="width: 90%"
                  v-model="formQuery.qylx"
                  :disabled="showLock"
                  class="chb_box"
                >
                  <el-checkbox
                    v-for="(d, i) in qylxOpts"
                    :key="i"
                    :label="d.dictCode"
                  >
                    {{ d.dictName }}
                  </el-checkbox>
                  <!-- <el-checkbox :label="'粮食收储企业'">粮食收储企业</el-checkbox>
						<el-checkbox :label="'粮油批发市场'">粮油批发市场</el-checkbox>
						<el-checkbox :label="'超市'">超市</el-checkbox>
						<el-checkbox :label="'小麦粉加工企业'">小麦粉加工企业</el-checkbox>
						<el-checkbox :label="'大米加工企业'">大米加工企业</el-checkbox>
						<el-checkbox :label="'其他成品粮加工企业'">其他成品粮加工企业</el-checkbox>
						<el-checkbox :label="'食用植物油加工企业'">食用植物油加工企业</el-checkbox>
						<el-checkbox :label="'食品及副食酿造企业'">食品及副食酿造企业</el-checkbox>
						<el-checkbox :label="'制酒企业'">制酒企业</el-checkbox>
						<el-checkbox :label="'饲料企业'">饲料企业</el-checkbox>
						<el-checkbox :label="'养殖企业'">养殖企业</el-checkbox>
						<el-checkbox :label="'淀粉企业'">淀粉企业</el-checkbox>
						<el-checkbox :label="'酒精企业'">酒精企业</el-checkbox>
						<el-checkbox :label="'其他粮油深加工企业'">其他粮油深加工企业</el-checkbox>
						<el-checkbox :label="'粮油机械制造企业'">粮油机械制造企业</el-checkbox>
						<el-checkbox :label="'玉米加工企业'">玉米加工企业</el-checkbox>-->
                </el-checkbox-group>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="企业层级:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qycj"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options2"
                    :key="item.value"
                    :label="item.label"
                    :value="item.label"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="在岗职工:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qycyrys"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="下属企业个数:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.xsqygs"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="企业工商登记机关:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qygsdjjg"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="16">
              <el-form-item label="注册地:">
                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.zcprovince"
                  placeholder="省"
                  style="width: 20%"
                  @change="initzcdCity"
                >
                  <el-option
                    v-for="item in zcdProvince"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>
                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.zccity"
                  placeholder="市"
                  style="width: 20%"
                >
                  <el-option
                    v-for="item in zcdCity"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>

                <el-select
                  clearable
                  :disabled="showLock"
                  v-model="formQuery.zccounty"
                  placeholder="地区"
                  style="width: 20%"
                >
                  <el-option
                    v-for="item in zcdCityQ"
                    :key="item.countyCode"
                    :label="item.countyName"
                    :value="item.countyCode"
                  ></el-option>
                </el-select>
                <el-input
                  :disabled="showLock"
                  style="width: 31%"
                  v-model="formQuery.qygszcd"
                  maxlength="50"
                ></el-input>
                <!--          <el-input-->
                <!--            class="inputWidth"-->
                <!--            :disabled="showLock"-->
                <!--            style="width: 92%"-->
                <!--            v-model="formQuery.qygszcd"-->
                <!--          ></el-input>-->
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="企业状态:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyzt"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options3"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="入统状态:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.rtzt"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options3"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="所属粮食行政管理部门:">
                <!-- <el-input class="inputWidth" :disabled="showLock" v-model="formQuery.sslsxzglbm"></el-input> -->
                <el-cascader
                  :disabled="showLock"
                  v-model="formQuery.sslsxzglbm"
                  :options="tree"
                  :props="defaultParams"
                  :change-on-select="true"
                  :show-all-levels="false"
                  class="inputWidth"
                ></el-cascader>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="市级承储企业:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sjccqy"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options4"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="区级承储企业:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qjccqy"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options4"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="是否最低最高企业:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sfzdzgqy"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options4"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="8">
              <el-form-item label="库点类别:" prop="kqlb">
                <el-cascader
                  class="inputWidth"
                  :options="kdlbOptions"
                  :props="pzProps"
                  clearable
                  disabled
                  :show-all-levels="false"
                  v-model="formQuery.kqlb"
                  placeholder="请选择"
                ></el-cascader>
                <!-- <el-select
              class="inputWidth"
              :disabled="showLock"
              v-model="formQuery.kqlb"
              placeholder="请选择"
            >
              <el-option
                v-for="item in kdlbOptions"
                :key="item.value"
                :label="item.label"
                :value="item.value"
              ></el-option>
            </el-select> -->
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="库区产权:" prop="kqcq">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.kqcq"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in kqcqOptions"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <el-row>
            <el-col :span="10">
              <el-form-item label="首页库区图:">
                <el-upload
                  :disabled="showLock"
                  class="upload-demo"
                  :action="actionUrl"
                  :on-preview="handlePreview1"
                  :file-list="fileList1"
                >
                </el-upload>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.lssgzg = !subTitle.lssgzg"
            :class="{ sub_title__icon_arrow_down: subTitle.lssgzg }"
          >
            粮食收购资格
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.lssgzg">
            <el-col :span="8">
              <el-form-item label="是否具有粮食收购资格许可:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sfjysgzg"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options4"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="粮食收购许可证发证机关:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.lssgxkzfzjg"
                  maxlength="20"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="收购资格证编号:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sgzgzbh"
                  maxlength="20"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="发证日期:">
                <el-date-picker
                  v-model="formQuery.fzrq"
                  value-format="yyyy-MM-dd"
                  format="yyyy-MM-dd"
                  clearable
                  :disabled="showLock"
                  class="inputWidth"
                ></el-date-picker>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="有效日期:">
                <el-date-picker
                  v-model="formQuery.yxqz"
                  value-format="yyyy-MM-dd"
                  format="yyyy-MM-dd"
                  clearable
                  :disabled="showLock"
                  class="inputWidth"
                ></el-date-picker>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="状态:">
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sgzt"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="(item, index) in ['无效', '有效']"
                    :key="index"
                    :label="item"
                    :value="`${index}`"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.qyyjxx = !subTitle.qyyjxx"
            :class="{ sub_title__icon_arrow_down: subTitle.qyyjxx }"
          >
            企业应急信息
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.qyyjxx">
            <el-col :span="8">
              <el-form-item label="应急级别:">
                <!-- <el-input class="inputWidth" :disabled="showLock" v-model="formQuery.qyyjjb"></el-input> -->
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyyjjb"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options5"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="企业应急类型:">
                <!-- <el-input class="inputWidth" :disabled="showLock" v-model="formQuery.qyyjlxmc"></el-input> -->
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qyyjlxmc"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options6"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.sjjtxx = !subTitle.sjjtxx"
            :class="{ sub_title__icon_arrow_down: subTitle.sjjtxx }"
          >
            上级集团信息
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.sjjtxx">
            <el-col :span="8">
              <el-form-item label="上级集团:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sjjtmc"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="上级集团统一社会信用代码:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sjjttyshxydm"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.jgqyxx = !subTitle.jgqyxx"
            :class="{ sub_title__icon_arrow_down: subTitle.jgqyxx }"
          >
            加工企业信息
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.jgqyxx">
            <el-col :span="8">
              <el-form-item label="产业化龙头企业:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.cyhltqy"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="放心粮油示范工程:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.fxlysfgc"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="全国工业产品生产许可证品种:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.qggycpscxkzpz"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="是否主食加工中央厨房:">
                <el-radio-group
                  :disabled="showLock"
                  v-model="formQuery.sfzsjgzycf"
                >
                  <el-radio :label="1">是</el-radio>
                  <el-radio :label="0">否</el-radio>
                </el-radio-group>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="研发中心级别:">
                <!-- <el-input class="inputWidth" :disabled="showLock" v-model="formQuery.yfzxjb"></el-input> -->
                <el-select
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.yfzxjb"
                  placeholder="请选择"
                >
                  <el-option
                    v-for="item in options7"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"
                  ></el-option>
                </el-select>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.qyjjsj = !subTitle.qyjjsj"
            :class="{ sub_title__icon_arrow_down: subTitle.qyjjsj }"
          >
            企业经济数据
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.qyjjsj">
            <el-col :span="8">
              <el-form-item label="注册资本(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zczb"
                  maxlength="9"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="营业收入(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.yysr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="工业总产值(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.gyzcz"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="产品销售收入(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.cpxssr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="利税总额(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.lsze"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="利润总额(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.lrze"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="资产总额(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zcze"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="当年研究开发投入(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.dnyjkftr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="政府支持投入(万元):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zfzctr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="当年专利获得数(件):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.dnzlhds"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="发明专利(件):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.fmzl"
                ></el-input>
              </el-form-item>
            </el-col>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.qysbjnh = !subTitle.qysbjnh"
            :class="{ sub_title__icon_arrow_down: subTitle.qysbjnh }"
          >
            企业设备及能耗
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.qysbjnh">
            <el-col :span="8">
              <el-form-item label="年产粮油机械制造:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.nclyjxzz"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="大米加工主机:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.dmjgzj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="小麦粉加工主机:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.xmfjgzj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="油脂加工主机:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.yzjgzj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="饲料加工主机:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.sljgzj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="仓储设备:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.ccsb"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="通用设备:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.tysb"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="能源耗电:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.nyhd"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="能源消耗水:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.nyxhs"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="能源消耗标准煤:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.nhxhbzm"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="能源消耗溶剂:">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.nyxhrj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="总仓容(以三等小麦计/吨):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.zcr"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="罐容(吨):">
                <el-input
                  class="inputWidth"
                  :disabled="showLock"
                  v-model="formQuery.gr"
                ></el-input>
              </el-form-item>
            </el-col>
            <!-- <el-col :span="16">
          <el-form-item label="仓房:">
            <el-input
              style="width: 80px"
              :disabled="showLock"
              v-model="formQuery.cfd"
            ></el-input>
            <span>&nbsp;&nbsp;栋&nbsp;&nbsp;</span>
            <el-input
              style="width: 80px"
              :disabled="showLock"
              v-model="formQuery.cfj"
            ></el-input>
            <span>&nbsp;&nbsp;间</span>
          </el-form-item>
        </el-col> -->
          </el-row>
          <el-row>
            <el-form-item label="备注:">
              <el-input
                type="textarea"
                rows="3"
                style="width: 95%"
                :disabled="showLock"
                v-model="formQuery.remark"
              ></el-input>
            </el-form-item>
          </el-row>
          <div
            class="sub_title"
            @click="subTitle.fjsc = !subTitle.fjsc"
            :class="{ sub_title__icon_arrow_down: subTitle.fjsc }"
          >
            主要电子证照扫描件
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-show="subTitle.fjsc">
            <el-col :span="24">
              <el-form-item label="主要电子证照扫描件:">
                <el-upload
                  disabled
                  class="upload-demo"
                  :action="actionUrl"
                  :on-preview="handlePreview"
                  multiple
                  :file-list="fileList"
                  list-type="picture-card"
                >
                  <!-- list-type="picture" -->
                  <i class="el-icon-plus"></i>
                  <!-- <el-button
              size="small"
              class="iconfont iconshangchuan"
              type="primary"
              
              >上传</el-button
            > -->
                </el-upload>
              </el-form-item>
            </el-col>
          </el-row>
        </el-form>
        <el-form
          class="content-main"
          label-width="200px"
          :data="auditQuery"
          ref="detailForm1"
        >
          <div
            v-if="reviewType"
            class="sub_title"
            @click="subTitle.spxx = !subTitle.spxx"
            :class="{ sub_title__icon_arrow_down: subTitle.spxx }"
          >
            审批信息
            <i class="el-icon-arrow-up"></i>
          </div>
          <el-row v-if="reviewType" v-show="subTitle.spxx">
            <el-col :span="24">
              <el-form-item label="审批:">
                <el-radio-group v-model="auditQuery.sfba" :disabled="auditShow">
                  <el-radio :label="5">通过</el-radio>
                  <el-radio :label="3">驳回</el-radio>
                </el-radio-group>
              </el-form-item>
            </el-col>
            <el-col :span="24">
              <el-form-item label="审核意见:">
                <el-input
                  class="inputWidth"
                  :disabled="auditShow"
                  type="textarea"
                  :autosize="{ minRows: 3 }"
                  v-model="auditQuery.shyj"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="审核人:">
                <el-input
                  class="inputWidth"
                  disabled
                  v-model="auditQuery.shrmc"
                ></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="8">
              <el-form-item label="审核时间:">
                <!-- <el-input class="inputWidth" :disabled="showLock" v-model="auditQuery.shsj"></el-input> -->
                <el-date-picker
                  v-model="auditQuery.shsj"
                  disabled
                  type="date"
                  value-format="yyyy-MM-dd"
                ></el-date-picker>
              </el-form-item>
            </el-col>
          </el-row>
        </el-form>
      </el-tab-pane>
      <el-tab-pane label="变更日志" name="second">
        <el-table
          :data="updateLogList"
          border
          fit
          highlight-current-row
          :span-method="objectSpanMethod"
        >
          <el-table-column
            align="center"
            prop="createDate"
            label="变更日期"
          ></el-table-column>
          <el-table-column
            align="center"
            prop="updateCol"
            label="变更字段"
          ></el-table-column>
          <el-table-column
            align="center"
            prop="beforeData"
            label="变更前"
          ></el-table-column>
          <el-table-column
            align="center"
            prop="afterData"
            label="变更后"
          ></el-table-column>
          <el-table-column
            align="center"
            prop="refresher"
            label="变更人"
          ></el-table-column>
        </el-table>
      </el-tab-pane>
    </el-tabs>
    <el-col :span="24">
      <div style="text-align: center; margin: 20px 0">
        <el-button
          type="primary"
          icon="iconfont icontijiao"
          v-if="!showLock"
          @click="saveSubmit('save')"
          >保存</el-button
        >
        <el-button
          type="primary"
          icon="iconfont icontijiao"
          v-if="!auditShow"
          @click="saveSubmit('send')"
          >提交</el-button
        >
        <el-button type="primary" icon="iconfont iconfanhui" @click="cancel">
          返回</el-button
        >
      </div>
    </el-col>
    <el-dialog
      width="800px"
      center
      title="查看大图"
      :close-on-click-modal="false"
      :visible.sync="dialogVisible"
    >
      <img width="100%" :src="dialogImageUrl" alt="" />
    </el-dialog>
  </div>
</template>

<script>
import {
  getCompanyInfo,
  editCompanyInfo,
  qylxOpts,
  tree,
  dwzyywOpts,
  findProvince,
  findCity,
  findCountyQ,
} from "@/api/jcxxwh/qyjcxx";
import { file } from "@/api";
import { getNowDate } from "@/utils/index";
import { fileInfo } from "@/api/grainReserves/downWarehouse/warehouseAcceptance";
function formatData(list) {
  return list.map((item) => {
    let newItem = {};
    newItem.label = item.orgName;
    newItem.value = item.orgName;
    newItem.code = item.orgCode;
    if (item.orgCode.length == 8) {
      return newItem;
    }
    if (item.hasOwnProperty("children") && item.children.length > 0) {
      newItem.children = formatData(item.children);
    }
    return newItem;
  });
}
function getCascaderObj(val, opt) {
  return val.map(function (value, index, array) {
    for (var itm of opt) {
      if (itm.value == value) {
        opt = itm.children;
        return itm;
      }
    }
    return null;
  });
}
export default {
  name: "slqyxxsb",
  data() {
    return {
      activeName: "first",
      updateLogList: [],
      pzProps: {
        label: "label",
        value: "value",
        key: "value",
        children: "children",
        // checkStrictly: true,

        emitPath: false,
      },
      kdlbOptions: [
        {
          value: "1",
          label: "粮食仓储企业",
          children: [
            { value: "11", label: "中央直属储备粮库" },
            { value: "12", label: "中谷粮油集团" },
            { value: "13", label: "省级储备粮库" },
            { value: "14", label: "地市级储备粮库" },
            { value: "15", label: "县级储备粮库" },
          ],
        },
        {
          value: "2",
          label: "粮食购销企业",
        },
        {
          value: "3",
          label: "粮食加工企业",
        },
        {
          value: "4",
          label: "粮食设备制造企业",
        },
        {
          value: "9",
          label: "其他粮食企业",
        },
      ],
      //1:自有  2:租赁  3:共有  4:混合  9:其他
      kqcqOptions: [
        { value: "1", label: "自有" },
        { value: "2", label: "租赁" },
        { value: "3", label: "共有" },
        { value: "4", label: "混合" },
        { value: "9", label: "其他" },
      ],
      lxOptions: [
        { value: "5317", label: "行政机构" },
        { value: "5318", label: "粮食企业" },
        { value: "5527", label: "部门" },
      ],
      dialogVisible: false,
      dialogImageUrl: "",
      actionUrl: file + "/file/upload",
      fileList: [],
      fileList1: [],
      subTitle: {
        lssgzg: true,
        qyyjxx: true,
        sjjtxx: true,
        jgqyxx: true,
        qyjjsj: true,
        qysbjnh: true,
        spxx: true,
        fjsc: true,
      },
      zcrq: "",
      dwzyywArr: [],
      dwzyywOpts: [],
      defaultParams: {
        label: "label",
        value: "code",
        children: "children",
        name: "label",
        emitPath: false,
      },
      tree: [],
      qylxOpts: [],
      showLock: true,
      auditShow: false,
      reviewType: false,
      formQuery: {},
      auditQuery: {
        shrmc: sessionStorage.userName || "",
        shsj: getNowDate(),
        sfba: 5,
        shyj: "",
      },
      dwzyyw1: [],
      qylx1: [],
      isChecked: false,
      options: [
        {
          value: "1",
          label: "应急",
        },
        {
          value: "2",
          label: "仓储",
        },
        {
          value: "3",
          label: "加工",
        },
        {
          value: "4",
          label: "物流",
        },
        {
          value: "5",
          label: "配送",
        },
      ],
      options1: [
        {
          value: 1,
          label: "行政机关",
        },
        {
          value: 2,
          label: "事业单位",
        },
        {
          value: 3,
          label: "参公管理事业单位",
        },
        {
          value: 4,
          label: "国有及国有控股企业",
        },
        {
          value: 5,
          label: "内资非国有企业",
        },
        {
          value: 6,
          label: "私营企业",
        },
        {
          value: 7,
          label: "港澳台商及外商企业",
        },
        {
          value: 8,
          label: "个体工商户",
        },
        {
          value: 9,
          label: "其他",
        },
      ],
      options2: [
        {
          value: "1",
          label: "市属",
        },
        {
          value: "2",
          label: "区属",
        },
        {
          value: "3",
          label: "利达粮油",
        },
        {
          value: "4",
          label: "中粮利金",
        },
      ],
      options3: [
        {
          value: 1,
          label: "启用",
        },
        {
          value: 0,
          label: "停用",
        },
      ],
      options4: [
        {
          value: "1",
          label: "是",
        },
        {
          value: "0",
          label: "否",
        },
      ],
      options5: [
        {
          value: "1",
          label: "市级",
        },
        {
          value: "2",
          label: "区级",
        },
        {
          value: "3",
          label: "非应急",
        },
      ],
      options6: [
        {
          value: "1",
          label: "应急储运企业",
        },
        {
          value: "2",
          label: "应急供应网点",
        },
        {
          value: "3",
          label: "应急加工企业",
        },
        {
          value: "4",
          label: "应急配送中心",
        },
      ],
      options7: [
        {
          value: "1",
          label: "初级",
        },
        {
          value: "2",
          label: "中级",
        },
        {
          value: "3",
          label: "高级",
        },
      ],
      szdProvince: [], //所在地省
      szdCity: [], //注册地市
      zcdProvince: [], //所在地省
      zcdCity: [], //注册地市
      szdCityQ: [],
      zcdCityQ: [],
    };
  },
  methods: {
    // table合并列
    objectSpanMethod({ row, column, rowIndex, columnIndex }) {
      if (columnIndex == 0 || columnIndex == 4) {
        console.log(row.dataVer, "row.dataVer");
        let data = this.updateLogList; //拿到当前table中数据
        let cellValue = row.dataVer + 1; //当前位置的值
        let noSortArr = [];
        data.map((item) => {
          noSortArr.push(item.dataVer + 1);
        });
        noSortArr = Array.from(new Set(noSortArr));
        // let noSortArr = ['num1', 'num2', 'num3', 'num4', 'num5', 'num6']; //不需要合并的字段（不进行合并行的prop）
        if (cellValue && !noSortArr.includes(column.property)) {
          let prevRow = data[rowIndex - 1]; //获取到上一条数据
          let nextRow = data[rowIndex + 1]; //下一条数据
          if (prevRow && prevRow.dataVer + 1 === cellValue) {
            //当有上一条数据，并且和当前值相等时
            return { rowspan: 0, colspan: 0 };
          } else {
            let countRowspan = 1;
            while (nextRow && nextRow.dataVer + 1 === cellValue) {
              //当有下一条数据并且和当前值相等时,获取新的下一条
              nextRow = data[++countRowspan + rowIndex];
            }
            if (countRowspan > 1) {
              return { rowspan: countRowspan, colspan: 1 };
            }
          }
        }
      }
    },
    //获取省
    initProvince() {
      findProvince()
        .then((res) => {
          this.szdProvince = res.data;
          this.zcdProvince = res.data;
        })
        .catch();
    },
    initCity(val, name) {
      //310000--上海,500000--重庆,110000--北京,120000--天津
      // if (val == 310000 || val == 500000 || val == 110000 || val == 120000) {
      //   //获取直辖市下的区
      //   findCountyQ(val)
      //     .then((res) => {
      //       this[name] = res.data;
      //     })
      //     .catch();
      // } else {
      //获取省下的市
      findCity(val)
        .then((res) => {
          this[name] = res.data;
        })
        .catch();
      // }
    },
    initCityQ(val, name) {
      //310000--上海,500000--重庆,110000--北京,120000--天津
      // if (val == 310000 || val == 500000 || val == 110000 || val == 120000) {
      //   //获取直辖市下的区
      findCountyQ(val)
        .then((res) => {
          this[name] = res.data;
        })
        .catch();
      // } else {
      //获取省下的市
      // findCity(val)
      //   .then((res) => {
      //     this[name] = res.data;
      //   })
      //   .catch();
      // }
    },
    initzcdCity(val) {
      this.$set(this.formQuery, "zccity", "");
      this.initCity(val, "zcdCity");
    },
    initszdCity(val) {
      this.$set(this.formQuery, "txcity", "");
      this.initCity(val, "szdCity");
    },
    initszdCityQ(val) {
      this.$set(this.formQuery, "txcounty", "");
      this.initCityQ(val, "szdCityQ");
    },
    initzcdCityQ(val) {
      this.$set(this.formQuery, "zccounty", "");
      this.initCityQ(val, "zcdCityQ");
    },
    initOpts() {
      qylxOpts().then((res) => {
        var codes = [];
        if (res && Array.isArray(res.data))
          this.qylxOpts = res.data.filter((d) => {
            if (codes.includes(d.dictCode)) {
              return false;
            } else {
              codes.push(d.dictCode);
              return true;
            }
          });
      });
      dwzyywOpts().then((res) => {
        if (!res) return;
        this.dwzyywOpts = res.data;
      });
      tree().then((res) => {
        if (!res) {
          this.tree = [];
          return;
        }
        var arr = [];
        arr.push(res.data);
        this.tree = formatData(arr);
      });
    },
    getInfo() {
      // var code = sessionStorage.getItem("tyshxydm");
      getCompanyInfo(this.$route.query.code).then((res) => {
        if (!res) return;
        let detailForm = res.data;
        if (!this.$route.query.status) {
          this.reviewType = true;
          this.auditQuery.sfba = res.data.sfba
            ? res.data.sfba == 2
              ? this.auditQuery.sfba
              : res.data.sfba
            : this.auditQuery.sfba;
          this.auditQuery.shrmc = res.data.shrmc
            ? res.data.sfba == 2
              ? this.auditQuery.shrmc
              : res.data.shrmc
            : this.auditQuery.shrmc;
          this.auditQuery.shsj = res.data.shsj
            ? res.data.sfba == 2
              ? this.auditQuery.shsj
              : res.data.shsj
            : this.auditQuery.shsj;
          this.auditQuery.shyj = res.data.shyj
            ? res.data.sfba == 2
              ? this.auditQuery.shyj
              : res.data.shyj
            : this.auditQuery.shyj;
        } else {
          this.reviewType = res.data.sfba > 2 ? true : false;
          this.auditQuery.sfba = res.data.sfba
            ? res.data.sfba == 2
              ? this.auditQuery.sfba
              : res.data.sfba
            : this.auditQuery.sfba;
          this.auditQuery.shrmc = res.data.shrmc
            ? res.data.sfba == 2
              ? this.auditQuery.shrmc
              : res.data.shrmc
            : this.auditQuery.shrmc;
          this.auditQuery.shsj = res.data.shsj
            ? res.data.sfba == 2
              ? this.auditQuery.shsj
              : res.data.shsj
            : this.auditQuery.shsj;
          this.auditQuery.shyj = res.data.shyj
            ? res.data.sfba == 2
              ? this.auditQuery.shyj
              : res.data.shyj
            : this.auditQuery.shyj;
        }
        detailForm = {
          ...detailForm,
          ...detailForm.tzYjqyVO,
        };
        if (detailForm.dwlx) detailForm.dwlx = detailForm.dwlx.split(",");
        if (detailForm.zcrq) this.zcrq = detailForm.zcrq.slice(0, 10);
        if (detailForm.sfjysgzg) detailForm.sfjysgzg = detailForm.sfjysgzg + "";
        // this.dwzyyw1 = detailForm.qyzyyw.split(',')
        this.dwzyywArr = detailForm.qyzyyw.split(",");
        detailForm.qylx = detailForm.tzQylxVOList.map((d) => d.qylxbh);
        if (!this.$route.query.status) {
        }
        this.formQuery = detailForm;
        //上传相关
        if (res.data.fileId) {
          fileInfo(res.data.fileId).then((res) => {
            res.data.forEach((item) => {
              item.url = `http://101.36.160.140:8097/file/${item.link}`;
            });
            this.fileList = res.data;
          });
        }
        if (res.data.sykqt) {
          findByIds(res.data.sykqt).then((res) => {
            this.fileList1 = res.data;
          });
        }
        this.initCity(this.formQuery.zcprovince, "zcdCity");
        this.initCity(this.formQuery.txprovince, "szdCity");
        this.initCityQ(this.formQuery.zccity, "zcdCityQ");
        this.initCityQ(this.formQuery.txcity, "szdCityQ");
        this.$refs.detailForm.clearValidate();
        this.initOpts();
        this.updateLogList = res.data.updateLogList;
      });
    },
    saveSubmit(status) {
      if (this.formQuery.dwlx)
        this.formQuery.dwlx = this.formQuery.dwlx.join(",");
      // this.formQuery.qyzyyw = this.dwzyyw1.join(',')
      // this.formQuery.qylx = this.qylx1.join(',')
      // this.formQuery = { ...this.auditQuery, ...this.formQuery }
      this.formQuery.sfba = this.auditQuery.sfba;
      this.formQuery.shrmc = this.auditQuery.shrmc;
      this.formQuery.shsj = this.auditQuery.shsj;
      this.formQuery.shyj = this.auditQuery.shyj;
      this.formQuery.dsbxxsjyVOList = [];
      if (status == "save") {
        editCompanyInfo(this.formQuery).then((res) => {
          if (res.infoCode == 200) {
            this.$message({
              message: "保存成功",
              type: "success",
              duration: 2000,
            });
            this.$router.push({ path: "/jcxxsh/qyxxsh" });
          } else {
            this.$message({
              message: "保存失败",
              type: "success",
              duration: 2000,
            });
          }
        });
      } else if (status == "send") {
        editCompanyInfo(this.formQuery).then((res) => {
          if (res.infoCode == 200) {
            this.$message({
              message: "提交成功",
              type: "success",
              duration: 2000,
            });
            this.$router.push({ path: "/jcxxsh/qyxxsh" });
          } else {
            this.$message({
              message: "提交失败",
              type: "success",
              duration: 2000,
            });
          }
        });
      }
    },
    cancel() {
      this.$router.go(-1);
    },
    //shagchau
    handlePreview(files) {
      console.log(files);
      this.dialogImageUrl = files.response
        ? `${window.location.origin}/${files.response.data.uri}`
        : `${window.location.origin}/${files.link}`;
      // `http://101.36.160.140:8097/file/${files.link}`;

      this.dialogVisible = true;
      // window.location.href = `${file}/file/download?id=${
      //   files.response ? files.response.data.id : files.id
      // }`;
    },
    handlePreview1(file) {
      // console.log(file);
      window.location.href = `${FileApi}/file/download?id=${
        file.response ? file.response.data.id : file.id
      }`;
    },
  },
  created() {
    if (this.$route.query.status) {
      this.auditShow = true;
      this.reviewType = false;
    } else {
      this.auditShow = false;
      this.reviewType = true;
    }
    this.initProvince();
    this.getInfo();
  },
};
</script>

<style scoped lang="scss">
.content-main {
  margin: 10px 10px 0;
  padding-top: 20px;
}

.span-inline-block {
  float: left;
  margin-right: 5px;
  width: 80px;
  text-align: right;
  line-height: 30px;
}

.inputWidth {
  width: 80%;
}

.sub_title {
  width: 98%;
  text-align: center;
  font-size: 1em;
  line-height: 2.5em;
  color: #fff;
  background-color: #49a2fa;
  box-sizing: border-box;
  margin-bottom: 20px;
  position: relative;
  cursor: pointer;
  &.sub_title__icon_arrow_down {
    .el-icon-arrow-up {
      transform: rotate(180deg);
    }
  }
  .el-icon-arrow-up {
    transition: transform 0.3s;
    position: absolute;
    right: 0.5em;
    font-size: 1.6em;
    line-height: 1.6em;
  }
}

.el-form {
  overflow: hidden;
  overflow-y: auto;
}

.el-row {
  .el-tooltip {
    float: left;
    padding: 0 12px 0 0;
    width: 118px;
    white-space: nowrap;
    text-align: right;
    vertical-align: middle;
    color: #525357;
    font-size: 14px;
    line-height: 40px;
    box-sizing: border-box;
  }
}
.chb_box {
  /deep/ .el-checkbox {
    min-width: 150px;
  }
}
/deep/ .el-select {
  display: inline-block !important;
}
</style>
