<template>
	<el-form class="content-main" label-width="200px" :data="formQuery">
        <el-row>
			<el-col :span="24">
				<h3 class="h3">仓房基本信息</h3>
			</el-col>
		</el-row>
        <el-row>
			<el-col :span="12">
				<el-form-item label="仓房编码:">
					<el-input class="inputWidth" disabled readonly = "readonly" placeholder="系统自动生成" v-model="formQuery.cfbh"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="仓房序号:">
					<el-select clearable class="inputWidth" @change="cfxhChange" disabled v-model="formQuery.cfxh" placeholder="请选择">
						<el-option
						v-for="item in cfxhOptions"
						:key="item.dictCode"
						:label="item.dictName"
						:value="item.dictCode">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="廒间序号:">
					<el-input class="inputWidth" disabled v-model="formQuery.ajxh"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="货位序号:">
					<el-input class="inputWidth" disabled v-model="formQuery.hwxh"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="仓房名称:">
					<el-input class="inputWidth" disabled v-model="formQuery.cfmc"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="建设时间:">
					<el-date-picker class="inputWidth" style="width: 335px;" disabled v-model="formQuery.jssj"  type="date" value-format="yyyy-MM-dd HH:mm:ss" placeholder="选择日期"></el-date-picker>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="交付使用日期:">
					<el-date-picker class="inputWidth" style="width: 335px;" disabled v-model="formQuery.jfsyrq"  type="date" value-format="yyyy-MM-dd HH:mm:ss" placeholder="选择日期"></el-date-picker>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="仓(罐)型:">
					<el-select clearable class="inputWidth"  disabled v-model="formQuery.cflx" placeholder="请选择">
						<el-option
						v-for="item in cxOptions"
						:key="item.dictName"
						:label="item.dictName"
						:value="item.dictName">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="单仓仓容(吨):">
					<el-input class="inputWidth" disabled v-model="formQuery.dczlrj"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="防雨防潮性能:">
					<el-select class="inputWidth" disabled v-model="formQuery.fyfcxn" placeholder="请选择">
						<el-option
						v-for="item in optionsStr"
						: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="12">
				<el-form-item label="密闭杀虫性能:">
					<el-select class="inputWidth" disabled v-model="formQuery.mbscxn" placeholder="请选择">
						<el-option
						v-for="item in optionsStr"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="隔热保冷性能:">
					<el-select class="inputWidth" disabled v-model="formQuery.grblxn" placeholder="请选择">
						<el-option
						v-for="item in optionsStr"
						: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="12">
				<el-form-item label="能否散装存储:">
					<el-select class="inputWidth" disabled v-model="formQuery.sfszcc" placeholder="请选择">
						<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="12">
				<el-form-item label="有无机械通风设施:">
					<el-select class="inputWidth" disabled v-model="formQuery.ywjxtfss" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="能否环流熏蒸杀虫:">
					<el-select class="inputWidth" disabled v-model="formQuery.nfxlsc" placeholder="请选择">
						<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="12">
				<el-form-item label="有无粮情测控情况:">
					<el-select class="inputWidth" disabled v-model="formQuery.ywlqckqk" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="仓房使用情况:">
					<el-select class="inputWidth" disabled v-model="formQuery.cfsyqk" placeholder="请选择">
						<el-option
						v-for="item in options2"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="低温仓类型:" prop="dwclx">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.dwclx" placeholder="请选择">
						<el-option
						v-for="item in dwcOptions"
						: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="24">
				<h3 class="h3">结构</h3>
			</el-col>
		</el-row>
		<el-row>
            <el-col :span="12">
				<el-form-item label="墙体:">
					<el-input class="inputWidth" disabled v-model="formQuery.cfqt"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="墙体厚度(厘米):">
					<el-input class="inputWidth" disabled v-model="formQuery.qthd"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
        <el-row>
            <el-col :span="12">
				<el-form-item label="屋面:">
					<el-input class="inputWidth" disabled v-model="formQuery.cfwm"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="地面:">
					<el-input class="inputWidth" disabled v-model="formQuery.cfdm"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="设计仓容(吨):">
					<el-input class="inputWidth" disabled v-model="formQuery.sjcr"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="檐高(米):">
					<el-input class="inputWidth" disabled v-model="formQuery.cfyg"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
        <el-row>
			<el-col :span="24">
				<h3 class="h3">仓内</h3>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="设计装粮高度(米):">
					<el-input class="inputWidth" disabled v-model="formQuery.zlxgd"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="筒仓内径(米):">
					<el-input class="inputWidth" disabled v-model="formQuery.tczj"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="长(米):">
					<el-input class="inputWidth" disabled v-model="formQuery.cfnc"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="宽(米):">
					<el-input class="inputWidth" disabled v-model="formQuery.cfnk"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row>
			<el-col :span="24">
				<h3 class="h3">其他</h3>
			</el-col>
		</el-row>
		<el-row class="warehouseDoorVOList">
			<!-- <el-form-item label="" prop="workOffice"> -->
            <el-table :data="formQuery.warehouseDoorVOList"  :key="tableKey"  border  fit  highlight-current-row  style="width: 98%;margin-bottom:25px">
                <el-table-column align="center" label="库门名称">
                    <template slot-scope="scope">
						<el-form :model="scope.row">
							<el-form-item prop="cmmc">
								<el-input v-model="scope.row.cmmc" disabled></el-input>
							</el-form-item>
						</el-form>
                    </template>
                </el-table-column>
                <el-table-column align="center" label="库门高度(米)">
                    <template slot-scope="scope">
						<el-form :model="scope.row">
							<el-form-item prop="cmgd" :rules="[{ required: false, message: '请填写库门高度，仅限两位小数',validator: validateUsername},{pattern:/^\d{1,2}(\.\d{1,2})?$/, message: '库门高度精确到两位小数点'}]">
								<el-input v-model="scope.row.cmgd" style="width:100%" disabled></el-input>
							</el-form-item>
						</el-form>
                    </template>
                </el-table-column>
                <el-table-column align="center" label="库门宽度(米)">
                    <template slot-scope="scope">
						<el-form :model="scope.row">
							<el-form-item prop="cmkd" :rules="[{ required: false, message: '请填写库门宽度，仅限两位小数'},{pattern:/^\d{1,2}(\.\d{1,2})?$/, message: '库门宽度精确到两位小数点'}]">
								<el-input v-model="scope.row.cmkd" style="width:100%" disabled></el-input>
							</el-form-item>
						</el-form>
                    </template>
                </el-table-column>
                <!-- <el-table-column align="center" fixed="right"  label="操作" width="100">
                    <template slot-scope="scope">
                      <el-button @click="addZJ()" size="mini" title="添加" type="text" class="el-icon-plus"> </el-button>
                    <el-button @click="deleteNodeBtn(scope.$index)" size="mini" title="删除" disabled type="text" class="el-icon-minus">
                    </el-button>
                    </template>
                </el-table-column> -->
            </el-table>
        <!-- </el-form-item> -->
		</el-row>
		<el-row>
			<el-col :span="12">
				<el-form-item label="通风操作:">
					<el-select class="inputWidth" disabled v-model="formQuery.tffs" 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="12">
				<el-form-item label="屋面隔热:">
					<el-select class="inputWidth" disabled v-model="formQuery.grfs" 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="12">
				<el-form-item label="墙体隔热:">
					<el-select class="inputWidth" disabled v-model="formQuery.qtgr" 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="12">
				<el-form-item label="控温措施:">
					<el-select class="inputWidth" disabled v-model="formQuery.kwcs" 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>
		<el-row>
			<el-col :span="12">
				<el-form-item label="仓门保温:">
					<el-select class="inputWidth" disabled v-model="formQuery.dwc" 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-col :span="12">
				<el-form-item label="窗户保温:">
					<el-select class="inputWidth" disabled v-model="formQuery.chbw" placeholder="请选择">
						<el-option
						v-for="item in options8"
						: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="12">
				<el-form-item label="保温门:" prop="bwm">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.bwm" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="保温窗:" prop="bwc">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.bwc" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="双层保温窗:" prop="scbwc">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.scbwc" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="外控内开窗:" prop="wknkc">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.wknkc" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="仓内吊顶:" prop="cndd">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.cndd" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="仓内保温吊顶:" prop="cdbwdd">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.cdbwdd" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="隔层排积热:" prop="gcpjr">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.gcpjr" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="仓顶外隔热层:" prop="cdwgrc">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.cdwgrc" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="保温墙体:" prop="bwqt">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.bwqt" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="保温涂料:" prop="bwtl">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.bwtl" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="制冷设备:" prop="zlsb">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.zlsb" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="地笼通风:" prop="dltf">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.dltf" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="轴流风机:">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.zlfj" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="电子测温:" prop="dzcw">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.dzcw" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="自动流粮口:" prop="zdllk">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.zdllk" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="环流熏蒸:" prop="hlxz">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.hlxz" placeholder="请选择">
						<el-option
						v-for="item in options1"
						: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="12">
				<el-form-item label="内环流:" prop="cnhl">
					<el-select clearable class="inputWidth" disabled v-model="formQuery.cnhl" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item clearable label="仓内摄像头:" prop="cnsxt">
					<el-select class="inputWidth" disabled v-model="formQuery.cnsxt" placeholder="请选择">
						<el-option
						v-for="item in options1"
						:key="item.value"
						:label="item.label"
						:value="item.value">
						</el-option>
					</el-select>
				</el-form-item>
			</el-col>
		</el-row>
		<el-row v-if="isChecked">
			<el-col :span="24">
				<h3 class="h3">审批信息</h3>
			</el-col>
		</el-row>
		<el-row v-if="isChecked">
			<el-col :span="24">
				<el-form-item label="审批:">
					<el-radio v-model="formQuery.sfba" :disabled="showLock" :label="5">通过</el-radio>
  					<el-radio v-model="formQuery.sfba" :disabled="showLock" :label="3">驳回</el-radio>
				</el-form-item>
			</el-col>
			<el-col :span="24">
				<el-form-item label="审核意见:">
					<el-input style="width:90%" :disabled="showLock" v-model="formQuery.shyj"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="审核人:">
					<el-input disabled style="width:80%" v-model="formQuery.shrmc"></el-input>
				</el-form-item>
			</el-col>
			<el-col :span="12">
				<el-form-item label="审核时间:">
					<el-input disabled style="width:80%" v-model="formQuery.shsj"></el-input>
				</el-form-item>
			</el-col>
		</el-row>
    <el-col :span="24">
        <div style="text-align:center;margin-top:20px">
            <el-button type="primary" icon="iconfont icontijiao" v-if="!showLock" @click="saveSubmit()">保存</el-button>
			<el-button type="primary" icon="iconfont iconfanhui" @click="cancel">返回</el-button>
        </div>
        </el-col>
	</el-form>

