<template>
    <div id="main-contain">
      <div class="position">
        <bread-crumb :crumbs='crumbs'></bread-crumb>
      </div>
      <div class="app-container">
          <div style="float: left; margin-bottom: 10px;">
            <el-date-picker
              v-model="startvalue"
              value-format="yyyy-MM-dd"
              type="date"
              placeholder="选择日期"
              style="width: 150px;">
            </el-date-picker>
            <span>-</span>
            <el-date-picker
              v-model="endvalue"
              type="date"
              placeholder="选择日期"
              style="width: 150px;"
              value-format="yyyy-MM-dd">
            </el-date-picker>
            <el-select v-model="storey" placeholder="请选择楼层" v-if="art_way_one==0||art_way_one == 1"  @chang="changeStore">
                <el-option
                v-for="(item,index) in storeyList"
                :key="index"
                :label="item.name"
                :value="item.name">
                </el-option>
             </el-select>
            <el-button type="primary" style="margin-left: 10px;" @click="toSeach">搜索</el-button>
          </div>
          <div style="float:right;margin-bottom:10px;">
            <el-button type="primary" @click="toSetting">设置</el-button>
            <el-button type="primary" @click="printCard" v-if="art_way_one==0 || art_way_one ==1">打印</el-button>
            <el-button type="primary" @click="printCardOne" v-if=" art_way_one ==2">打印</el-button>
            <el-button type="primary" @click="dialogFormVisible = true" v-if="art_way_one == 0 || art_way_one == 1">新增</el-button>
            <el-button type="primary" @click="newdialogFormVisible = true" v-if="art_way_one == 2">新增</el-button>
          </div>
          <div class="tab_air" v-if="art_way_one == 0 || art_way_one ==1">
            <el-table  :data="tableData" :fit="true" stripe>
               
                <el-table-column prop="year" label="名称" width="150" align="center">
                    <el-table-column prop="year" label="消毒时间" align="center" width="150">
                        <el-table-column prop="year" label="日期" align="center" width="150">
                            <template slot-scope="scope">
                                {{getTimes(scope.row.record_date) }}
                            </template>
                          
                        </el-table-column>
                    </el-table-column>
                </el-table-column>
                <el-table-column label="楼层" width="100" align="center">
                    <template  slot-scope="scope">
                        {{ scope.row.storey }}
                    </template>
                </el-table-column>
                <el-table-column prop="fenopda" :label="'湿化瓶'+'\n'+'500mg/l含氯制剂'" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{ getTimeTwo(scope.row.first_start_time) }} - {{ getTimeTwo(scope.row.first_end_time) }}
                       
                    </template>
                </el-table-column>
                <el-table-column prop="dwaiod" label="责任人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.first_creator)}}

                     
                    </template>
                </el-table-column>

                <el-table-column prop="date" :label="'止血带'+'\n'+'500mg/l含氯制剂'" align="center" min-width="60">
                    <template slot-scope="scope">
                        <!-- {{scope.row.sencond_total_time?scope.row.sencond_total_time:""}} -->
                        <!-- {{ scope.row.sencond_disinfection_time }} -->
                        {{ getTimeTwo(scope.row.sencond_start_time) }} - {{ getTimeTwo(scope.row.sencond_end_time) }}
                    </template>
                </el-table-column>
                <el-table-column prop="name" label="责任人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.sencond_creator)}}
                       
                    </template>
                </el-table-column>

                <el-table-column prop="province" :label="'医疗垃圾桶'+'\n'+'1000mg/l含氯制剂'" align="center" min-width="60">
                    <template slot-scope="scope">
                        <!-- {{scope.row.third_total_time?scope.row.third_total_time:""}} -->
                        <!-- {{ scope.row.third_disinfection_time }} -->
                        {{ getTimeTwo(scope.row.third_start_time) }} - {{ getTimeTwo(scope.row.third_end_time) }}
                    </template>
                </el-table-column>
                <el-table-column prop="city" label="负责人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.third_creator)}}

                   
                    </template>
                </el-table-column>

                <el-table-column prop="name" :label="'体温计'+'\n'+'75%酒精浸泡'" align="center" min-width="60">
                    <template slot-scope="scope">
                        <!-- {{scope.row.fourth_total_time?scope.row.fourth_total_time:""}} -->
                        <!-- {{ scope.row.fourth_disinfection_time }} -->
                        {{ getTimeTwo(scope.row.fourth_start_time) }} - {{ getTimeTwo(scope.row.fourth_end_time) }} 
                    </template>
                </el-table-column>
                <el-table-column prop="province" label="负责人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.fourth_creator)}}
                    
                  
                    </template>
                </el-table-column>

                <el-table-column prop="city" :label="'体温枪'+'\n'+'75%酒精擦拭'" align="center" min-width="60">
                    <template slot-scope="scope">
                        <!-- {{scope.row.fourth_total_time?scope.row.fourth_total_time:""}} -->
                        <!-- {{ scope.row.last_disinfection_time }} -->
                        {{ getTimeTwo(scope.row.last_start_time) }} - {{ getTimeTwo(scope.row.last_end_time) }} 
                    </template>
                </el-table-column>
                <el-table-column prop="province" label="负责人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.last_creator)}}

                    
                    </template>
                </el-table-column>
                <el-table-column prop="city" label="操作" align="center" min-width="100">
                    <template slot-scope="scope">
                        <el-button
                        size="mini"
                        type="primary"
                        @click="handleEdit(scope.row.id)">编辑</el-button>
                        <el-button
                        size="mini"
                        type="danger"
                        @click="handleDelete(scope.row.id)">删除</el-button>
                    </template>
                </el-table-column>
            </el-table>
            <el-pagination
              :page-sizes="[10, 20, 50, 100]"
              :page-size="10"
              background
              style="margin-top:20px;float: right"
              layout="total, sizes, prev, pager, next, jumper"
              :total="total"
              @size-change="handleSizeChange"
              @current-change="handleCurrentChange"
          >
            
          </el-pagination>
         </div>

         <div  v-if="art_way_one == 2">
            <el-table  :data="tableDataOne" :fit="true" stripe   style="width: 100%"
                row-key="id"
                border
                lazy
                :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
               
            <el-table-column prop="year" label="消毒日期" align="center" width="150">
                <template slot-scope="scope">
                    {{getTimes(scope.row.record_date) }}
                </template>
                
            </el-table-column>

            <el-table-column prop="year" label="消毒物品" align="center" width="150">
                <template slot-scope="scope">
                  {{scope.row.department  }} 
                </template>
                
            </el-table-column>
                   
             
                <el-table-column prop="fenopda" :label="'500mg/l含氯制剂'" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{ getTimeTwo(scope.row.first_start_time) }} - {{ getTimeTwo(scope.row.first_end_time) }}
                       
                    </template>
                </el-table-column>
                <el-table-column prop="dwaiod" label="责任人" align="center" min-width="60">
                    <template slot-scope="scope">
                        {{getName(scope.row.first_creator)}}

                     
                    </template>
                </el-table-column>

              

                <el-table-column prop="city" label="操作" align="center" min-width="100">
                    <template slot-scope="scope">
                        <el-button
                        size="mini"
                        type="primary"
                        @click="handleEditOne(scope.row.id)">编辑</el-button>
                        <el-button
                        size="mini"
                        type="danger"
                        @click="handleDeleteOne(scope.row.id)">删除</el-button>
                    </template>
                </el-table-column>
            </el-table>
            <el-pagination
              :page-sizes="[10, 20, 50, 100]"
              :page-size="10"
              background
              style="margin-top:20px;float: right"
              layout="total, sizes, prev, pager, next, jumper"
              :total="total"
              @size-change="handleSizeChangeOne"
              @current-change="handleCurrentChangeOne"
          >
            
          </el-pagination>
         </div>

         <!-- 新增 -->
          <el-dialog
          class="centerDialog"
          width="1000px"
          title="新增物表消毒表"
          :visible.sync="dialogFormVisible">
              <el-form :model="form" ref="form" class="airForm" :rules="airRules">
                  <div style="width: 100%;">
                    <el-form-item label="创建日期" label-width="110px" required prop="record_date">
                        <el-date-picker
                        value-format="yyyy-MM-dd"
                        v-model="form.record_date"
                        type="date"
                        placeholder="选择日期时间">
                        </el-date-picker>
                    </el-form-item>
                  </div>
                  <div style="width: 100%;">
                    <el-form-item label="楼层">
                        <el-select v-model="form.storey" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in storeyList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                    </el-form-item>
                  </div>
                  <div class="form_title"><span >湿化瓶</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_methods"></el-input> -->
                      <el-select v-model="form.first_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_water"></el-input> -->
                      <el-select v-model="form.first_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.first_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_start_time"
                        @change="firststartime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_end_time"
                        @change="firstendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.first_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.first_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.first_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px" >
                      <el-select v-model="form.first_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.first_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >止血带</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.sencond_disinfection_methods"></el-input> -->
                      <el-select v-model="form.sencond_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.sencond_disinfection_water"></el-input> -->
                      <el-select v-model="form.sencond_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.sencond_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.sencond_start_time"
                        @change="sencondstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item> 
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.sencond_end_time"
                        @change="sencondendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.sencond_total_time"></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.sencond_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.sencond_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.sencond_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px" >
                      <el-select v-model="form.sencond_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >医疗垃圾桶</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.third_disinfection_methods"></el-input> -->
                      <el-select v-model="form.third_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.third_disinfection_water"></el-input> -->
                      <el-select v-model="form.third_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.third_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.third_start_time"
                        @change="thirdstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.third_end_time"
                        @change="thirdendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.third_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px" >
                      <div>
                          <el-radio v-model="form.third_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.third_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.third_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.third_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >体温计</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.fourth_disinfection_methods"></el-input> -->
                      <el-select v-model="form.fourth_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.fourth_disinfection_water"></el-input> -->
                      <el-select v-model="form.fourth_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.fourth_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.fourth_start_time"
                        @change="fourthstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.fourth_end_time"
                        @change="fourthendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.fourth_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.fourth_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.fourth_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.fourth_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.fourth_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >体温枪</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.last_disinfection_methods"></el-input> -->
                      <el-select v-model="form.last_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.last_disinfection_water"></el-input> -->
                      <el-select v-model="form.last_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.last_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.last_start_time"
                        @change="laststarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.last_end_time"
                        @change="lastendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.last_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.last_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.last_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.last_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.last_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>
              </el-form>
              <div slot="footer" class="dialog-footer">
                  <el-button @click="dialogFormVisible = false">取 消</el-button>
                  <el-button type="primary" @click="saveObjectTableDisinfect('form')">保 存</el-button>
              </div>
          </el-dialog>

          <!-- 编辑 -->
          <el-dialog
          class="centerDialog"
          width="1000px"
          title="编辑物表消毒表"
          :visible.sync="editDialogFormVisible">
          <el-form :model="form" ref="form" class="airForm" :rules="airRules">
                  <div style="width: 100%;">
                    <el-form-item label="创建日期" label-width="110px" required prop="record_date">
                        <el-date-picker
                        value-format="yyyy-MM-dd"
                        v-model="form.record_date"
                        type="date"
                        placeholder="选择日期时间">
                        </el-date-picker>
                    </el-form-item>
                  </div>
                  <div style="width: 100%;">
                    <el-form-item label="楼层">
                        <el-select v-model="form.storey" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in storeyList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                    </el-form-item>
                  </div>
                  <div class="form_title"><span >湿化瓶</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_methods"></el-input> -->
                      <el-select v-model="form.first_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_water"></el-input> -->
                      <el-select v-model="form.first_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.first_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_start_time"
                        @change="firststartime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_end_time"
                        @change="firstendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.first_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.first_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.first_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px" >
                      <el-select v-model="form.first_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.first_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >止血带</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.sencond_disinfection_methods"></el-input> -->
                      <el-select v-model="form.sencond_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.sencond_disinfection_water"></el-input> -->
                      <el-select v-model="form.sencond_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.sencond_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.sencond_start_time"
                        @change="sencondstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item> 
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.sencond_end_time"
                        @change="sencondendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.sencond_total_time"></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.sencond_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.sencond_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.sencond_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px" >
                      <el-select v-model="form.sencond_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >医疗垃圾桶</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.third_disinfection_methods"></el-input> -->
                      <el-select v-model="form.third_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.third_disinfection_water"></el-input> -->
                      <el-select v-model="form.third_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.third_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.third_start_time"
                        @change="thirdstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.third_end_time"
                        @change="thirdendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.third_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px" >
                      <div>
                          <el-radio v-model="form.third_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.third_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.third_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.third_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >体温计</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.fourth_disinfection_methods"></el-input> -->
                      <el-select v-model="form.fourth_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.fourth_disinfection_water"></el-input> -->
                      <el-select v-model="form.fourth_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.fourth_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.fourth_start_time"
                        @change="fourthstarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.fourth_end_time"
                        @change="fourthendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.fourth_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.fourth_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.fourth_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.fourth_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.fourth_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>

                  <div class="form_title"><span >体温枪</span></div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.last_disinfection_methods"></el-input> -->
                      <el-select v-model="form.last_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.last_disinfection_water"></el-input> -->
                      <el-select v-model="form.last_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.last_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.last_start_time"
                        @change="laststarttime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.last_end_time"
                        @change="lastendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <!-- <el-form-item label="累计时间(h)" label-width="110px">
                      <el-input v-model= "form.last_total_time"  ></el-input>
                  </el-form-item> -->
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.last_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.last_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px">
                      <el-select v-model="form.last_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.last_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>
              </el-form>
              <div slot="footer" class="dialog-footer">
                  <el-button @click="editDialogFormVisible = false">取 消</el-button>
                  <el-button type="primary" @click="updateObjectTableDisinfect('form')">保 存</el-button>
              </div>
          </el-dialog>
         

          <div hidden="hidden">
            <div id="print-card-info" v-show="hiddenShow">
                <div>
                    <h1 style="text-align: center;">物表消毒登记</h1>
                    <div>
                        <table border="1" style="text-align: center;margin: auto;border-collapse: collapse;">
                            <tr>
                                <td style="position: relative;box-sizing: border-box;width: 107px;
                                height: 80px;">
                                    <span style="position: absolute; right: 10px; top: 10px; font-size: 12px;">名称</span>

                                    <span style="position: absolute; display: block; top: 0; left: 46px; width: 100px;
                                    border-bottom:1px solid black ;transform: rotate(52deg); 
                                    transform-origin: top left;"></span>

                                    <span style="position: absolute; right: 45px; top: 23px;font-size: 12px;">消毒 <br/>时间</span>
                                    <span style="position: absolute; display: block; top: 46px; left: 0; width: 113px;
                                     border-bottom:1px solid black ;transform: rotate(17deg); 
                                    transform-origin: top left;"></span>
                                    <span style="position: absolute; left: 6px; bottom: 6px;font-size: 12px;">日期</span>
                                </td>
                                <td>楼层</td>
                                <td>湿化瓶<br/>500mg/l含氯制剂</td>
                                <td>负责人</td>
                                <td width="40">消毒液浓度合格<br/></td>
                                <td>止血带<br/>500mg/l含氯制剂</td>
                                <td>负责人</td>
                                <td width="40">消毒液浓度合格<br/></td>
                                <td>医疗垃圾桶<br/>1000mg/l含<br/>氯制剂</td>
                                <td>负责人</td>
                                <td width="40">消毒液浓度合格<br/></td>
                                <td>体温计<br/>75%酒精浸泡</td>
                                <td>负责人</td>
                                <td width="40">消毒液浓度合格<br/></td>
                                <td>体温枪<br/>75%酒精擦拭</td>
                                <td>负责人</td>
                                <td width="40">消毒液浓度合格<br/></td>
                               
                            </tr>

                            <tr v-for="(item,index) in tableData" :key="index">
                                <td>{{item.storey }}</td>
                                <td>{{getTimes(item.record_date) }}</td>
                                <td>{{getTimeTwo( item.first_start_time)}}- {{getTimeTwo(item.first_end_time)  }}</td>
                                <td>
                                <span v-if="setAdminUserES(item.first_creator?item.last_creator:item.first_creator) == ''">
                                   {{getName(item.first_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.last_creator?item.last_creator:item.last_creator)" alt="" srcset="">
                                </span>   
                                </td>

                                <td>是<br/></td>

                                <td>{{getTimeTwo(item.sencond_start_time) }} - {{getTimeTwo( item.sencond_end_time) }}</td>
                                <td>
                                 <span v-if="setAdminUserES(item.sencond_creator?item.sencond_creator:item.sencond_creator) == ''">
                                   {{getName(item.sencond_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.sencond_creator?item.sencond_creator:item.sencond_creator)" alt="" srcset="">
                                </span>   
                                </td>
                                <td>是<br/></td>
                                <td>{{getTimeTwo(item.third_start_time) }} - {{getTimeTwo(item.third_end_time)  }}</td>
                                <td>
                                    <span v-if="setAdminUserES(item.third_creator?item.third_creator:item.third_creator) == ''">
                                   {{getName(item.third_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.third_creator?item.third_creator:item.third_creator)" alt="" srcset="">
                                </span>   
                                </td>

                                <td>是<br/></td>
                                <td>{{getTimeTwo(item.fourth_start_time)  }} - {{getTimeTwo(item.fourth_end_time)  }}</td>
                                <td>
                                    <span v-if="setAdminUserES(item.fourth_creator?item.fourth_creator:item.fourth_creator) == ''">
                                   {{getName(item.fourth_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.fourth_creator?item.fourth_creator:item.fourth_creator)" alt="" srcset="">
                                </span>   
                                </td>
                                <td>是<br/></td>
                                <td>{{getTimeTwo(item.last_start_time) }} - {{getTimeTwo( item.last_end_time) }}</td>
                                <td>
                                    <span v-if="setAdminUserES(item.last_creator?item.last_creator:item.last_creator) == ''">
                                   {{getName(item.last_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.last_creator?item.last_creator:item.last_creator)" alt="" srcset="">
                                </span>   
                                </td>
                                <td>是<br/></td>
                            </tr>
                         </table>   

                    </div>
                </div>
            </div>
         </div>


         <div hidden="hiddenShowOne">
            <div id="print-card-info_one" v-show="hiddenShowOne">
                <div>
                    <h1 style="text-align: center;">物表消毒登记</h1>
                    <div>
                        <table border="1" style="text-align: center;margin: auto;border-collapse: collapse;">
                            <tr>
                               <td>消毒时间</td>
                               <td>消毒物品</td>
                                <td>500mg/l含氯制剂</td>
                                <td>负责人</td>
                            </tr>

                            <tr v-for="(item,index) in tableDataOne" :key="index">
                                <td>{{getTimes(item.record_date) }}</td>
                                <td>{{item.department}}</td>
                                <td>{{getTimeTwo( item.first_start_time)}}- {{getTimeTwo(item.first_end_time)  }}</td>
                                <td>
                                <span v-if="setAdminUserES(item.first_creator?item.last_creator:item.first_creator) == ''">
                                   {{getName(item.first_creator)}}
                                  </span>
                                <span v-else>
                                    <img style="height:30px;" :src="setAdminUserES(item.last_creator?item.last_creator:item.last_creator)" alt="" srcset="">
                                </span>   
                                </td>
                            </tr>
                         </table>   

                    </div>
                </div>
            </div>
         </div>
         
         <el-dialog
            title="请选择版本"
            :visible.sync="setEditDialog"
            width="60%">
            <span>
                <el-radio v-model="air_way" label="1">版本一</el-radio>
                <el-radio v-model="air_way" label="2">版本二</el-radio>
            </span>
            <span slot="footer" class="dialog-footer">
                <el-button @click="setEditDialog = false">取 消</el-button>
                <el-button type="primary" @click="saveSetObjectTable()">保 存</el-button>
            </span>
         </el-dialog>


         <el-dialog
          class="centerDialog"
          width="1000px"
          title="新增物表消毒表"
          :visible.sync="newdialogFormVisible">
              <el-form :model="form" ref="form" class="airForm" :rules="airRules">
                  <div style="width: 100%;">
                    <el-form-item label="创建日期" label-width="110px" required prop="record_date">
                        <el-date-picker
                        value-format="yyyy-MM-dd"
                        v-model="form.record_date"
                        type="date"
                        placeholder="选择日期时间">
                        </el-date-picker>
                    </el-form-item>

                    <el-form-item label="消毒物品" label-width="110px" required prop="department">
                        <el-select v-model="form.department" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disinfectionOfficeList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                        </el-select>
                    </el-form-item>
                  </div>
                  <div class="form_title">
                    <span >
                     {{ form.department }}
                   </span>
                  </div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_methods"></el-input> -->
                      <el-select v-model="form.first_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_water"></el-input> -->
                      <el-select v-model="form.first_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.first_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_start_time"
                        @change="firststartime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_end_time"
                        @change="firstendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                 
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.first_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.first_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px" >
                      <el-select v-model="form.first_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.first_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>
    
              </el-form>
              <div slot="footer" class="dialog-footer">
                  <el-button @click="newdialogFormVisible = false">取 消</el-button>
                  <el-button type="primary" @click="saveObjectWayTableDisinfect('form')">保 存</el-button>
              </div>
          </el-dialog>


        <el-dialog
          class="centerDialog"
          width="1000px"
          title="编辑物表消毒表"
          :visible.sync="editnewdialogFormVisible">
              <el-form :model="form" ref="form" class="airForm" :rules="airRules">
                  <div style="width: 100%;">
                    <el-form-item label="创建日期" label-width="110px" required prop="record_date">
                        <el-date-picker
                        value-format="yyyy-MM-dd"
                        v-model="form.record_date"
                        type="date"
                        placeholder="选择日期时间">
                        </el-date-picker>
                    </el-form-item>

                    <el-form-item label="消毒物品" label-width="110px" required prop="department">
                        <el-select v-model="form.department" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disinfectionOfficeList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                        </el-select>
                    </el-form-item>
                  </div>
                  <div class="form_title">
                    <span >
                     {{ form.department }}
                   </span>
                  </div>
                  <el-form-item label="消毒方式" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_methods"></el-input> -->
                      <el-select v-model="form.first_disinfection_methods" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in DisinfectionMode"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒液" label-width="110px">
                      <!-- <el-input v-model="form.first_disinfection_water"></el-input> -->
                      <el-select v-model="form.first_disinfection_water" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in disInfectionWaterList"
                          :key="index"
                          :label="item.name"
                          :value="item.name">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="消毒时间(h)" label-width="110px">
                      <el-input v-model="form.first_disinfection_time " :disabled="true"></el-input>
                  </el-form-item>
                  <el-form-item label="开始时间" label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_start_time"
                        @change="firststartime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                  <el-form-item label="结束时间"  label-width="110px">
                    <el-date-picker
                        type="datetime"
                        format="yyyy-MM-dd HH:mm"
                        value-format="yyyy-MM-dd HH:mm"
                        placeholder="选择时间"
                        v-model="form.first_end_time"
                        @change="firstendtime"
                        style="width:100%;"
                    ></el-date-picker>
                  </el-form-item>
                 
                  <el-form-item label="检测合格" label-width="110px">
                      <div>
                          <el-radio v-model="form.first_is_check" label="1">是</el-radio>
                          <el-radio v-model="form.first_is_check" label="2">否</el-radio>
                      </div>
                  </el-form-item>
                  <el-form-item label="修改标志" label-width="110px" >
                      <el-select v-model="form.first_modifications" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in options"
                          :key="index"
                          :label="item.name"
                          :value="item.id">
                          </el-option>
                      </el-select>
                  </el-form-item>
                  <el-form-item label="责任人" label-width="110px">
                      <el-select v-model="form.first_creator" placeholder="请选择">
                          <el-option
                          v-for="(item,index) in docList"
                          :key="index"
                          :label="item.user_name"
                          :value="item.admin_user_id">
                          </el-option>
                      </el-select>
                  </el-form-item>
    
              </el-form>
              <div slot="footer" class="dialog-footer">
                  <el-button @click="editnewdialogFormVisible = false">取 消</el-button>
                  <el-button type="primary" @click="updateObjectWayTableDisinfect('form')">保 存</el-button>
              </div>
          </el-dialog>
      </div>
    </div>
  </template>

  <script>
    import print from "print-js";
    import BreadCrumb from '@/xt_pages/components/bread-crumb'
    import { getAllDoctorList,
        saveObjectTableDisinfect,
        getObjectTableDisInfectList,
        getObjectTableDisInfectByIdList,
        updateObjectTableDisinfect, 
        deleteObjectTableDisinfect,
        setObjectDisinfect,
        getObjectWayDisinfect,
        saveObjectWayTableDisinfect,
        getObjectTableDisInfectWayList,
        getObjectTableDisInfectWayByIdList,
        updateObjectWayTableDisinfect,
        deleteObjectTableWayDisinfect
    } from "@/api/device"
    import { getManageMentDataConfig } from '@/utils/data'
    import { uParseTime } from '@/utils/tools'
    const moment = require('moment')
    export default {
      name: 'airDisinfect',
      components: {
        BreadCrumb
      },
      data() {
        return {
          crumbs: [
            { path: false, name: '院感管理' },
            { path: false, name: '透析室物表消毒记录表' }
          ],

          dialogFormVisible:false,
          editDialogFormVisible:false,
          newdialogFormVisible:false,
          editnewdialogFormVisible:false,
          setEditDialog:false,
          startvalue:'',
          endvalue:'',
          form: {
            id:0,
            record_date:moment(new Date()).add('year',0).format("YYYY-MM-DD"), //创建日期
            first_disinfection_water:"",// 消毒液
            first_disinfection_methods:"",//消毒方式
            first_disinfection_time:"",//消毒时长
            first_start_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//开始时间
            first_end_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//结束时间
            first_total_time:"",//累计时间
            first_is_check:"1",//检验合格
            first_modifications:"",//修改标志
            first_creator:this.$store.getters.xt_user.user.id,//第一责任人

            sencond_disinfection_water:"",// 消毒液
            sencond_disinfection_methods:"",//消毒方式
            sencond_disinfection_time:"",//消毒时长
            sencond_start_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//开始时间
            sencond_end_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//结束时间
            sencond_total_time:"",//累计时间
            sencond_is_check:"1",//检验合格
            sencond_modifications:"",//修改标志
            sencond_creator:this.$store.getters.xt_user.user.id,//第一责任人

            third_disinfection_water:"",// 消毒液
            third_disinfection_methods:"",//消毒方式
            third_disinfection_time:"",//消毒时长
            third_start_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//开始时间
            third_end_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//结束时间
            third_total_time:"",//累计时间
            third_is_check:"1",//检验合格
            third_modifications:"",//修改标志
            third_creator:this.$store.getters.xt_user.user.id,//第一责任人

            fourth_disinfection_water:"",// 消毒液
            fourth_disinfection_methods:"",//消毒方式
            fourth_disinfection_time:"",//消毒时长
            fourth_start_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//开始时间
            fourth_end_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//结束时间
            fourth_total_time:"",//累计时间
            fourth_is_check:"1",//检验合格
            fourth_modifications:"",//修改标志
            fourth_creator:this.$store.getters.xt_user.user.id,//第一责任人

            last_disinfection_water:"",// 消毒液
            last_disinfection_methods:"",//消毒方式
            last_disinfection_time:"",//消毒时长
            last_start_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//开始时间
            last_end_time:moment(new Date()).format('YYYY-MM-DD HH:mm'),//结束时间
            last_total_time:"",//累计时间
            last_is_check:"1",//检验合格
            last_modifications:"",//修改标志
            last_creator:this.$store.getters.xt_user.user.id,//第一责任人
            department:"",
            storey:"",
          },
        //   value1:'',
          docList:[],
          options:[
            {id:1,name:"正常"},
            {id:2,name:"撤销"}
          ],
         airRules: {
          created_time:[{required:true,message:"请选择创建时间",trigger:"blur"}],
          start_time:[{required:true,message:"请选择开始时间",trigger:"blur"}],
          end_time:[{required:true,message:"请选择结束时间",trigger:"blur"}]
         },
         limit:10,
         page:1,
         total:0,
         tableData: [],
         hiddenShow:false,
         disInfectionWaterList:[
        //  { id: 1, name: "0.22%季铵盐" },
        //  { id: 2, name: "500mg/l含氯消毒剂" },
        //  { id: 3, name: "1000mg/l含氯消毒剂" },
        //  { id: 4, name: "1500mg/l含氯消毒剂" },
        //  { id: 5, name: "消毒湿巾" },
        //  {  id:6, name:"75%酒精"}
         ],
         DisinfectionMode: [
            // { id: 1, name: "擦拭" },
            // { id: 2, name: "浸泡" },
            // { id: 3, name: "喷洒" }
         ],
         operators: [],
         operatorMaps:{},
         setEditDialog:false,
         air_way:"2",
         disinfectionOfficeList:[],
         tableDataOne:[],
         hiddenShowOne:false,
         art_way_one:0,
         storeyList:[],
         storey:""
        }

      },
      created(){
        var  disinfection_fluid = getManageMentDataConfig('management', 'disinfection_fluid')
      
        for(let i=0;i<disinfection_fluid.length;i++){
          this.disInfectionWaterList.push(disinfection_fluid[i])
        }

        var  disinfection_methods = getManageMentDataConfig('management', 'disinfection_methods')
       
        for(let i=0;i<disinfection_methods.length;i++){
          this.DisinfectionMode.push(disinfection_methods[i])
        }
        var  disinfection_offices = getManageMentDataConfig('management', 'disinfection_object')
        
        for(let i=0;i<disinfection_offices.length;i++){
          this.disinfectionOfficeList.push(disinfection_offices[i])
        }

        var  storey = getManageMentDataConfig('management', 'storey')
        
        for(let i=0;i<storey.length;i++){
          this.storeyList.push(storey[i])
        }
        this.getAllDoctorList()
        this.getObjectTableDisInfectList()
        this.getObjectTableDisInfectWayList()
        this.getObjectWayDisinfect()
      },
      computed:{
        firstdisinfection_time (){
            const firststart= Date.parse(new Date(this.form.first_start_time))
            console.log('开始时间',firststart);
            const firstend= Date.parse(new Date(this.form.first_end_time)) 
            console.log('结束时间',firstend);
            const time_interval = ((firstend - firststart)/(60*60*1000)).toFixed(1)
            console.log('结束时间',time_interval,Math.floor((firstend - firststart)/(60*60*1000)).toFixed(1));           
            return time_interval
        },
        senconddisinfection_time (){
            const sencondstart= Date.parse(new Date(this.form.sencond_start_time))
            const sencondend= Date.parse(new Date(this.form.sencond_end_time))
            const time_interval = ((sencondend - sencondstart)/(60*60*1000)).toFixed(1)
            return time_interval
        },
        thirddisinfection_time (){
            const thirdstart= Date.parse(new Date(this.form.third_start_time))
            const thirdend= Date.parse(new Date(this.form.third_end_time))
            const time_interval = ((thirdend - thirdstart)/(60*60*1000)).toFixed(1)
            return time_interval
        },
        fourthdisinfection_time (){
            const fourthstart= Date.parse(new Date(this.form.fourth_start_time))
            const fourthend= Date.parse(new Date(this.form.fourth_end_time))
            const time_interval = ((fourthend - fourthstart)/(60*60*1000)).toFixed(1)
            return time_interval
        },
        lastdisinfection_time (){
            const laststart= Date.parse(new Date(this.form.last_start_time))
            const lastend= Date.parse(new Date(this.form.last_end_time))
            const time_interval = ((lastend - laststart)/(60*60*1000)).toFixed(1)
            return time_interval
        },
      },
      methods:{
        changeStore(val){
         this.getObjectTableDisInfectList()  
       },  
      printCard() {
        this.hiddenShow = true;
        var ptime = Math.round(new Date().getTime() / 1000);
        this.print_time = uParseTime(ptime, "{y}年{m}月{d}日");

        const style =
            "@media print { .print_main_content { background-color: white; width:960px; margin:0 auto; padding: 0 0 20px 0;font-size:15px } .print_main_content .order_title { text-align: center; font-size: 15px; line-height: 50px;} .print_main_content table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px;font-size:15px } .print_main_content table tbody tr td { border: 1px solid; text-align: center; padding: 10px 8px;font-size:15px } .td_proj_title { font-size: 15px; line-height: 25px;} .td_proj_content { font-size: 15px; line-height: 25px; } .td_align_left { text-align: left; } .print_footnote_panel { font-size: 15px; line-height: 40px; } .print_footnote_panel .proj { display: inline-block; width: 49%; } .print_footnote_panel .proj}";

        setTimeout(() => {
            printJS({
            printable: "print-card-info",
            type: "html",
            style: style,
            scanStyles: false
            });
        }, 1);
       },
       printCardOne(){
        this.hiddenShowOne = true;
        var ptime = Math.round(new Date().getTime() / 1000);
        this.print_time = uParseTime(ptime, "{y}年{m}月{d}日");

        const style =
            "@media print { .print_main_content { background-color: white; width:960px; margin:0 auto; padding: 0 0 20px 0;font-size:15px } .print_main_content .order_title { text-align: center; font-size: 15px; line-height: 50px;} .print_main_content table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px;font-size:15px } .print_main_content table tbody tr td { border: 1px solid; text-align: center; padding: 10px 8px;font-size:15px } .td_proj_title { font-size: 15px; line-height: 25px;} .td_proj_content { font-size: 15px; line-height: 25px; } .td_align_left { text-align: left; } .print_footnote_panel { font-size: 15px; line-height: 40px; } .print_footnote_panel .proj { display: inline-block; width: 49%; } .print_footnote_panel .proj}";

        setTimeout(() => {
            printJS({
            printable: "print-card-info_one",
            type: "html",
            style: style,
            scanStyles: false
            });
        }, 1);
       },
       getTimes(time) {
         return uParseTime(time, '{y}-{m}-{d}')
       },
       getTimeTwo(time) {
         return uParseTime(time, '{h}:{i}')
       },
       getTimeThree(time) {
         return uParseTime(time, '{y}-{m}-{d} {h}:{i}')
       },
       getName(creator){
         var name = ""
         for(let i=0;i<this.docList.length;i++){
          if(creator == this.docList[i].admin_user_id){
             name = this.docList[i].user_name
          }
         }
         return name
       },
        getAllDoctorList(){
          getAllDoctorList().then(response=>{
            if(response.data.state == 1){
               var list = response.data.data.list
               console.log("list222222",list)
               this.docList = list
               this.operators = response.data.data.operators
            }
          })  
        },
        saveObjectTableDisinfect(formName){
          this.$refs[formName].validate((valid=>{
            if(valid){
                if(this.form.first_is_check!=""){
                  this.form.first_is_check = parseInt(this.form.first_is_check) 
                }else{
                    this.form.first_is_check=0
                }

                if(this.form.sencond_is_check!=""){
                  this.form.sencond_is_check = parseInt(this.form.sencond_is_check) 
                }else{
                    this.form.sencond_is_check=0  
                }

                if(this.form.third_is_check!=""){
                  this.form.third_is_check = parseInt(this.form.third_is_check)
                }else{
                    this.form.third_is_check = 0
                }
                
                if(this.form.fourth_is_check!=""){
                  this.form.fourth_is_check = parseInt(this.form.fourth_is_check)
                }else{
                    this.form.fourth_is_check =0  
                }

                if(this.form.last_is_check!=""){
                    this.form.last_is_check = parseInt(this.form.last_is_check)
                }else{
                    this.form.last_is_check = 0
                }


                if(this.form.first_modifications!=""){
                  this.form.first_modifications = parseInt(this.form.first_modifications) 
                }else{
                    this.form.first_modifications=0
                }

                if(this.form.sencond_modifications!=""){
                  this.form.sencond_modifications = parseInt(this.form.sencond_modifications) 
                }else{
                    this.form.sencond_modifications=0  
                }

                if(this.form.third_modifications!=""){
                  this.form.third_modifications = parseInt(this.form.third_modifications)
                }else{
                    this.form.third_modifications = 0
                }
                
                if(this.form.fourth_modifications!=""){
                  this.form.fourth_modifications = parseInt(this.form.fourth_modifications)
                }else{
                    this.form.fourth_modifications =0  
                }

                if(this.form.last_modifications!=""){
                    this.form.last_modifications = parseInt(this.form.last_modifications)
                }else{
                    this.form.last_modifications = 0
                }

                if(this.form.first_start_time == null){
                   this.form.first_start_time = ""
                }

                if(this.form.first_end_time == null){
                   this.form.first_end_time = ""
                }

                if(this.form.sencond_start_time == null){
                   this.form.sencond_start_time = ""
                }

                if(this.form.sencond_end_time == null){
                   this.form.sencond_end_time = ""
                }

                if(this.form.third_start_time == null){
                   this.form.third_start_time = ""
                }

                if(this.form.third_end_time == null){
                   this.form.third_end_time = ""
                }

                if(this.form.fourth_start_time == null){
                   this.form.fourth_start_time = ""
                }

                if(this.form.fourth_end_time == null){
                   this.form.fourth_end_time = ""
                }
              
                if(this.form.last_start_time == null){
                   this.form.last_start_time = ""
                }

                if(this.form.last_end_time == null){
                   this.form.last_end_time = ""
                }
               console.log("param23333333333333333",this.form)
               
              saveObjectTableDisinfect(this.form).then(response=>{
                 if(response.data.state == 1){
                   var objectDisinfect =  response.data.data.objectDisinfect
                   this.$message.success("保存成功!")
                   this.dialogFormVisible = false
                   this.getObjectTableDisInfectList()
                 }
              })
            }
          }))
        },
        getObjectTableDisInfectList(){
             var params = {
                start_time:this.startvalue,
                end_time:this.endvalue,
                limit:this.limit,
                page:this.page,
                storey:this.storey,
             }
             console.log("storey",params)
            getObjectTableDisInfectList(params).then(response=>{
              if(response.data.state == 1){
                var list = response.data.data.list
                this.tableData = list
                this.total = response.data.data.total
              }
            })  
        },
        handleEdit(id){
          getObjectTableDisInfectByIdList(id).then(response=>{
            if(response.data.state == 1){
              var list = response.data.data.list
              console.log("list",list)
              this.form.id = list.id
              this.form.record_date = this.getTimes(list.record_date)
              this.form.first_disinfection_water = list.first_disinfection_water? list.first_disinfection_water:""
              this.form.first_disinfection_methods = list.first_disinfection_methods? list.first_disinfection_methods:""
              this.form.first_disinfection_time = list.first_disinfection_time?list.first_disinfection_time:""
              this.form.first_start_time = this.getTimeThree(list.first_start_time)
              this.form.first_end_time = this.getTimeThree(list.first_end_time)
              this.form.first_total_time = list.first_total_time?list.first_total_time:""
              this.form.first_is_check = list.first_is_check.toString()
              this.form.first_modifications = list.first_modifications?list.first_modifications:""
              this.form.first_creator = list.first_creator
              this.form.sencond_disinfection_water = list.sencond_disinfection_water?list.sencond_disinfection_water:""
              this.form.sencond_disinfection_methods = list.sencond_disinfection_methods?list.sencond_disinfection_methods:""
              this.form.sencond_disinfection_time = list.sencond_disinfection_time?list.sencond_disinfection_time:""
              this.form.sencond_start_time = this.getTimeThree(list.sencond_start_time)
              this.form.sencond_end_time = this.getTimeThree(list.sencond_end_time)
              this.form.sencond_total_time = list.sencond_total_time?list.sencond_total_time:""
              this.form.sencond_is_check = list.sencond_is_check.toString()
              this.form.sencond_modifications = list.sencond_modifications?list.sencond_modifications:""
              this.form.sencond_creator = list.sencond_creator
              this.form.third_disinfection_water = list.third_disinfection_water?list.third_disinfection_water:""
              this.form.third_disinfection_methods = list.third_disinfection_methods?list.third_disinfection_methods:""
              this.form.third_disinfection_time = list.third_disinfection_time?list.third_disinfection_time:""
              this.form.third_start_time  =this.getTimeThree(list.third_start_time)
              this.form.third_end_time = this.getTimeThree(list.third_end_time)
              this.form.third_total_time = list.third_total_time?list.third_total_time:""
              this.form.third_is_check = list.third_is_check.toString()
              this.form.third_modifications = list.third_modifications?list.third_modifications:""
              this.form.third_creator = list.third_creator

              this.form.fourth_disinfection_water = list.fourth_disinfection_water?list.fourth_disinfection_water:""
              this.form.fourth_disinfection_methods = list.fourth_disinfection_methods?list.fourth_disinfection_methods:""
              this.form.fourth_disinfection_time = list.fourth_disinfection_time?list.fourth_disinfection_time:""
              this.form.fourth_start_time  =this.getTimeThree(list.fourth_start_time)
              this.form.fourth_end_time = this.getTimeThree(list.fourth_end_time)
              this.form.fourth_total_time = list.fourth_total_time? list.fourth_total_time:""
              this.form.fourth_is_check = list.fourth_is_check.toString()
              this.form.fourth_modifications = list.fourth_modifications?list.fourth_modifications:""
              this.form.fourth_creator = list.fourth_creator

              this.form.last_start_time = this.getTimeThree(list.last_start_time)
              this.form.last_end_time = this.getTimeThree(list.last_end_time)
              this.form.last_total_time = list.last_total_time?list.last_total_time:""
              this.form.last_is_check = list.last_is_check.toString()
              this.form.last_modifications = list.last_modifications?list.last_modifications:""
              this.form.last_creator = list.last_creator
              this.form.last_disinfection_water = list.last_disinfection_water?list.last_disinfection_water:""
              this.form.last_disinfection_methods = list.last_disinfection_methods?list.last_disinfection_methods:""
              this.form.last_disinfection_time = list.last_disinfection_time?list.last_disinfection_time:""
              this.form.storey = list.storey
              this.editDialogFormVisible = true
            }
          })
        },
        handleEditOne(id){
            getObjectTableDisInfectWayByIdList(id).then(response=>{
                var list = response.data.data.list
              console.log("list",list)
              this.form.id = list.id
              this.form.record_date = this.getTimes(list.record_date)
              this.form.first_disinfection_water = list.first_disinfection_water? list.first_disinfection_water:""
              this.form.first_disinfection_methods = list.first_disinfection_methods? list.first_disinfection_methods:""
              this.form.first_disinfection_time = list.first_disinfection_time?list.first_disinfection_time:""
              this.form.first_start_time = this.getTimeThree(list.first_start_time)
              this.form.first_end_time = this.getTimeThree(list.first_end_time)
              this.form.first_total_time = list.first_total_time?list.first_total_time:""
              this.form.first_is_check = list.first_is_check.toString()
              this.form.first_modifications = list.first_modifications?list.first_modifications:""
              this.form.first_creator = list.first_creator

              this.form.last_start_time = this.getTimeThree(list.last_start_time)
              this.form.last_end_time = this.getTimeThree(list.last_end_time)
              this.form.last_total_time = list.last_total_time?list.last_total_time:""
              this.form.last_is_check = list.last_is_check.toString()
              this.form.last_modifications = list.last_modifications?list.last_modifications:""
              this.form.last_creator = list.last_creator
              this.form.last_disinfection_water = list.last_disinfection_water?list.last_disinfection_water:""
              this.form.last_disinfection_methods = list.last_disinfection_methods?list.last_disinfection_methods:""
              this.form.last_disinfection_time = list.last_disinfection_time?list.last_disinfection_time:""
              this.form.department = list.department
              this.editnewdialogFormVisible = true
            })
        },
        updateObjectTableDisinfect(formName){
          this.$refs[formName].validate((valid=>{
            if(valid){
                if(this.form.first_is_check!=""){
                  this.form.first_is_check = parseInt(this.form.first_is_check) 
                }else{
                    this.form.first_is_check=0
                }

                if(this.form.sencond_is_check!=""){
                  this.form.sencond_is_check = parseInt(this.form.sencond_is_check) 
                }else{
                    this.form.sencond_is_check=0  
                }

                if(this.form.third_is_check!=""){
                  this.form.third_is_check = parseInt(this.form.third_is_check)
                }else{
                    this.form.third_is_check = 0
                }
                
                if(this.form.fourth_is_check!=""){
                  this.form.fourth_is_check = parseInt(this.form.fourth_is_check)
                }else{
                    this.form.fourth_is_check =0  
                }

                if(this.form.last_is_check!=""){
                    this.form.last_is_check = parseInt(this.form.last_is_check)
                }else{
                    this.form.last_is_check = 0
                }


                if(this.form.first_modifications!=""){
                  this.form.first_modifications = parseInt(this.form.first_modifications) 
                }else{
                    this.form.first_modifications=0
                }

                if(this.form.sencond_modifications!=""){
                  this.form.sencond_modifications = parseInt(this.form.sencond_modifications) 
                }else{
                    this.form.sencond_modifications=0  
                }

                if(this.form.third_modifications!=""){
                  this.form.third_modifications = parseInt(this.form.third_modifications)
                }else{
                    this.form.third_modifications = 0
                }
                
                if(this.form.fourth_modifications!=""){
                  this.form.fourth_modifications = parseInt(this.form.fourth_modifications)
                }else{
                    this.form.fourth_modifications =0  
                }

                if(this.form.last_modifications!=""){
                    this.form.last_modifications = parseInt(this.form.last_modifications)
                }else{
                    this.form.last_modifications = 0
                }
                console.log("hhahdhfhahdf",this.form)
                updateObjectTableDisinfect(this.form).then(response=>{
                 if(response.data.state == 1){
                   var objectDisinfect =  response.data.data.objectDisinfect
                   this.$message.success("保存成功!")
                   this.editDialogFormVisible = false
                   this.getObjectTableDisInfectList()
                 }
              })
            }
          }))
        },
        updateObjectWayTableDisinfect(formName){
          this.$refs[formName].validate((valid=>{
            if(valid){
                if(this.form.first_is_check!=""){
                  this.form.first_is_check = parseInt(this.form.first_is_check) 
                }else{
                    this.form.first_is_check=0
                }

              
                if(this.form.last_is_check!=""){
                    this.form.last_is_check = parseInt(this.form.last_is_check)
                }else{
                    this.form.last_is_check = 0
                }


                if(this.form.first_modifications!=""){
                  this.form.first_modifications = parseInt(this.form.first_modifications) 
                }else{
                    this.form.first_modifications=0
                }

               
                if(this.form.last_modifications!=""){
                    this.form.last_modifications = parseInt(this.form.last_modifications)
                }else{
                    this.form.last_modifications = 0
                }
                console.log("hhahdhfhahdf",this.form)
                updateObjectWayTableDisinfect(this.form).then(response=>{
                 if(response.data.state == 1){
                   var objectDisinfect =  response.data.data.objectDisinfect
                   this.$message.success("保存成功!")
                   this.editnewdialogFormVisible = false
                   this.getObjectTableDisInfectWayList()
                 }
              })
            }
          }))
        },
        handleDelete(id){
          deleteObjectTableDisinfect(id).then(response=>{
            if(response.data.state ==1){
              var msg = response.data.data.msg
              this.$message.success("删除成功!")
              this.getObjectTableDisInfectList()
            }
          })
        },
        handleDeleteOne(id){
          deleteObjectTableWayDisinfect(id).then(response=>{
            if(response.data.state ==1){
              var msg = response.data.data.msg
              this.$message.success("删除成功!")
              this.getObjectTableDisInfectWayList()
            }
          })
        },
        firststartime(val){
            this.form.first_start_time = val
            this.form.first_disinfection_time = this.firstdisinfection_time
        },
        firstendtime(val){
            this.form.first_disinfection_time = this.firstdisinfection_time
            this.form.first_end_time = val   
        },
        sencondstarttime(val){
            this.form.sencond_start_time = val
            this.form.sencond_disinfection_time = this.senconddisinfection_time
        },
         sencondendtime(val){
            this.form.sencond_end_time = val
            this.form.sencond_disinfection_time = this.senconddisinfection_time
        },
        thirdstarttime(val){
            this.form.third_start_time = val
            this.form.third_disinfection_time = this.thirddisinfection_time
        },
        thirdendtime(val){
            this.form.third_end_time = val
            this.form.third_disinfection_time = this.thirddisinfection_time
        },
        fourthstarttime(val){
            this.form.fourth_start_time = val
            this.form.fourth_disinfection_time = this.fourthdisinfection_time
        },
        fourthendtime(val){
            this.form.fourth_end_time = val
            this.form.fourth_disinfection_time = this.fourthdisinfection_time
        },
        laststarttime(val){
            this.form.last_start_time = val
            this.form.last_disinfection_time = this.lastdisinfection_time
        },
        lastendtime(val){
            this.form.last_end_time = val
            this.form.last_disinfection_time = this.lastdisinfection_time
        },
        setAdminUserES(id) {
           
           if (id === 0) {
           return ''
           }
           var user_name = ""
           for(let i=0;i<this.operators.length;i++){
              if(id == this.operators[i].admin_user_id){
                 user_name = this.operators[i].url
              }
           }
           return user_name
       },

       handleSizeChange(val) {
        this.limit = val;
        this.getObjectTableDisInfectList()
      },
      handleCurrentChange(val) {
        this.page = val;
        this.getObjectTableDisInfectList()
      },
      handleSizeChangeOne(val){
        this.limit = val;
        this.getObjectTableDisInfectWayList()
      },
      handleCurrentChangeOne(val){
        this.page = val;
        this.getObjectTableDisInfectWayList()
      },
      toSeach(){
        this.getObjectTableDisInfectList()
        this.getObjectTableDisInfectWayList()
      },
      toSetting(){
        getObjectWayDisinfect().then(response=>{
           if(response.data.state==1){
             var objctSet = response.data.data.disinfect
             if(objctSet!=undefined){
                this.art_way_one = objctSet.air_way.toString()
             }
             this.setEditDialog = true
             
           }
        })
      },
      getObjectWayDisinfect(){
        getObjectWayDisinfect().then(response=>{
           if(response.data.state==1){
             var objctSet = response.data.data.disinfect
             if(objctSet!=undefined){
                this.art_way_one = objctSet.air_way
             }
             console.log("art_way_one23232322323",this.art_way_one)
            
           }
        })
      },
      saveSetObjectTable(){
         var params = {
            air_way:parseInt(this.air_way)
         }
        setObjectDisinfect(params).then(response=>{
           if(response.data.state==1){
             var objctSet = response.data.data.objctSet
             this.setEditDialog = false
             this.getObjectWayDisinfect()
           }
        })
      },
      saveObjectWayTableDisinfect(formName){
        this.$refs[formName].validate((valid)=>{
            if(valid){
                if(this.form.first_is_check!=""){
                  this.form.first_is_check = parseInt(this.form.first_is_check) 
                }else{
                    this.form.first_is_check=0
                }

                if(this.form.first_modifications!=""){
                  this.form.first_modifications = parseInt(this.form.first_modifications) 
                }else{
                    this.form.first_modifications=0
                }


                if(this.form.last_is_check!=""){
                    this.form.last_is_check = parseInt(this.form.last_is_check)
                }else{
                    this.form.last_is_check = 0
                }

              

                if(this.form.last_modifications!=""){
                    this.form.last_modifications = parseInt(this.form.last_modifications)
                }else{
                    this.form.last_modifications = 0
                }

                if(this.form.last_start_time == null){
                   this.form.last_start_time = ""
                }

                if(this.form.last_end_time == null){
                   this.form.last_end_time = ""
                }
              
              saveObjectWayTableDisinfect(this.form).then(response=>{
                if(response.data.state ==1){
                    var objectDisinfect =  response.data.data.objectDisinfect
                   this.$message.success("保存成功!")
                   this.newdialogFormVisible = false
                   this.getObjectTableDisInfectWayList()
                }
              })
            }
        })
      },
      getObjectTableDisInfectWayList(){
        var params = {
                start_time:this.startvalue,
                end_time:this.endvalue,
                limit:this.limit,
                page:this.page,
             }
             getObjectTableDisInfectWayList(params).then(response=>{
              if(response.data.state == 1){
                var list = response.data.data.list
                this.tableDataOne = list
                this.total = response.data.data.total
              }
            })  
       }
        
      }
    }
  </script>

  <style lang="scss" scoped>
  .airForm{
      display: flex;
      justify-content: space-between;
      flex-wrap: wrap;
      .el-form-item{
          width:33%;
      }
      .el-date-editor.el-input, .el-date-editor.el-input__inner{
          width: 200px;
      }
      .el-input{
          width: 200px;
      }
      .el-select{
          width: 200px;
      }
      .form_title{
        width: 100%;
        margin-bottom: 10px;
        span{
            font-size: 20px;
            font-weight: bold;
        }
      }
  }
  </style>

  <style lang="scss">
   #main-contain{
    .app-container{
        // display: flex;
        // justify-content: space-between;
        // flex-wrap: wrap;
        .tab_air{
        // 斜杠表格
        .el-table{
            th{
                padding: 0px !important;
            }
            tr:first-of-type th:first-of-type div.cell {
                text-align: right;/*上边文字靠右*/
            }
            tr:last-of-type th:first-of-type div.cell {
                text-align: left;/*下边文字靠左*/
            }
            tr:first-of-type th:first-of-type:before {
                content: "";
                position: absolute;
                width: 1px;
                height: 100px;/*斜线的长度*/
                top: 0;
                left: 75px;
                background-color: rgb(172, 171, 171);
                opacity: 1.2;
                display: block;
                transform: rotate(-47deg);/*调整斜线的角度*/
                -webkit-transform-origin: top;
                transform-origin: top;
            }
            tr:nth-of-type(2) th:nth-of-type(1):before{
                content: "";
                position: absolute;
                width: 1px;
                height: 80px;/*斜线的长度*/
                top: 0;
                left: 100px;
                background-color: rgb(172, 171, 171);
                opacity: 1.2;
                display: block;
                transform: rotate(-47deg);/*调整斜线的角度*/
                -webkit-transform-origin: top;
                transform-origin: top;
            }
            tr:last-of-type th:first-of-type:before {
                content: "";
                position: absolute;
                width: 1px;
                height: 80px;/*斜线的长度*/
                top: 0;
                left: 125px;
                background-color: rgb(172, 171, 171);
                opacity: 1.2;
                display: block;
                transform: rotate(-48deg);/*调整斜线的角度*/
                -webkit-transform-origin: top;
                transform-origin: top;
            }
            tr:nth-of-type(2) th:nth-of-type(1):after{
                content: "";
                position: absolute;
                width: 1px;
                height: 80px;/*斜线的长度*/
                top: 8px;
                left: 0px;
                background-color: rgb(172, 171, 171);
                opacity: 1.2;
                display: block;
                transform: rotate(-76deg);/*调整斜线的角度*/
                -webkit-transform-origin: top;
                transform-origin: top;
            }
            tr:last-of-type th:first-of-type:after {
                content: "";
                position: absolute;
                width: 1px;
                height: 92px;/*斜线的长度*/
                top: 0;
                left: 59px;
                background-color: rgb(172, 171, 171);
                opacity: 1.2;
                display: block;
                transform: rotate(-76deg);/*调整斜线的角度*/
                -webkit-transform-origin: top;
                transform-origin: top;
            }
        }
        .el-table--border th, .el-table__fixed-right-patch {
            border-bottom: none !important;
        }
        .el-table td .cell, .el-table th .cell {
            padding: 0 5px !important;
        }
        .el-table .cell {
            white-space: pre-line;
        }
     }
    }


   }
  ::-webkit-scrollbar{
    height: 15px;
  }

  </style>