</template>

<script>
import {
  detailsFn,
  addFn,
  editFn,
  dataDictionary
} from '@/api/jcxxwh/cfxx'
import { getNowDate } from '@/utils'
export default {
	name: "slqyxxsb",
	data() {
		const validateUsername = (rule, value, callback) => {
        if (value > 3) {
			alert(2)
          callback(new Error("请输入正确的用户名"));
        } else {
          callback();
        }
      };
		return {
			showLock: false,
			formQuery: {
				cfbh:"",
        shyj:'',
				warehouseDoorVOList:[{}]
			},
			tableKey:'',
			isChecked:true,
			options: [{
			value: 1,
			label: '能'
			}, {
			value: 0,
			label: '否'
			}],
			optionsStr: [{
			value: '1',
			label: '有'
			}, {
			value: '0',
			label: '无'
			}],
			options1: [{
			value: 1,
			label: '有'
			}, {
			value: 0,
			label: '无'
			}],
			options2: [{
			value: 0,
			label: '空闲中'
			}, {
			value: 1,
			label: '使用中'
			}, {
			value: 2,
			label: '已停用'
			}],
			options3: [{
			value: 0,
			label: '自然通风'
			}, {
			value: 1,
			label: '轴流通风'
			}, {
			value: 2,
			label: '离心通风'
			}, {
			value: 3,
			label: '单管通风'
			}],
			options4: [{
			value: 0,
			label: '双层屋面'
			}, {
			value: 1,
			label: '仓内吊顶'
			}, {
			value: 2,
			label: '保温隔热涂料'
			}],
			options5: [{
			value: 0,
			label: '保温隔热涂料'
			}, {
			value: 1,
			label: '墙体增厚'
			}],
			options6: [{
			value: 0,
			label: '内环流'
			}, {
			value: 1,
			label: '空调'
			}],
			options7: [{
			value: 0,
			label: '单层'
			}, {
			value: 1,
			label: '双层'
			}],
			options8: [{
			value: 0,
			label: '单层'
			}, {
			value: 1,
			label: '双层'
			}, {
			value: 2,
			label: '三层'
			}],
			dwcOptions:[{
			value: 1,
			label: '低温仓'
			},{
			value: 2,
			label: '准低温箱'
			},{
			value: 3,
			label: '普通仓'
			},{
			value: 4,
			label: '保温仓'
			}],
			cfxhOptions:[],
			cxOptions:[]
		};
	},
	methods: {
		getInfo(code) {
			detailsFn(code).then(res => {
				this.formQuery = res.data;
				this.formQuery.tffs = this.formQuery.tffs ? Number(this.formQuery.tffs) : this.formQuery.tffs
				this.formQuery.grfs = this.formQuery.grfs? Number(this.formQuery.grfs) : this.formQuery.grfs
				this.formQuery.kwcs = this.formQuery.kwcs ? Number(this.formQuery.kwcs) : this.formQuery.kwcs
				if(this.formQuery.ajxh.slice(1) == '-0'){
					this.formQuery.ajxh = '无'
				}
				if(this.$route.query.status == 'edit'){
					this.formQuery.sfba = 5;
					this.formQuery.shrmc = sessionStorage.getItem("userName")
					this.formQuery.shsj = getNowDate(new Date());
					this.formQuery.shyj = ""
				}

			})
		},
		// 库门的动态添加
		addZJ() {
		const newList = {
			cmmc:'',
			cmgd:'',
			cmkd:''
		}
		this.formQuery.warehouseDoorVOList.push(newList)
		},
		// 库门的动态删除
		deleteNodeBtn(i) {
		this.formQuery.warehouseDoorVOList.splice(i, 1)
		},
		saveSubmit() {
			this.formQuery.tyshxydm = sessionStorage.getItem('tyshxydm');
					editFn(this.formQuery).then(res => {
						if(res.infoCode == 200){
							this.$message({
								message: '审核成功',
								type: 'success'
							});
							this.$router.push({path:'/jcxxsh/cfxxsh'})
						}else{
							this.$message({
								message: '审核失败',
								type: 'error'
							});
						}
					})
		},
		cancel(){
			this.$router.push({path:'/jcxxsh/cfxxsh'})
		}
	},
	created() {
		if(this.$route.query.status == 'detail'){
			this.showLock = true
			this.getInfo(this.$route.query.cfbhNum)
		}else if(this.$route.query.status == 'edit'){
			this.showLock = false
			this.getInfo(this.$route.query.cfbhNum)
		}else{
			this.showLock = false
		}
		dataDictionary('5472').then(res=>{
			if(res.infoCode == 200){
				this.cfxhOptions = res.data;
			}
		})
		dataDictionary('5473').then(res=>{
			if(res.infoCode == 200){
				this.cxOptions = res.data;
			}
		})
	}
};
</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: 335px;
}

.h3 {
	width: 98%;
	text-align: center;
	font-size: 1em;
	line-height: 2.5;
	color: #fff;
	background-color: #49a2fa;
  margin-bottom: 20px
}

.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;
	}
}

.warehouseDoorVOList .el-form-item{
	margin:0!important
}
</style>
