<template>
  <div style="padding: 30px 30px 3px 30px">
    <div style="background-color: rgb(239,239,240);padding: 15px">
      <div class="div5">设备详情</div>
      <el-card class="card">
        <el-table
          v-loading="loading"
          :data="equipmentTableData"
          :header-cell-style="tableHeaderColor1"
          :cell-style="tableColor"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%">
          <el-table-column align="left" label="设备编号" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.设备编号 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="设备名称" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.设备名称 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="车间" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.车间 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="产线" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.产线 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="工序" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.工序 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="ABC指标" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ machine.ABC指标 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="设备详情" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-button type="text" icon="el-icon-document" @click="details()"/>
            </template>
          </el-table-column>
        </el-table>
      </el-card>
      <div class="div5">工单详情</div>
      <el-card class="card">
        <el-table
          v-loading="loading"
          :data="orderTableData1"
          :header-cell-style="tableHeaderColor1"
          :cell-style="tableColor1"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%;margin-bottom: 20px">
          <el-table-column align="left" label="工单号" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-tag color="rgb(153,153,153)" size="mini" type="info" >{{ orderCurrent.工单号 }}</el-tag>
            </template>
          </el-table-column>
          <el-table-column align="left" label="状态" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-tag v-if="orderCurrent.状态代码 === 1 || orderCurrent.状态代码 === 2" color="rgb(227,0,21)" type="info" size="mini" >{{ orderCurrent.状态 }}</el-tag>
              <el-tag v-if="orderCurrent.状态代码 === 4" color="rgb(0,142,207)" type="info" size="mini" >{{ orderCurrent.状态 }}</el-tag>
              <el-tag v-if="orderCurrent.状态代码 === 3" color="rgb(255,165,0)" type="info" size="mini" >{{ orderCurrent.状态 }}</el-tag>
              <el-tag v-if="orderCurrent.状态代码 === 5" color="rgb(115,168,57)" type="info" size="mini" >{{ orderCurrent.状态 }}</el-tag>
            </template>
          </el-table-column>
          <el-table-column align="left" label="故障类别" prop="故障类别" min-width="80" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ orderCurrent.故障名称 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="开始时间" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ orderCurrent.开始时间 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="申请人" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ orderCurrent.申请人姓名 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="故障现象" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ orderCurrent.故障现象 }}</span>
            </template>
          </el-table-column>
        </el-table>
        <span style="font-size: 18px">实际总工时：</span>
        <el-tag v-if="orderCurrent.实际总工时" color="rgb(0,142,207)" size="mini" type="info" >{{ orderCurrent.实际总工时 }}小时</el-tag>
        <el-tag v-else color="rgb(0,142,207)" size="mini" type="info" >0小时</el-tag>
      </el-card>
      <div class="div5">工作流及状态</div>
      <el-card class="card">
        <el-table
          v-loading="loading"
          :data="statusTableData"
          :header-cell-style="tableHeaderColor1"
          :cell-style="tableColor1"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%">
          <el-table-column align="center" label="人员安排">
            <template slot-scope="scope">
              <el-button
                :disabled="orderCurrent.状态代码 ===4 ||orderCurrent.状态代码 === 5 "
                style="height: 50px;width: 140px"
                class="button11"
                @click="statusArrange()">安排</el-button>
              <el-tag v-if="orderCurrent.安排时间" color="rgb(0,142,207)" size="mini" type="info" style="margin-top: 2px">{{ orderCurrent.安排时间 }}</el-tag>
              <div v-else style="width: 100%;height: 25px"/>
            </template>
          </el-table-column>
          <el-table-column align="center" label="人员到场" min-width="90">
            <template slot-scope="scope">
              <el-button
                :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 3 || orderCurrent.状态代码 === 4 || orderCurrent.状态代码 === 5"
                style="height: 50px;width: 140px"
                class="button11"
                @click="statusReach()">到场确认</el-button>
              <el-tag v-if="orderCurrent.到场时间" color="rgb(0,142,207)" size="mini" type="info" style="margin-top: 2px">{{ orderCurrent.到场时间 }}</el-tag>
              <div v-else style="width: 100%;height: 25px"/>
            </template>
          </el-table-column>
          <el-table-column align="center" label="问题确定" min-width="90">
            <template slot-scope="scope">
              <el-button
                :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 4 || orderCurrent.状态代码 === 5"
                style="height: 50px;width: 140px"
                class="button11"
                @click="statusProblem('problemForm')">确认</el-button>
              <el-tag v-if="orderCurrent.确定时间" color="rgb(0,142,207)" size="mini" type="info" style="margin-top: 2px">{{ orderCurrent.确定时间 }}</el-tag>
              <div v-else style="width: 100%;height: 25px"/>
            </template>
          </el-table-column>
          <el-table-column align="center" label="维修完成" min-width="90">
            <template slot-scope="scope">
              <el-button
                :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || (orderCurrent.状态代码 === 3 && orderCurrent.确定状态 === 0) || orderCurrent.状态代码 === 4 || orderCurrent.状态代码 === 5"
                style="height: 50px;width: 140px"
                class="button11"
                @click="statusRepair()">维修完成</el-button>
              <el-tag v-if="orderCurrent.完成时间" color="rgb(0,142,207)" size="mini" type="info" style="margin-top: 2px">{{ orderCurrent.完成时间 }}</el-tag>
              <div v-else style="width: 100%;height: 25px"/>
            </template>
          </el-table-column>
          <el-table-column align="center" label="生产接受并确认" min-width="90">
            <template slot-scope="scope">
              <el-button
                :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3 || orderCurrent.状态代码 === 5 || orderCurrent.是否录入维修内容 === 0"
                class="button11"
                style="height: 50px;width: 140px"
                @click="statusAccept()">确认接受</el-button>
              <el-tag v-if="orderCurrent.确认时间" color="rgb(0,142,207)" size="mini" type="info" style="margin-top: 2px">{{ orderCurrent.确认时间 }}</el-tag>
              <div v-else style="width: 100%;height: 25px"/>
            </template>
          </el-table-column>
        </el-table>
      </el-card>
      <el-row style="margin: 0px 10px 40px 10px">
        <el-col :span="13">
          <el-button size="large" style="background-color: rgb(239,239,240)" class="button12" @click="orderMap()">操作轨迹</el-button>
          <el-button
            v-if="orderCurrent.工单号.indexOf('EM') !== -1"
            size="large"
            style="background-color: rgb(239,239,240)"
            class="button12"
            @click="support()">技术支援</el-button>
        </el-col>
        <el-col :span="3">
          <div style="font-size: 20px;margin-top: 10px;margin-left: 10%">维修技术员:</div>
        </el-col>
        <el-col :span="8">
          <div v-if="orderCurrent.维修人员姓名">
            <el-tag v-for="(order,index) in orderCurrent.维修人员姓名" :key="index" color="rgb(115,168,57)" size="large" type="info" style="margin: 5px 5px">{{ order }}</el-tag>
          </div>
          <el-tag v-else color="rgb(227,0,21)" size="large" type="info" style="margin: 5px 5px">N/A</el-tag>
        </el-col>
      </el-row>
      <div class="div5">问题确定</div>
      <el-card class="card">
        <el-row>
          <el-col :span = "12">
            <div style="font-size: 20px;margin: 20px 10px 10px 0px">原因与描述</div>
            <div style="margin: 20px 10px 10px 0px;font-size: 15px">{{ orderCurrent.故障名称 }}</div>
            <div style="margin: 20px 10px 10px 0px;font-size: 15px">{{ orderCurrent.故障部位 }}</div>
            <div style="margin: 20px 10px 10px 0px;font-size: 15px">{{ orderCurrent.故障部件 }}</div>
            <div style="margin: 20px 10px 1px 5px;font-size: 10px;font-weight: 800">故障状态描述</div>
            <el-input v-model="orderCurrent.故障状态描述" type="textarea" readonly class="inputext" style="margin-bottom: 20px" />
          </el-col>
          <el-col :span = "12">
            <div style="font-size: 20px;margin: 20px 10px 10px 0px">故障分析</div>
            <el-collapse v-model="problemActiveNames" class="collapse1" style="margin-top: 10px">
              <el-collapse-item title="设备故障统计（最近3个月）" name="1">
                <el-row style="margin-top: 10px;font-size: 15px;line-height: 26px">
                  <el-col :span="10">
                    <div>发生次数：</div>
                    <div>故障占比：</div>
                    <div>平均维修时间（分钟）：</div>
                    <div>平均故障间隔（分钟）：</div>
                  </el-col>
                  <el-col :span="10">
                    <div>{{ faultCurrent.问题故障次数 }}</div>
                    <div>{{ faultCurrent.故障占比 }}</div>
                    <div>{{ faultCurrent.平均维修时间 }}</div>
                    <div>{{ faultCurrent.平均间隔 }}</div>
                  </el-col>
                </el-row>
              </el-collapse-item>
            </el-collapse>
          </el-col>
        </el-row>
      </el-card>
      <div class="div5">维修内容</div>
      <el-card class="card">
        <el-button
          :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3 || contentCount !== 0"
          class="button12"
          style="background-color: white;"
          @click="entryContent()">录入维修内容</el-button>
        <span style="margin-left: 20px">请点击按钮录入维修内容</span>
        <el-table
          v-loading="loading"
          v-if=" contentCount !== 0"
          :data="contentServiceTableData"
          :header-cell-style="tableHeaderColor1"
          :cell-style="tableColor2"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%;margin-top: 30px">
          <el-table-column align="left" label="故障原因分析" min-width="120" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.故障原因分析 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="现场解决措施" min-width="120" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.现场解决措施 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="改进意见" min-width="120" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.改进意见 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="等待时间合计" min-width="50" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.等待时间合计 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="填写人" min-width="50" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.填写人 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="编辑" min-width="50" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-button :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3" size="mini" type="text" icon="el-icon-edit" @click="editContent(scope.row)"/>
            </template>
          </el-table-column>
        </el-table>
      </el-card>
      <div class="div5">备件记录</div>
      <el-card class="card">
        <el-row>
          <el-col :span="3">
            <el-button
              :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3"
              class="button12"
              style="background-color: white;"
              @click="entrySpare()">录入备件信息</el-button>
          </el-col>
          <el-col :span="21">
            <el-table
              v-loading="loading"
              v-if=" spareCount !== 0"
              :data="spareTableData1"
              :header-cell-style="tableHeaderColor1"
              :cell-style="tableColor2"
              element-loading-spinner="el-icon-loading"
              tooltip-effect="dark"
              style="width: 100%">
              <el-table-column align="left" label="SAP编码" min-width="100" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.SAP编码 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="描述" min-width="100" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.描述 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="一级帐数" min-width="100" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.数量 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="二级帐数" min-width="100" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.二级帐 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="申请人" min-width="50" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.申请人 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="编辑" min-width="50" show-overflow-tooltip>
                <template slot-scope="scope">
                  <el-button :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3" size="mini" type="text" icon="el-icon-edit" @click="editSpare(scope.row)"/>
                  <el-button :disabled="orderCurrent.状态代码 ===1 || orderCurrent.状态代码 === 2 || orderCurrent.状态代码 === 3" size="mini" type="text" icon="el-icon-delete" @click="deleteSpare(scope.row)"/>
                </template>
              </el-table-column>
            </el-table>
          </el-col>
        </el-row>
      </el-card>
      <div v-if="assessCount !== 0" class="div5">评价及意见</div>
      <el-card v-if="assessCount !== 0" class="card">
        <el-row>
          <div>
            <el-rate v-model="assessValue" class="rate1" style="margin-left: 70px"/>
            <el-table
              v-loading="loading"
              :data="assessTableData"
              :header-cell-style="tableHeaderColor1"
              :cell-style="tableColor1"
              element-loading-spinner="el-icon-loading"
              tooltip-effect="dark"
              style="width: 90%;margin-top: 10px;margin-left: 70px">
              <el-table-column align="left" label="评价及意见" min-width="90" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.评价及意见 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="创建人" min-width="90" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.创建人 }}</span>
                </template>
              </el-table-column>
              <el-table-column align="left" label="创建时间" min-width="90" show-overflow-tooltip>
                <template slot-scope="scope">
                  <span>{{ scope.row.创建时间 }}</span>
                </template>
              </el-table-column>
            </el-table>
          </div>
        </el-row>
      </el-card>
      <!--    设备详情-->
      <el-dialog :title="title1" :visible.sync="dialogFormVisible1" center width="60%" >
        <el-form ref="form1" :model="form1" label-position="top" label-width="700px" label-padding-bottom="0px">
          <span style="font-size: 22px">设备信息</span>
          <el-card style="margin-top: 10px">
            <el-row>
              <el-col :span="18">
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="资产号" prop="assetNumber">
                      <div class="div">{{ machine.资产号 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="设备编号:" prop="description">
                      <div class="div">{{ machine.设备编号 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="设备名称:" prop="description">
                      <div class="div">{{ machine.设备名称 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="承包人:" prop="deviceGroup">
                      <div class="div">{{ machine.承包人 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="网格长:" prop="people">
                      <div class="div">{{ machine.网格长 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="ABC指标:" prop="quota">
                      <div class="div">{{ machine.ABC指标 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="车间:" prop="machineShop">
                      <div class="div">{{ machine.车间 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="产线:" prop="productionLine">
                      <div class="div">{{ machine.产线 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="工序:" prop="region">
                      <div class="div">{{ machine.工序 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
              </el-col>
              <el-col :span="6">
                <div class="avatar-uploader" >
                  <img v-if="machine.图片" :src="machine.图片" class="avatar">
                  <img v-else src="static/image.png" class="avatar">
                </div>
              </el-col>
            </el-row>
          </el-card>
          <el-card style="margin-top: 20px">
            <el-tabs v-model="activeName">
              <el-tab-pane label="基本信息" name="1">
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="成本中心">
                      <div class="div">{{ machine.成本中心 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="保修起始日期">
                      <div class="div">{{ machine.保修起始日期 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="附加信息1">
                      <div class="div">{{ machine.附加信息1 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="工作中心代码">
                      <div class="div">{{ machine.工作中心代码 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="保修终止日期">
                      <div class="div">{{ machine.保修截至日期 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="附加信息2">
                      <div class="div">{{ machine.附加信息2 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
              </el-tab-pane>
              <el-tab-pane label="制造商" name="2">
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="制造商">
                      <div class="div">{{ machine.制造商 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="型号">
                      <div class="div">{{ machine.设备型号 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="生产序列号">
                      <div class="div">{{ machine.生产序列号 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="供应商">
                      <div class="div">{{ machine.供应商 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="制造日期">
                      <div class="div">{{ machine.制造日期 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
              </el-tab-pane>
              <el-tab-pane label="生命周期管理" name="3">
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="开始日期">
                      <div class="div">{{ machine.生命周期开始日期 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="警告日期">
                      <div class="div">{{ machine.生命周期警告日期 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="报废日期">
                      <div class="div">{{ machine.生命周期报废日期 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
              </el-tab-pane>
              <el-tab-pane label="资产折旧" name="4">
                <el-row>
                  <el-col :span="8">
                    <el-form-item label="原值">
                      <div class="div">{{ machine.原值 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="资产价值">
                      <div class="div">{{ machine.资产价值 }}</div>
                    </el-form-item>
                  </el-col>
                  <el-col :span="8">
                    <el-form-item label="剩余价值">
                      <div class="div">{{ machine.剩余价值 }}</div>
                    </el-form-item>
                  </el-col>
                </el-row>
              </el-tab-pane>
            </el-tabs>
          </el-card>
          <el-card style="margin-top: 20px">
            <el-tabs v-model="activeName1" @tab-click="handleClickMachineInfo">
              <el-tab-pane label="标准文件" name="1">
                <el-row>
                  <div v-for="(file, key) in hadFile" :key="key">
                    <div class="wrapper">
                      <div class="content">
                        <div v-if="file.suffix==='pdf'" class="icon"><svg-icon icon-class="pdf" /></div>
                        <div v-else-if="file.suffix==='docx'||file.suffix === 'doc'" class="icon"><svg-icon icon-class="doc" /></div>
                        <div v-else-if="file.suffix==='xlsx' || file.suffix === 'xls'" class="icon"><svg-icon icon-class="excel" /></div>
                        <div v-else-if="file.suffix==='pptx' || file.suffix === 'ppt'" class="icon"><svg-icon icon-class="ppt" /></div>
                        <div v-else-if="file.suffix==='jpg' || file.suffix === 'jpeg'|| file.suffix === 'png'" class="icon"><svg-icon icon-class="pic" /></div>
                        <div v-else class="icon"><svg-icon icon-class="file" /></div>
                        <a id="appUrl2" :href="file.url" target="view_window"><div class="info">{{ file.name }}</div></a>
                      </div>
                    </div>
                  </div>
                </el-row>
              </el-tab-pane>
              <el-tab-pane label="技术参考文件" name="2">
                <el-row>
                  <div v-for="(file, key) in hadFile1" :key="key">
                    <div class="wrapper">
                      <div class="content">
                        <div v-if="file.suffix==='pdf'" class="icon"><svg-icon icon-class="pdf" /></div>
                        <div v-else-if="file.suffix==='docx'||file.suffix === 'doc'" class="icon"><svg-icon icon-class="doc" /></div>
                        <div v-else-if="file.suffix==='xlsx' || file.suffix === 'xls'" class="icon"><svg-icon icon-class="excel" /></div>
                        <div v-else-if="file.suffix==='pptx' || file.suffix === 'ppt'" class="icon"><svg-icon icon-class="ppt" /></div>
                        <div v-else-if="file.suffix==='jpg' || file.suffix === 'jpeg'|| file.suffix === 'png'" class="icon"><svg-icon icon-class="pic" /></div>
                        <div v-else class="icon"><svg-icon icon-class="file" /></div>
                        <a id="appUrl3" :href="file.url" target="view_window"><div class="info">{{ file.name }}</div></a>
                      </div>
                    </div>
                  </div>
                </el-row>
              </el-tab-pane>
              <el-tab-pane label="备件列表" name="3">
                <el-table
                  :data="spareTableData2"
                  :header-cell-style="tableHeaderColor"
                  :cell-style="tableColor3"
                  element-loading-text="数据加载中"
                  element-loading-spinner="el-icon-loading"
                  element-loading-background="rgba(0, 0, 0, 0.2)"
                  tooltip-effect="dark"
                  height="402px"
                  style="width: 75%">
                  <el-table-column align="left" label="SAP编码" prop="SAP编码" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <div>{{ scope.row.SAP编码 }}</div>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="备件名称" prop="备件名称" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.物料描述 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="库存地点" prop="库存地点" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.库存地点 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="库存架位" prop="库存架位" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.库存架位 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="一级帐数" prop="数量" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.SAP库存数量 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="二级帐数" prop="二级帐" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.二级帐 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="单价" prop="单价" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.单价 }}</span>
                    </template>
                  </el-table-column>
                </el-table>
              </el-tab-pane>
              <el-tab-pane label="备件更换历史" name="4">
                <el-table
                  v-loading="loading"
                  :data="spareTableData"
                  :header-cell-style="tableHeaderColor"
                  :cell-style="tableColor3"
                  element-loading-text="数据加载中"
                  element-loading-spinner="el-icon-loading"
                  element-loading-background="rgba(0, 0, 0, 0.2)"
                  tooltip-effect="dark"
                  height="402px"
                  style="width: 75%">
                  <el-table-column align="left" label="SAP编码" prop="SAP编码" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <div>{{ scope.row.SAP编码 }}</div>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="备件名称" prop="备件名称" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.备件名称 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="一级帐数" prop="数量" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.数量 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="二级帐数" prop="二级帐" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.二级帐 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="操作时间" prop="操作时间" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.操作时间 }}</span>
                    </template>
                  </el-table-column>
                </el-table>
                <div class="block" style="margin-top: 10px;">
                  <el-pagination
                    v-if="!loading"
                    :current-page="sparePageCurrent"
                    :page-sizes="[10, 20, 30, 40]"
                    :page-size="sparePageSize"
                    :total="spareTotal"
                    layout="total, sizes, prev, pager, next, jumper"
                    @size-change="handleSizeChange1"
                    @current-change="handleCurrentChange1"/>
                </div>
              </el-tab-pane>
              <el-tab-pane label="EM" name="5">
                <el-table
                  v-loading="loading"
                  :data="orderTableData"
                  :header-cell-style="tableHeaderColor"
                  :cell-style="tableColor2"
                  element-loading-text="数据加载中"
                  element-loading-spinner="el-icon-loading"
                  element-loading-background="rgba(0, 0, 0, 0.2)"
                  tooltip-effect="dark"
                  height="400px"
                  style="width: 90%">
                  <el-table-column align="left" label="工单号" prop="工单号" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag color="rgb(153,153,153)" size="mini" type="info" style="cursor: pointer" @click="orderClick(scope.row)">{{ scope.row.工单号 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障类别" prop="故障类别" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障名称 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障现象" prop="故障现象" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障现象 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="状态" prop="状态" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag v-if="scope.row.状态代码 === 1 || scope.row.状态代码 === 2" color="red" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 4" color="rgb(0,142,207)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 3" color="rgb(255,165,0)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 5" color="green" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="开始时间" prop="开始时间" min-width="130" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.开始时间 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="持续时长" prop="持续时长" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.持续时长 }}</span>
                    </template>
                  </el-table-column>
                </el-table>
              </el-tab-pane>
              <el-tab-pane label="CM" name="6">
                <el-table
                  v-loading="loading"
                  :data="orderTableData10"
                  :header-cell-style="tableHeaderColor"
                  :cell-style="tableColor2"
                  element-loading-text="数据加载中"
                  element-loading-spinner="el-icon-loading"
                  element-loading-background="rgba(0, 0, 0, 0.2)"
                  tooltip-effect="dark"
                  height="400px"
                  style="width: 90%">
                  <el-table-column align="left" label="工单号" prop="工单号" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag color="rgb(153,153,153)" size="mini" type="info" style="cursor: pointer" @click="orderClick(scope.row)">{{ scope.row.工单号 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障类别" prop="故障类别" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障名称 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障现象" prop="故障现象" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障现象 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="状态" prop="状态" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag v-if="scope.row.状态代码 === 1 || scope.row.状态代码 === 2" color="red" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 4" color="rgb(0,142,207)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 3" color="rgb(255,165,0)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 5" color="green" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="开始时间" prop="开始时间" min-width="130" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.开始时间 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="持续时长" prop="持续时长" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.持续时长 }}</span>
                    </template>
                  </el-table-column>
                </el-table>
              </el-tab-pane>
              <el-tab-pane label="PM" name="7">
                <el-table
                  v-loading="loading"
                  :data="orderTableData2"
                  :header-cell-style="tableHeaderColor"
                  :cell-style="tableColor2"
                  element-loading-text="数据加载中"
                  element-loading-spinner="el-icon-loading"
                  element-loading-background="rgba(0, 0, 0, 0.2)"
                  tooltip-effect="dark"
                  height="400px"
                  style="width: 90%">
                  <el-table-column align="left" label="工单号" prop="工单号" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag color="rgb(153,153,153)" size="mini" type="info" style="cursor: pointer" @click="orderClick(scope.row)">{{ scope.row.工单号 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障类别" prop="故障类别" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障名称 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="故障现象" prop="故障现象" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.故障现象 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="状态" prop="状态" min-width="80" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <el-tag v-if="scope.row.状态代码 === 1 || scope.row.状态代码 === 2" color="red" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 4" color="rgb(0,142,207)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 3" color="rgb(255,165,0)" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                      <el-tag v-if="scope.row.状态代码 === 5" color="green" type="info" size="mini" >{{ scope.row.状态 }}</el-tag>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="开始时间" prop="开始时间" min-width="130" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.开始时间 }}</span>
                    </template>
                  </el-table-column>
                  <el-table-column align="left" label="持续时长" prop="持续时长" min-width="120" show-overflow-tooltip>
                    <template slot-scope="scope">
                      <span>{{ scope.row.持续时长 }}</span>
                    </template>
                  </el-table-column>
                </el-table>
              </el-tab-pane>
            </el-tabs>
          </el-card>
        </el-form>
      </el-dialog>
      <!--    人员安排-->
      <el-dialog :title="arrangeTitle" :visible.sync="arrangeDialogFormVisible" width="50%" class="dialog1">
        <div style="width: 100%;height: 54px;background-color: rgb(245,245,245)">
          <el-input
            v-model="arrangementInput"
            placeholder="search"
            size="middle"
            style="width: 180px;margin: 7px 15px"
            suffix-icon="el-icon-search"
            @input="getRepairman()"/>
        </div>
        <el-table
          v-loading="loading"
          :data="arrangeTableData"
          :header-cell-class-name="arrangeCellHeader"
          :cell-class-name="arrangeTableCell"
          :header-cell-style="tableHeaderColor"
          :cell-style="tableColor1"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%"
          @selection-change="peopleSelectionChange">
          <el-table-column type="selection" width="55"/>
          <el-table-column align="left" label="姓名" min-width="80" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.姓名 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="技能" min-width="70" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-tag v-if="scope.row.技能" color="rgb(0,142,207)" size="mini" type="info" > {{ scope.row.技能 }} </el-tag>
            </template>
          </el-table-column>
          <el-table-column align="left" label="等级" min-width="60" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.等级 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="状态" min-width="100" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-tag v-if="scope.row.维修工单号" color="rgb(153,153,153)" size="mini" type="info" >{{ scope.row.维修工单号 }}</el-tag>
              <el-tag v-else color="rgb(115,168,57)" size="mini" type="info" > 空闲 </el-tag>
            </template>
          </el-table-column>
          <el-table-column align="left" label="操作" min-width="140" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-button v-if="scope.row.维修工单号" size="mini" style="width: 80px;height: 40px;padding-left: 10px" class="button11" @click="statusFreed(scope.row)">紧急释放</el-button>
              <el-button v-if="scope.row.维修工单号" size="mini" style="width: 80px;height: 40px;padding-left: 10px" class="button11" @click="statusFreed1(scope.row)">能力释放</el-button>
            </template>
          </el-table-column>
        </el-table>
        <el-row>
          <el-button :disabled="arrangeAbled" class="button11" style="margin: 20px 0px 20px 75%;width: 11%" @click="arrangeSubmit(),arrangeSubmit1()">确认</el-button>
          <el-button class="button12" style="margin: 20px 0px 20px 1%;width: 11%;background-color: white" @click="arrangeCancle()">取消</el-button>
        </el-row>
      </el-dialog>
      <!--    问题确定-->
      <el-dialog :title="problemTitle" :visible.sync="problemDialogFormVisible" width="50%" class="dialog2">
        <el-form ref="problemForm" :model="problemForm" :rules="problemRules" label-position="top" label-width="700px" label-padding-bottom="0px" class="formItem1">
          <el-row>
            <el-col :span="12">
              <el-form-item label="问题分类" prop="problemFault">
                <el-select v-model="problemForm.problemFault" clearable class="select11" placeholder="">
                  <el-option
                    v-for="item in problemFaults"
                    :key="item.value"
                    :label="item.label"
                    :value="item.value"/>
                </el-select>
              </el-form-item>
              <el-form-item label="故障状态描述" prop="descriptionReason">
                <el-input v-model="problemForm.descriptionReason" type="textarea" class="inputext2" style="width: 80%" maxlength="255" show-word-limit/>
              </el-form-item>
              <el-form-item >
                <el-button size="large" class="button11" style="margin-top: 10px" @click="problemSubmit('problemForm')">保存</el-button>
              </el-form-item>
            </el-col>
            <el-col :span="12">
              <el-row>
                <el-col :span="10">
                  <el-form-item label="故障部位" prop="faultLocation">
                    <el-input v-model="problemForm.faultLocation" class="input12" style="width: 90%;height: 50px"/>
                  </el-form-item>
                </el-col>
                <el-col :span="10">
                  <el-form-item label="故障部件" prop="faultParts">
                    <el-input v-model="problemForm.faultParts" class="input12" style="width: 90%;height: 50px"/>
                  </el-form-item>
                </el-col>
              </el-row>
              <el-form-item label="部件故障状态描述" prop="descriptionReason1">
                <el-input v-model="problemForm.descriptionReason1" type="textarea" class="inputext2" style="width: 80%" maxlength="255" show-word-limit/>
              </el-form-item>
            </el-col>
          </el-row>
        </el-form>
      </el-dialog>
      <!--    录入维修内容-->
      <el-dialog :title="contentTitle" :visible.sync="contentDialogFormVisible" width="900px" class="dialog3">
        <el-form ref="contentForm" :model="contentForm" :rules="contentRules" label-position="top" label-width="700px" label-padding-bottom="0px" class="formItem2">
          <el-row>
            <el-col :span="15">
              <div style="margin-top: 15px;margin-right: 35px">
                <el-form-item label="导致停产时间(分钟)" prop="noWork">
                  <el-input v-model="contentForm.noWork" class="input12" style="width:40%;height: 40px"/>
                </el-form-item>
                <el-form-item label="现场解决措施" prop="repairContent">
                  <el-input v-model="contentForm.repairContent" type="textarea" class="inputext2" maxlength="255" style="width:97%" show-word-limit/>
                </el-form-item>
                <el-form-item label="故障原因分析" prop="faultAnalysis">
                  <el-input v-model="contentForm.faultAnalysis" type="textarea" class="inputext2" maxlength="255" style="width:97%" show-word-limit/>
                </el-form-item>
                <el-form-item label="改进意见" prop="improveSuggest">
                  <el-input v-model="contentForm.improveSuggest" type="textarea" class="inputext2" maxlength="255" style="width:97%" show-word-limit/>
                </el-form-item>
                <el-form-item>
                  <el-button v-if="contentSubmitValue === 1" class="button11" style="margin: 20px 0px 0px 65%;width: 15%" @click="contentSubmit('contentForm')">确认</el-button>
                  <el-button v-else class="button11" style="margin: 20px 0px 0px 65%;width: 15%" @click="contentEditSubmit('contentForm')">确认</el-button>
                  <el-button class="button12" style="margin: 20px 0px 0px 1%;width: 15%;background-color: white" @click="contentCancle('contentForm')">取消</el-button>
                </el-form-item>
              </div>
            </el-col>
            <el-col :span="9" style="border-left: 1px rgb(224,224,224) solid">
              <div style="margin-left: 35px;margin-top: 15px">
                <el-row>
                  <span style="font-size: 16px;font-weight: bold;">等待时间合计 </span>
                  <el-input v-model="contentWaitTime" readonly class="input12" style="width:50%;height: 40px"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">领件时间(分钟)</span>
                  <el-input-number v-model="contentWait1" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">等操作者(分钟)</span>
                  <el-input-number v-model="contentWait2" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">暂无备件(分钟)</span>
                  <el-input-number v-model="contentWait3" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">外部资源(分钟)</span>
                  <el-input-number v-model="contentWait4" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">维修工具(分钟)</span>
                  <el-input-number v-model="contentWait5" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">人力不足(分钟)</span>
                  <el-input-number v-model="contentWait6" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
                <el-row style="margin-top: 15px">
                  <span style="font-size: 14px;font-weight: bold">其&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;他(分钟)</span>
                  <el-input-number v-model="contentWait7" style="width:50%;height: 40px" @input="contentSum()"/>
                </el-row>
              </div>
            </el-col>
          </el-row>
        </el-form>
      </el-dialog>
      <!--    录入备件-->
      <el-dialog :title="spareTitle" :visible.sync="spareDialogFormVisible" width="20%" class="dialog3">
        <div style="margin-left: 15px">
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">手动输入</span>
            <el-switch
              v-model="value"
              active-color="#13ce66"
              inactive-color="#ff4949"
              @change="changeValue"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">物料组别</span>
            <el-select :disabled="value" v-model="materialGroup" placeholder="" style="width:200px;height: 40px" @change="getSAP();sapNumber='';sapName1=''">
              <el-option
                v-for="item in materialGroups"
                :key="item.value"
                :label="item.label"
                :value="item.value"/>
            </el-select>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">SAP编码</span>
            <el-select v-if="!value" v-model="sapNumber" placeholder="" style="width:200px;height: 40px" @change="selectSap">
              <el-option
                v-for="item in sapNumbers"
                :key="item.value"
                :label="item.label"
                :value="item.value"/>
            </el-select>
            <el-input v-if="value" v-model="spareSap1" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">备件描述</span>
            <el-input v-model="spareName1" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">一级帐数</span>
            <el-input v-model="spareNum1" type="number" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">二级帐数</span>
            <el-input v-model="spareNum2" type="number" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <el-button class="button11" style="margin-left: 34%;width: 80px" @click="spareSubmit()">确认</el-button>
            <el-button class="button12" style="margin-left: 10px;width: 80px;background-color: white" @click="spareCancle()">取消</el-button>
          </el-row>
        </div>
      </el-dialog>
      <!--    修改备件-->
      <el-dialog :title="spareTitle1" :visible.sync="spareDialogFormVisible1" width="20%" class="dialog1">
        <div style="margin-left: 15px">
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">手动输入</span>
            <el-switch
              v-model="value"
              active-color="#13ce66"
              inactive-color="#ff4949"
              @change="changeValue"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">物料组别</span>
            <el-select :disabled="value" v-model="materialGroup" placeholder="" style="width:200px;height: 40px" @change="getSAP();sapNumber='';sapName1=''">
              <el-option
                v-for="item in materialGroups"
                :key="item.value"
                :label="item.label"
                :value="item.value"/>
            </el-select>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">SAP编码</span>
            <el-select v-if="!value" v-model="sapNumber" placeholder="" style="width:200px;height: 40px" @change="selectSap">
              <el-option
                v-for="item in sapNumbers"
                :key="item.value"
                :label="item.label"
                :value="item.value"/>
            </el-select>
            <el-input v-if="value" v-model="spareSap1" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">备件描述</span>
            <el-input v-model="spareName1" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">一级帐数</span>
            <el-input v-model="spareNum1" type="number" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <span style="font-size: 14px;font-weight: bold">二级帐数</span>
            <el-input v-model="spareNum2" type="number" style="width:200px;height: 40px"/>
          </el-row>
          <el-row style="margin-top: 10px">
            <el-button class="button11" style="margin-left: 34%;width: 80px" @click="spareSubmit1()">确认</el-button>
            <el-button class="button12" style="margin-left: 10px;width: 80px;background-color: white" @click="spareCancle1()">取消</el-button>
          </el-row>
        </div>
      </el-dialog>
      <!--    维修完成-->
      <el-dialog :title="completeTitle" :visible.sync="completeDialogFormVisible" width="460px">
        <div style="margin-top:-90px;margin-left: 40%;margin-bottom: 30px;">
          <img :src="img" style="height: 75px;width: 100px;">
        </div>
        <el-row>
          <span style="font-size:30px;margin-left: 35px;">你确定维修已完成？</span>
        </el-row>
        <el-row style="margin-top: 50px">
          <span style="font-size:16px;margin-left: 35px">维修完成后，请录入维修内容。</span>
        </el-row>
        <el-button class="button11" style="margin-top: 50px;margin-left:230px;width: 70px" @click="completeSubmit()">是</el-button>
        <el-button class="button12" style="background-color: white;width: 70px;margin-top: 50px;margin-left: 15px" @click="completeCancle">否</el-button>
      </el-dialog>
      <!--    确认接受-->
      <el-dialog :title="acceptTitle" :visible.sync="acceptDialogFormVisible" width="50%" class="dialog4">
        <div>
          <span>工单号: {{ orderCurrent.工单号 }}</span>
          <el-row style="margin-top: 30px">
            <el-col :span="9">
              <span>工单开始时间: </span>
              <el-tag color="rgb(0,142,207)" size="small" type="info" style="cursor: pointer">{{ orderCurrent.开始时间 }}</el-tag>
            </el-col>
            <el-col :span="9">
              <span>维修完成时间: </span>
              <el-tag color="rgb(0,142,207)" size="small" type="info" style="cursor: pointer">{{ orderCurrent.完成时间 }}</el-tag>
            </el-col>
            <el-col :span="6">
              <span>维修时长: </span>
              <el-tag color="rgb(0,142,207)" size="small" type="info" style="cursor: pointer">{{ orderCurrent.持续时长 }}</el-tag>
            </el-col>
          </el-row>
          <el-row style="margin-top: 30px">
            <el-col :span="2">
              <span>维修人: </span>
            </el-col>
            <el-col :span="5">
              <div v-if="orderCurrent.维修人员姓名">
                <el-tag v-for="(order,index) in orderCurrent.维修人员姓名" :key="index" color="rgb(115,168,57)" size="middle" type="info" style="margin-left: 5px">{{ order }}</el-tag>
              </div>
              <el-tag v-else color="rgb(227,0,21)" size="middle" type="info" style="margin-left: 5px">N/A</el-tag>
            </el-col>
            <el-col :span="8">
              <span>导致停产时间: </span>
              <el-input v-model="acceptNoWork" class="input12" style="width:40%;height: 40px"/>
            </el-col>
            <el-col :span="8">
              <el-switch
                v-model="acceptSwitch"
                active-text="带病运转"
                inactive-text="正常运行"
                style="margin-top: 10px;margin-left: 10px"/>
            </el-col>
          </el-row>
          <div style="margin-top: 15px">评价及意见</div>
          <el-rate v-model="acceptAssessValue" class="rate1" style="margin-top: 15px"/>
          <el-input
            v-model="acceptAssess"
            style="margin-top: 10px;width: 40%"
            class="inputext2"
            type="textarea"
            maxlength="255"
            show-word-limit
            placeholder="描述"/>
        </div>
        <el-row style="margin-top: 30px;">
          <el-button class="button11" style="margin-left:80%;width: 8%" @click="acceptSubmit()">是</el-button>
          <el-button class="button12" style="background-color: white;width:  8%;margin-left: 2%" @click="acceptCancle">否</el-button>
        </el-row>
      </el-dialog>
      <!--    操作轨迹-->
      <el-dialog :title="locusTitle" :visible.sync="locusDialogFormVisible" width="60%" class="dialog5">
        <el-table
          v-loading="loading"
          :data="locusTableData"
          :header-cell-style="tableHeaderColor"
          :cell-style="tableColor1"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%">
          <el-table-column align="left" label="日期时间" prop="日期时间" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.日期时间 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="类型" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.类型 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="原值" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.原值 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="新值" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.新值 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="用户" prop="用户" min-width="90" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.用户 }}</span>
            </template>
          </el-table-column>
        </el-table>
        <div style="margin-top: 20px;margin-left: 65%;">
          <el-pagination
            :current-page="locusPageCurrent"
            :page-sizes="[10, 20, 30, 40]"
            :page-size="locusPageSize"
            :total="locusTotal"
            layout="total, prev, pager, next, sizes"
            @size-change="locusSizeChange"
            @current-change="locusCurrentChange"/>
        </div>
      </el-dialog>
      <!--    技术支援-->
      <el-dialog :title="supportTitle" :visible.sync="supportDialogFormVisible" width="40%" class="dialog5">
        <el-table
          v-loading="loading"
          v-if="supportCount !== 0"
          :data="supportTableData"
          :header-cell-style="tableHeaderColor"
          :cell-style="tableColor1"
          element-loading-spinner="el-icon-loading"
          tooltip-effect="dark"
          style="width: 100%;margin-top: 10px">
          <el-table-column align="left" label="申请原因" min-width="80" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.技术支援内容 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="申请人" min-width="70" show-overflow-tooltip>
            <template slot-scope="scope">
              <span>{{ scope.row.姓名 }}</span>
            </template>
          </el-table-column>
          <el-table-column align="left" label="状态" min-width="130" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-tag v-if="scope.row.是否同意 === 0" color="rgb(153,153,153)" size="mini" type="info" >未响应</el-tag>
              <el-tag v-if="scope.row.是否同意 === 1" color="rgb(153,153,153)" size="mini" type="info" >已同意</el-tag>
              <el-tag v-if="scope.row.是否同意 === 2" color="rgb(153,153,153)" size="mini" type="info" >未同意</el-tag>
            </template>
          </el-table-column>
          <el-table-column align="left" label="操作" min-width="140" show-overflow-tooltip>
            <template slot-scope="scope">
              <el-button size="mini" style="width: 70px;height: 30px" class="button11" @click="agree(scope.row)">同意</el-button>
              <el-button size="mini" style="width: 70px;height: 30px" class="button11" @click="disagree(scope.row)">不同意</el-button>
            </template>
          </el-table-column>
        </el-table>
      </el-dialog>
    </div>
  </div>
</template>

<script>
import img from '@/assets/404_images/20.png'
import { ExecDatabase } from '@/main'
import { MESDownloadFile } from '@/utils/request'
import { mapGetters } from 'vuex'
export default {
  data() {
    return {
      img,
      hadFile: [],
      hadFile1: [],
      value: false,
      materialGroups: [],
      materialGroup: '',
      sapNumbers: [],
      sapNumber: '',
      materialNumber: '',
      tableData2: [],
      rowOrder: {},
      orderCurrent: { 工单号: '' },
      machineValue: '',
      machine: {},
      equipmentTableData: [{}],
      dialogFormVisible: false,
      activeNames: ['1', '2'],
      dialogFormVisible1: false,
      title1: '',
      form1: {},
      activeName: '1',
      activeName1: '1',
      orderTableData1: [{}],
      statusTableData: [{}],
      arrangeDialogFormVisible: false,
      arrangeTitle: '',
      arrangementInput: '',
      arrangeTableData: [],
      multipleSelection: [],
      arrangeAbled: true,
      problemTitle: '',
      problemDialogFormVisible: false,
      problemFaults: [],
      problemForm: {
        problemFault: '',
        descriptionReason: '',
        faultLocation: '',
        faultParts: '',
        descriptionReason1: ''
      },
      problemRules: {
        problemFault: [{ required: true, trigger: 'blur' }],
        descriptionReason: [{ required: true, trigger: 'blur' }],
        faultLocation: [{ required: true, trigger: 'blur' }],
        faultParts: [{ required: true, trigger: 'blur' }],
        descriptionReason1: [{ required: true, trigger: 'blur' }]
      },
      problemActiveNames: ['1'],
      faultCurrent: {},
      completeTitle: '',
      completeDialogFormVisible: false,
      acceptTitle: '',
      acceptDialogFormVisible: false,
      acceptAssessValue: 0,
      acceptAssess: '',
      acceptSwitch: false,
      acceptNoWork: '',
      supportTitle: '',
      supportDialogFormVisible: false,
      supportTableData: [],
      supportCount: 0,
      locusTitle: '',
      locusDialogFormVisible: false,
      locusTableData: [],
      locusOrder: '',
      contentServiceTableData: [],
      contentCount: 0,
      contentTitle: '',
      contentDialogFormVisible: false,
      contentSubmitValue: -1,
      contentValue: '',
      contentForm: {
        noWork: '',
        faultAnalysis: '',
        repairContent: '',
        improveSuggest: ''
      },
      contentRules: {
        noWork: [{ required: true, trigger: 'blur' }],
        // improveSuggest: [{ required: true, trigger: 'blur' }],
        repairContent: [{ required: true, trigger: 'blur' }],
        faultAnalysis: [{ required: true, trigger: 'blur' }]
      },
      contentWaitTime: 0,
      contentWait1: 0,
      contentWait2: 0,
      contentWait3: 0,
      contentWait4: 0,
      contentWait5: 0,
      contentWait6: 0,
      contentWait7: 0,
      spareTableData1: [],
      spareCount: '',
      spareTitle: '',
      spareDialogFormVisible: false,
      spareSap1: '',
      spareName1: '',
      spareNum1: '',
      spareSap2: '',
      spareName2: '',
      spareNum2: '',
      spareSap3: '',
      spareName3: '',
      spareNum3: '',
      spareSap4: '',
      spareName4: '',
      spareNum4: '',
      spareValue: '',
      spareTitle1: '',
      spareDialogFormVisible1: false,
      spareSap: '',
      spareName: '',
      spareNum: '',
      assessTableData: [],
      assess: '',
      assessCount: 0,
      assessValue: 0,
      originalPeople: [],
      newPeople: [],
      loading: false,
      loadingFiles: false,
      tableDataFiles: [],
      spareTableData: [],
      spareTableData2: [],
      orderTableData: [],
      orderTableData10: [],
      orderTableData2: [],
      spareTotal: 0, // 总条数
      sparePageSize: 10, // 每页显示条数
      sparePageCurrent: 1, // 后台获取页
      locusTotal: 0, // 总条数
      locusPageSize: 10, // 每页显示条数
      locusPageCurrent: 1 // 后台获取页
    }
  },
  computed: {
    ...mapGetters([
      'sidebar',
      'avatar',
      'name',
      'id',
      'token',
      'cname'
    ])
  },
  created() {
    this.rowOrder = this.$route.query.jobNumber
    this.searchCurrentOrder()
    this.searchCurrentMachine()
    this.searchMaterialGroup()
  },
  methods: {
    // 表头样式
    tableHeaderColor() {
      return 'background-color: rgb(250, 250, 250);height:20px;border-bottom: 3px rgb(170, 170, 170) solid;color: rgb(35, 35, 35);font-weight: 5000;padding: 8px 10px'
    },
    tableHeaderColor1() {
      return 'height:20px;border-bottom: 3px rgb(170, 170, 170) solid;color: rgb(35, 35, 35);font-weight: 5000;padding: 8px 10px'
    },
    tableColor() {
      return 'border-color: #E8E8E8;padding: 0px'
    },
    tableColor1() {
      return 'border-color: #E8E8E8;padding: 12px 0px 10px 0px'
    },
    tableColor2() {
      return 'border-color: #E8E8E8;padding: 6px 0px 4px 0px'
    },
    tableColor3() {
      return 'border-color: #E8E8E8;padding: 7px 0px 5px 0px'
    },
    tableColor4() {
      return 'border-color: #E8E8E8;padding: 10px 0px 8px 0px'
    },
    uploadManual() {
      this.hadFile = []
      var param = []
      param[0] = ['设备代码', this.machineValue]
      param[1] = ['类型', 1]
      var Data = this.CreateData('11', '基础数据_设备文件_查询数据', param)
      ExecDatabase(Data).then(res => {
        this.suffix = res.data
        if (res.data.length > 0) {
          const server = `${MESDownloadFile}`.split('/')
          res.data.map(item => {
            this.hadFile.push({
              url: `http://${server[2]}/webpage/part/${item.uid}.${item.suffix}`,
              name: `${item.name}.${item.suffix}`,
              suffix: item.suffix,
              id: item.num
            })
          })
        }
      })
    },
    uploadManual1() {
      this.hadFile1 = []
      var param = []
      param[0] = ['设备代码', this.machineValue]
      param[1] = ['类型', 2]
      var Data = this.CreateData('11', '基础数据_设备文件_查询数据', param)
      ExecDatabase(Data).then(res => {
        this.suffix = res.data
        if (res.data.length > 0) {
          const server = `${MESDownloadFile}`.split('/')
          res.data.map(item => {
            this.hadFile1.push({
              url: `http://${server[2]}/webpage/part/${item.uid}.${item.suffix}`,
              name: `${item.name}.${item.suffix}`,
              suffix: item.suffix,
              id: item.num
            })
          })
        }
      })
    },
    // 获得物料组
    searchMaterialGroup() {
      var param = []
      var Data = this.CreateData('11', '基础数据_物料组_查询', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.materialGroups.push({
            label: v.物料组名称,
            value: v.物料组名称
          })
        })
      }).then(() => {
      })
    },
    changeValue() {
      this.spareName1 = ''
      this.sapNumber = ''
      this.spareSap1 = ''
    },
    getSAP() {
      this.sapNumbers = []
      var param = []
      param[0] = ['物料组名称', this.materialGroup]
      param[1] = ['设备编号', this.rowOrder.设备编号]
      var Data = this.CreateData('11', '备件管理_SAP编号_查询', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.sapNumbers.push({
            label: v.SAP编号,
            value: v.物料流水号,
            name: v.物料描述
          })
        })
      }).then(() => {
      })
    },
    selectSap() {
      for (let i = 0; i < this.sapNumbers.length; i++) {
        if (this.sapNumber === this.sapNumbers[i].value) {
          this.spareName1 = this.sapNumbers[i].name
        }
      }
    },
    // 查询当前设备信息
    searchCurrentMachine() {
      var param = []
      param[0] = ['设备编号', this.rowOrder.设备编号]
      var Data = this.CreateData('11', '维修工单_设备_查询', param)
      ExecDatabase(Data).then(response => {
        this.machineValue = response.data[0].设备代码
        this.machine = response.data[0]
        if (this.machine.图片 !== null) {
          this.machine.图片 = 'data:image/png;base64,' + this.machine.图片
        } else { this.machine.图片 = this.machine.图片 }
      })
    },
    // 查看设备信息
    details() {
      this.dialogFormVisible1 = true
      this.title1 = this.machine.资产号
      this.activeName1 = '1'
      this.getFileListMachine(1)
      this.getSpare1()
      this.getSpare2()
      this.getOrder()
      this.uploadManual()
    },
    getSpare1() {
      this.spareTableData = []
      var param = []
      param[0] = ['设备代码', this.machineValue]
      param[1] = ['PageSize', this.sparePageSize]
      param[2] = ['PageCurrent', this.sparePageCurrent]
      param[3] = ['PageCount', '1111', 'int', '1']
      param[4] = ['ItemCount', '1111', 'int', '1']
      var Data = this.CreateData('11', '维修工单_历史备件_查询', param)
      ExecDatabase(Data).then(response => {
        response.data.result.map(v => {
          this.spareTableData.push({
            备件代码: v.备件代码,
            工单号: v.工单号,
            SAP编码: v.SAP编码,
            备件名称: v.备件名称,
            数量: v.数量,
            二级帐: v.二级帐,
            操作时间: v.操作时间
          })
        })
        this.spareTotal = parseInt(response.data.output[0].ItemCount)
      })
    },
    getSpare2() {
      var param = []
      param[0] = ['设备代码', this.machineValue]
      var Data = this.CreateData('11', '基础数据_设备_备件信息查询', param)
      ExecDatabase(Data).then(response => {
        this.spareTableData2 = response.data
      })
    },
    getOrder() {
      this.orderTableData = []
      this.orderTableData10 = []
      this.orderTableData2 = []
      var param = []
      param[0] = ['设备代码', this.machineValue]
      param[1] = ['工单类型', 'EM']
      var Data = this.CreateData('11', '维修工单_工单历史_查询_拆分', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.orderTableData.push({
            维修工单代码: v.维修工单代码,
            故障名称: v.故障名称,
            故障现象: v.故障现象,
            工单号: v.工单号,
            状态代码: v.状态代码,
            状态: v.状态,
            开始时间: v.开始时间,
            持续时长: v.持续时长,
            设备代码: v.设备代码,
            设备编号: v.设备编号
          })
        })
      })
      var param1 = []
      param1[0] = ['设备代码', this.machineValue]
      param1[1] = ['工单类型', 'CM']
      var Data1 = this.CreateData('11', '维修工单_工单历史_查询_拆分', param1)
      ExecDatabase(Data1).then(response => {
        response.data.map(v => {
          this.orderTableData10.push({
            维修工单代码: v.维修工单代码,
            故障名称: v.故障名称,
            故障现象: v.故障现象,
            工单号: v.工单号,
            状态代码: v.状态代码,
            状态: v.状态,
            开始时间: v.开始时间,
            持续时长: v.持续时长,
            设备代码: v.设备代码,
            设备编号: v.设备编号
          })
        })
      })
      var param2 = []
      param2[0] = ['设备代码', this.machineValue]
      param2[1] = ['工单类型', 'PM']
      var Data2 = this.CreateData('11', '维修工单_工单历史_查询_拆分', param2)
      ExecDatabase(Data2).then(response => {
        response.data.map(v => {
          this.orderTableData2.push({
            维修工单代码: v.维修工单代码,
            故障名称: v.故障名称,
            故障现象: v.故障现象,
            工单号: v.工单号,
            状态代码: v.状态代码,
            状态: v.状态,
            开始时间: v.开始时间,
            持续时长: v.持续时长,
            设备代码: v.设备代码,
            设备编号: v.设备编号
          })
        })
      })
    },
    // 点击工单
    orderClick(row) {
      this.dialogFormVisible1 = false
      this.rowOrder = row
      this.searchCurrentMachine()
      this.searchCurrentOrder()
    },
    getFileListMachine(filesType) {
      this.loadingFiles = true
      this.tableDataFiles = []
      var param = []
      param[0] = ['设备代码', this.machineValue]
      param[1] = ['文件类型', filesType]
      var Data = this.CreateData('11', '基础数据_设备_文件查询', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.tableDataFiles.push({
            参考文档名称: v.参考文档名称,
            参考文档类型: v.参考文档类型,
            参考文档代码: v.参考文档代码
          })
        })
        this.loadingFiles = false
      })
    },
    /**
     * 详情页切换标签
     */
    handleClickMachineInfo(tab, event) {
      if (tab.name === '1') {
        this.uploadManual()
      } else if (tab.name === '2') {
        this.uploadManual1()
      }
    },
    downloadFiles(row) {
      var param = []
      param[0] = ['参考文档代码', row.参考文档代码]
      var Data = this.CreateData('2004', '基础数据_设备_文件下载', param)
      this.exportExcel_NPOI(Data)
    },
    // 获得当前工单数据
    searchCurrentOrder() {
      var param = []
      param[0] = ['维修工单代码', this.rowOrder.维修工单代码]
      param[1] = ['维修工单代码_check', 1]
      var Data = this.CreateData('11', '维修工单_当前工单_查询', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].维修人员姓名) {
          response.data[0].维修人员姓名 = response.data[0].维修人员姓名.split(',')
        }
        if (response.data[0].维修人员代码) {
          response.data[0].维修人员代码 = response.data[0].维修人员代码.split(',')
        }
        this.orderCurrent = response.data[0]
      }).then(() => {
        this.getServiceContent()
        this.getProblemFault()
        this.getSpare()
        this.getAssess()
      })
    },
    // 查询当前工单故障统计
    getProblemFault() {
      var param = []
      param[0] = ['故障代码', this.orderCurrent.故障代码]
      param[1] = ['设备代码', this.orderCurrent.设备代码]
      var Data = this.CreateData('11', '维修工单_故障统计_查询', param)
      ExecDatabase(Data).then(response => {
        this.faultCurrent = response.data[0]
        if (this.faultCurrent.故障占比) {
          this.faultCurrent.故障占比 = this.faultCurrent.故障占比 + '%'
        }
      })
    },
    // 获得当前工单维修内容
    getServiceContent() {
      this.contentServiceTableData = []
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      var Data = this.CreateData('11', '维修工单_维修内容_查询 ', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.contentServiceTableData.push({
            内容代码: v.内容代码,
            填写人: v.填写人,
            故障原因分析: v.故障原因分析,
            现场解决措施: v.现场解决措施,
            改进意见: v.改进意见,
            等待时间合计: v.等待时间合计,
            领件时间: v.领件时间,
            等操作者: v.等操作者,
            暂无备件: v.暂无备件,
            外部资源: v.外部资源,
            维修工具: v.维修工具,
            人力不足: v.人力不足,
            其他: v.其他
          })
        })
        this.contentCount = response.data.length
      })
    },
    // 获得当前工单备件信息
    getSpare() {
      this.spareTableData1 = []
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      var Data = this.CreateData('11', '维修工单_备件_查询 ', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.spareTableData1.push({
            备件代码: v.备件代码,
            申请人: v.申请人,
            SAP编码: v.SAP编码,
            描述: v.描述,
            数量: v.数量,
            二级帐: v.二级帐,
            物料流水号: v.物料流水号,
            物料组名称: v.物料组名称
          })
        })
        this.spareCount = response.data.length
      })
    },
    // 获得评价意见
    getAssess() {
      this.assessValue = 0
      this.assessTableData = []
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      var Data = this.CreateData('11', '维修工单_评价及意见_查询 ', param)
      ExecDatabase(Data).then(response => {
        if (response.data.length > 0) {
          this.assessValue = response.data[0].评价分数
        }
        response.data.map(v => {
          this.assessTableData.push({
            评价及意见: v.评价及意见,
            创建人: v.创建人,
            创建时间: v.创建时间
          })
        })
        this.assessCount = response.data.length
      })
    },
    // 人员安排
    statusArrange() {
      this.arrangeDialogFormVisible = true
      this.arrangeTitle = '选择人员'
      this.arrangementInput = ''
      this.getRepairman()
    },
    // 查询人员
    getRepairman() {
      this.arrangeTableData = []
      if (this.arrangementInput) { this.arrangementInput_check = 1 } else { this.arrangementInput_check = 0 }
      var param = []
      param[0] = ['关键字', this.arrangementInput]
      param[1] = ['关键字_check', this.arrangementInput_check]
      var Data = this.CreateData('11', '维修工单_维修人员_查询 ', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.arrangeTableData.push({
            安排代码: v.安排代码,
            人员代码: v.人员代码,
            姓名: v.姓名,
            技能: v.技能,
            等级: v.等级,
            技能代码: v.技能代码,
            维修工单代码: v.维修工单代码,
            维修工单号: v.维修工单号
          })
        })
      })
    },
    // 多选框条件隐藏
    arrangeTableCell(row) {
      if (row.row.维修工单号 !== null && row.columnIndex === 0) {
        return 'myCell'
      }
    },
    arrangeCellHeader(row) {
      if (row.columnIndex === 0) {
        return 'myCell'
      }
    },
    // 人员状态释放
    statusFreed(row) {
      var param = []
      param[0] = ['安排代码', row.安排代码]
      param[1] = ['维修工单代码', row.维修工单代码]
      param[2] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_维修人员_状态释放', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].result === '1') {
          this.$message({
            message: '信息编辑成功',
            type: 'success'
          })
          this.getRepairman()
          this.searchCurrentOrder()
        } else {
          this.$message.error('信息编辑失败')
        }
      })
    },
    // 人员状态释放
    statusFreed1(row) {
      var param = []
      param[0] = ['安排代码', row.安排代码]
      param[1] = ['维修工单代码', row.维修工单代码]
      param[2] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_维修人员_状态释放1', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].result === '1') {
          this.$message({
            message: '信息编辑成功',
            type: 'success'
          })
          this.getRepairman()
          this.searchCurrentOrder()
        } else {
          this.$message.error('信息编辑失败')
        }
      })
    },
    // 选中维修人员
    peopleSelectionChange(val) {
      this.multipleSelection = val
      if (this.multipleSelection.length === 0) {
        this.arrangeAbled = true
      } else { this.arrangeAbled = false }
      this.newPeople = []
      for (let i = 0; i < this.multipleSelection.length; i++) {
        this.newPeople.push(this.multipleSelection[i].姓名)
      }
    },
    // 维修人员确认
    arrangeSubmit() {
      for (let i = 0; i < this.multipleSelection.length; i++) {
        var param = []
        param[0] = ['人员代码', this.multipleSelection[i].人员代码]
        param[1] = ['维修工单代码', this.orderCurrent.维修工单代码]
        var Data = this.CreateData('12', '维修工单_维修人员_安排工单', param)
        ExecDatabase(Data).then(response => {
          if (response.data[0].result === '1') {
            this.$message({
              message: '已安排',
              type: 'success'
            })
            this.searchCurrentOrder()
            this.arrangeDialogFormVisible = false
          } else {
            this.$message.error('人员安排失败')
          }
        })
      }
    },
    arrangeSubmit1() {
      this.originalPeople = this.orderCurrent.维修人员姓名
      if (this.originalPeople !== null) {
        this.newPeople = this.newPeople.concat(this.originalPeople)
      }
      var param = []
      param[0] = ['人员原值', this.originalPeople]
      param[1] = ['人员新值', this.newPeople]
      param[2] = ['维修工单代码', this.orderCurrent.维修工单代码]
      param[3] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_维修人员_操作轨迹', param)
      ExecDatabase(Data).then(response => {
      })
    },
    // 关闭人员安排弹出框
    arrangeCancle() {
      this.arrangeDialogFormVisible = false
    },
    // 人员到场
    statusReach() {
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      param[1] = ['是否停机', this.orderCurrent.是否停机]
      param[2] = ['设备代码', this.orderCurrent.设备代码]
      param[3] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_人员到场确认', param)
      ExecDatabase(Data).then(response => {
      }).then(() => {
        this.searchCurrentOrder()
      })
    },
    // 问题确定
    statusProblem() {
      if (this.$refs['problemForm'] !== undefined) {
        this.$refs['problemForm'].resetFields()
      }
      this.problemDialogFormVisible = true
      this.problemTitle = '问题确定'
      this.problemForm.descriptionReason = this.orderCurrent.故障状态描述
      this.problemForm.problemFault = this.orderCurrent.故障代码
      this.problemForm.faultLocation = this.orderCurrent.故障部位
      this.problemForm.faultParts = this.orderCurrent.故障部件
      this.problemForm.descriptionReason1 = this.orderCurrent.部件故障状态描述
      this.searchOrderFault()
    },
    // 查询问题分类
    searchOrderFault() {
      this.problemFaults = []
      var param = []
      var Data = this.CreateData('11', '维修工单_问题故障_查询', param)
      ExecDatabase(Data).then(response => {
        for (let i = 0; i < response.data.length; i++) {
          this.problemFaults.push({
            label: response.data[i].故障名称,
            value: response.data[i].故障代码
          })
        }
      })
    },
    // 问题确定保存
    problemSubmit(formName) {
      this.$refs[formName].validate((valid) => {
        if (valid) {
          var param = []
          param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
          param[1] = ['故障代码', this.problemForm.problemFault]
          param[2] = ['故障部位', this.problemForm.faultLocation]
          param[3] = ['故障部件', this.problemForm.faultParts]
          param[4] = ['部件故障状态描述', this.problemForm.descriptionReason1]
          param[5] = ['故障状态描述', this.problemForm.descriptionReason]
          param[6] = ['用户', this.cname]
          var Data = this.CreateData('12', '维修工单_问题确定', param)
          ExecDatabase(Data).then(response => {
            if (response.data[0].result === '1') {
              this.$message({
                message: '已保存',
                type: 'success'
              })
              this.searchCurrentOrder()
              this.problemDialogFormVisible = false
            } else {
              this.$message.error('信息编辑失败')
            }
          })
        }
      })
    },
    // 录入维修内容
    entryContent() {
      if (this.$refs['contentForm'] !== undefined) {
        this.$refs['contentForm'].resetFields()
      }
      this.contentDialogFormVisible = true
      this.contentTitle = '录入维修内容'
      this.contentSubmitValue = 1
      this.contentForm.faultAnalysis = ''
      this.contentForm.repairContent = ''
      this.contentForm.improveSuggest = ''
      this.contentForm.noWork = ''
      this.contentWaitTime = 0
      this.contentWait1 = 0
      this.contentWait2 = 0
      this.contentWait3 = 0
      this.contentWait4 = 0
      this.contentWait5 = 0
      this.contentWait6 = 0
      this.contentWait7 = 0
    },
    contentSum() {
      this.contentWaitTime = this.contentWait1 + this.contentWait2 + this.contentWait3 + this.contentWait4 + this.contentWait5 + this.contentWait6 + this.contentWait7
    },
    // 修改维修内容
    editContent(row) {
      if (this.$refs['contentForm'] !== undefined) {
        this.$refs['contentForm'].resetFields()
      }
      this.contentSubmitValue = 2
      this.contentDialogFormVisible = true
      this.contentTitle = '修改维修内容'
      this.contentValue = row.内容代码
      this.contentForm.faultAnalysis = row.故障原因分析
      this.contentForm.repairContent = row.现场解决措施
      this.contentForm.improveSuggest = row.改进意见
      this.contentForm.noWork = this.orderCurrent.导致停产时间
      this.contentWaitTime = row.等待时间合计
      this.contentWait1 = row.领件时间
      this.contentWait2 = row.等操作者
      this.contentWait3 = row.暂无备件
      this.contentWait4 = row.外部资源
      this.contentWait5 = row.维修工具
      this.contentWait6 = row.人力不足
      this.contentWait7 = row.其他
    },
    // 维修内容确定保存
    contentSubmit(formName) {
      this.$refs[formName].validate((valid) => {
        if (valid) {
          var param = []
          param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
          param[1] = ['维修人员代码', this.id]
          param[2] = ['等待时间合计', this.contentWaitTime]
          param[3] = ['领件时间', this.contentWait1]
          param[4] = ['等操作者', this.contentWait2]
          param[5] = ['暂无备件', this.contentWait3]
          param[6] = ['外部资源', this.contentWait4]
          param[7] = ['维修工具', this.contentWait5]
          param[8] = ['人力不足', this.contentWait6]
          param[9] = ['其他', this.contentWait7]
          param[10] = ['故障原因分析', this.contentForm.faultAnalysis]
          param[11] = ['现场解决措施', this.contentForm.repairContent]
          param[12] = ['改进意见', this.contentForm.improveSuggest]
          param[13] = ['导致停产时间', this.contentForm.noWork]
          var Data = this.CreateData('12', '维修工单_维修内容_增加', param)
          ExecDatabase(Data).then(response => {
            if (response.data[0].result === '1') {
              this.$message({
                message: '已保存',
                type: 'success'
              })
              this.searchCurrentOrder()
              this.contentDialogFormVisible = false
            } else {
              this.$message.error('信息编辑失败')
            }
          })
        }
      })
    },
    // 修改维修内容确定保存
    contentEditSubmit(formName) {
      this.$refs[formName].validate((valid) => {
        if (valid) {
          var param = []
          param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
          param[1] = ['维修人员代码', this.id]
          param[2] = ['等待时间合计', this.contentWaitTime]
          param[3] = ['领件时间', this.contentWait1]
          param[4] = ['等操作者', this.contentWait2]
          param[5] = ['暂无备件', this.contentWait3]
          param[6] = ['外部资源', this.contentWait4]
          param[7] = ['维修工具', this.contentWait5]
          param[8] = ['人力不足', this.contentWait6]
          param[9] = ['其他', this.contentWait7]
          param[10] = ['故障原因分析', this.contentForm.faultAnalysis]
          param[11] = ['现场解决措施', this.contentForm.repairContent]
          param[12] = ['改进意见', this.contentForm.improveSuggest]
          param[13] = ['导致停产时间', this.contentForm.noWork]
          param[14] = ['内容代码', this.contentValue]
          var Data = this.CreateData('12', '维修工单_维修内容_修改', param)
          ExecDatabase(Data).then(response => {
            if (response.data[0].result === '1') {
              this.$message({
                message: '已保存',
                type: 'success'
              })
              this.searchCurrentOrder()
              this.contentDialogFormVisible = false
            } else {
              this.$message.error('信息编辑失败')
            }
          })
        }
      })
    },
    // 关闭维修内容弹出框
    contentCancle(formName) {
      this.$refs[formName].resetFields()
      this.contentDialogFormVisible = false
    },
    // 录入备件信息
    entrySpare() {
      this.spareDialogFormVisible = true
      this.spareTitle = '录入备件信息'
      this.value = false
      this.materialGroup = ''
      this.sapNumber = ''
      this.spareSap1 = ''
      this.spareName1 = ''
      this.spareNum1 = ''
      this.spareNum2 = ''
    },
    // 备件确定保存
    spareSubmit() {
      if (this.value) {
        if (!(this.spareSap1 && this.spareNum1 !== '' && this.spareNum1 !== null && this.spareNum2 !== '' && this.spareNum2 !== null && this.spareName1)) {
          this.$message.warning('数据不完整')
          return
        }
      } else {
        if (!(this.sapNumber && this.spareNum1 !== '' && this.spareNum1 !== null && this.spareNum2 !== '' && this.spareNum2 !== null && this.spareName1)) {
          this.$message.warning('数据不完整')
          return
        }
      }
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      param[1] = ['维修人员代码', this.id]
      if (this.value) {
        param[2] = ['SAP编码', this.spareSap1]
      } else {
        param[2] = ['SAP编码', '']
      }
      param[3] = ['描述', this.spareName1]
      param[4] = ['数量', this.spareNum1]
      param[5] = ['二级帐', this.spareNum2]
      if (this.value) {
        param[6] = ['物料流水号', 0]
      } else {
        param[6] = ['物料流水号', this.sapNumber]
      }
      var Data = this.CreateData('12', '维修工单_备件信息_增加新', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].result === '1') {
          this.$message({
            message: '已添加',
            type: 'success'
          })
          this.searchCurrentOrder()
        } else {
          this.$message.error('信息添加失败')
        }
      })
    },
    // 关闭备件弹出框
    spareCancle() {
      this.spareDialogFormVisible = false
    },
    // 修改备件信息
    editSpare(row) {
      this.spareDialogFormVisible1 = true
      this.spareTitle1 = '修改备件信息'
      Number(row.物料流水号) ? this.value = false : this.value = true
      this.materialGroup = row.物料组名称
      this.sapNumber = row.物料流水号
      this.spareSap1 = row.SAP编码
      this.spareName1 = row.描述
      this.spareNum1 = row.数量
      this.spareNum2 = row.二级帐
      this.spareValue = row.备件代码
    },
    // 备件确定保存
    spareSubmit1() {
      if (this.value) {
        if (!(this.spareSap1 && this.spareNum1 !== '' && this.spareNum1 !== null && this.spareNum2 !== '' && this.spareNum2 !== null && this.spareName1)) {
          this.$message.warning('数据不完整')
          return
        }
      } else {
        if (!(this.sapNumber && this.spareNum1 !== '' && this.spareNum1 !== null && this.spareNum2 !== '' && this.spareNum2 !== null && this.spareName1)) {
          this.$message.warning('数据不完整')
          return
        }
      }
      var param = []
      param[0] = ['备件代码', this.spareValue]
      param[1] = ['维修人员代码', this.id]
      if (this.value) {
        param[2] = ['SAP编码', this.spareSap1]
      } else {
        param[2] = ['SAP编码', '']
      }
      param[3] = ['描述', this.spareName1]
      param[4] = ['数量', this.spareNum1]
      param[5] = ['二级帐', this.spareNum2]
      if (this.value) {
        param[6] = ['物料流水号', 0]
      } else {
        param[6] = ['物料流水号', this.sapNumber]
      }
      var Data = this.CreateData('12', '维修工单_备件信息_修改', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].result === '1') {
          this.$message({
            message: '已保存',
            type: 'success'
          })
          this.searchCurrentOrder()
          this.spareDialogFormVisible1 = false
        } else {
          this.$message.error('信息编辑失败')
        }
      })
    },
    // 关闭备件弹出框
    spareCancle1() {
      this.spareDialogFormVisible1 = false
    },
    deleteSpare(row) {
      this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning'
      }).then(() => {
        var param = []
        param[0] = ['备件代码', row.备件代码]
        var Data = this.CreateData('12', '维修工单_备件信息_删除', param)
        ExecDatabase(Data).then(response => {
          if (response.data[0].result === '1') {
            this.$message.success('删除成功')
            this.searchCurrentOrder()
          } else {
            this.$message.error('删除失败')
          }
        })
      }).catch(() => {
        this.$message({
          type: 'info',
          message: '已取消删除'
        })
      })
    },
    // 维修完成
    statusRepair() {
      this.completeDialogFormVisible = true
    },
    // 确认维修完成
    completeSubmit() {
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      param[1] = ['是否停机', this.orderCurrent.是否停机]
      param[2] = ['设备代码', this.orderCurrent.设备代码]
      param[3] = ['用户', this.cname]
      param[4] = ['故障代码', this.orderCurrent.故障代码]
      var Data = this.CreateData('12', '维修工单_维修完成', param)
      ExecDatabase(Data).then(response => {
      }).then(() => {
        this.searchCurrentOrder()
        this.completeDialogFormVisible = false
      })
    },
    // 关闭维修完成弹出框
    completeCancle() {
      this.completeDialogFormVisible = false
    },
    // 打开确认接受弹出框
    statusAccept() {
      this.acceptDialogFormVisible = true
      this.acceptTitle = '工单确认详情'
      this.acceptAssessValue = 3
      this.acceptAssess = ''
      this.acceptNoWork = this.orderCurrent.导致停产时间
      this.acceptSwitch = false
    },
    // 确认接受
    acceptSubmit() {
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      param[1] = ['创建人', this.cname]
      param[2] = ['评价及意见', this.acceptAssess]
      param[3] = ['评价分数', this.acceptAssessValue]
      param[4] = ['是否停机', this.orderCurrent.是否停机]
      param[5] = ['设备代码', this.orderCurrent.设备代码]
      param[6] = ['用户', this.cname]
      param[7] = ['导致停产时间', this.acceptNoWork]
      param[8] = ['是否带病运转', this.acceptSwitch ? 1 : 0]
      var Data = this.CreateData('12', '维修工单_评价及意见_增加', param)
      ExecDatabase(Data).then(response => {
        if (response.data[0].result === '1') {
          this.$message({
            message: '已保存',
            type: 'success'
          })
          this.searchCurrentOrder()
          this.acceptDialogFormVisible = false
        } else {
          this.$message.error('信息编辑失败')
        }
      })
    },
    // 关闭确认接受弹出框
    acceptCancle() {
      this.acceptDialogFormVisible = false
    },
    // 打开操作轨迹弹出框
    orderMap() {
      this.locusDialogFormVisible = true
      this.locusTitle = '工单操作轨迹'
      this.getLocus()
    },
    // 查询操作轨迹数据
    getLocus() {
      this.locusTableData = []
      var param = []
      param[0] = ['PageSize', this.locusPageSize]
      param[1] = ['PageCurrent', this.locusPageCurrent]
      param[2] = ['PageCount', '1111', 'int', '1']
      param[3] = ['ItemCount', '1111', 'int', '1']
      param[4] = ['维修工单代码', this.orderCurrent.维修工单代码]
      var Data = this.CreateData('11', '维修工单_操作轨迹_查询_分页', param)
      ExecDatabase(Data).then(response => {
        response.data.result.map(v => {
          this.locusTableData.push({
            日期时间: v.日期时间,
            类型: v.类型,
            原值: v.原值,
            新值: v.新值,
            用户: v.用户
          })
        })
        this.locusTotal = parseInt(response.data.output[0].ItemCount)
        this.loading = false
      })
    },
    // 申请技术支援
    support() {
      this.supportDialogFormVisible = true
      this.supportTitle = '申请技术支援'
      this.getSupportContent()
    },
    // 查询技术支援内容
    getSupportContent() {
      this.supportTableData = []
      var param = []
      param[0] = ['维修工单代码', this.orderCurrent.维修工单代码]
      var Data = this.CreateData('11', '维修工单_技术支援_维修班长 ', param)
      ExecDatabase(Data).then(response => {
        response.data.map(v => {
          this.supportTableData.push({
            申请代码: v.申请代码,
            申请人代码: v.申请人代码,
            姓名: v.姓名,
            是否同意: v.是否同意,
            技术支援内容: v.技术支援内容,
            技术支援代码: v.技术支援代码,
            维修工单代码: v.维修工单代码,
            维修工单号: v.维修工单号
          })
          this.supportCount = response.data.length
        })
      })
    },
    // 同意
    agree(row) {
      var param = []
      param[0] = ['申请代码', row.申请代码]
      param[1] = ['维修工单代码', row.维修工单代码]
      param[2] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_技术支援_同意', param)
      ExecDatabase(Data).then(response => {
        this.getSupportContent()
      })
    },
    // 同意
    disagree(row) {
      var param = []
      param[0] = ['申请代码', row.申请代码]
      param[1] = ['维修工单代码', row.维修工单代码]
      param[2] = ['用户', this.cname]
      var Data = this.CreateData('12', '维修工单_技术支援_不同意', param)
      ExecDatabase(Data).then(response => {
        this.getSupportContent()
      })
    },
    handleSizeChange1(val) {
      this.sparePageCurrent = 1
      this.sparePageSize = val
      this.getSpare1()
    },
    handleCurrentChange1(val) {
      this.sparePageCurrent = val
      this.getSpare1()
    },
    locusSizeChange(val) {
      this.locusPageCurrent = 1
      this.locusPageSize = val
      this.getLocus()
    },
    locusCurrentChange(val) {
      this.locusPageCurrent = val
      this.getLocus()
    }
  }
}
</script>

<style scoped>
  .div {
    width: 200px;
    height:45px;
    margin-top: 0px;
    border-bottom: rgb(220,220,220) solid 2px
  }
  .div3{
    font-size: 20px;
    color:#a9a9a9;
    margin-top:10px;
  }
  .div4{
    font-size: 18px;
    font-weight: bold;
    margin-top:10px;
  }
  .div5 {
    font-size: 24px;
    margin: 10px 0px;
  }
  .card{
    margin-bottom: 40px;
    padding: 10px;
  }
  >>>.formItem1 .el-form-item__label {
    line-height: 0px;
    margin-left: 5px;
  }
  >>>.formItem1 .el-form-item {
    margin-bottom: 18px;
  }
  >>>.formItem2 .el-form-item__label {
    line-height: 0px;
    margin-left: 5px;
  }
  >>>.formItem2 .el-form-item {
    margin-bottom: 20px;
  }
  >>>.inputext .el-textarea__inner {
    background-color: rgb(255,255,255);
    border-top: 0px;
    border-left: 0px;
    border-right: 0px;
    border-bottom: 1px solid;
    color: #C0C4CC;
    cursor: text;
    height: 80px;
    width: 80%;
  }
  >>>.inputext .el-textarea__inner:focus {
    background-color: rgb(238,239,240);
  }
  >>>.inputext2 .el-textarea__inner {
    padding: 5px 15px;
    line-height: 1.5;
    width: 100%;
    height: 90px;
    background-color: rgb(247,247,247);
    border-color: rgb(247,247,247);
    border-bottom: 1px solid rgb(207,208,209);
  }
  >>>.inputext2 .el-textarea__inner:focus {
    background-color: rgb(239,239,240);
  }
  >>>.dialog1 .el-dialog__header {
    padding: 40px 20px 10px 40px;
  }
  >>>.dialog2 .el-dialog__header {
    padding: 45px 20px 35px 45px;
  }
  >>>.dialog2 .el-dialog__body {
    padding: 5px 50px 30px 50px;
  }
  >>>.dialog3 .el-dialog__header {
    padding: 45px 25px 25px 40px;
  }
  >>>.dialog3 .el-dialog__body {
    padding: 0px 25px 30px 35px;
  }
  >>>.dialog4 .el-dialog__header {
    padding: 45px 25px 30px 35px;
  }
  >>>.dialog4 .el-dialog__body {
    padding: 0px 25px 30px 45px;
  }
  >>>.dialog5 .el-dialog__header {
    padding: 45px 25px 25px 40px;
  }
  >>>.dialog5 .el-dialog__body {
    padding: 0px 25px 40px 20px;
  }
  >>>.rate1 .el-rate__icon {
    font-size: 22px;
  }
  >>>.myCell .el-checkbox__input {
    display: none
  }
  >>>.collapse1 .el-collapse-item__header {
    font-size: 17px;
  }
  >>>.input1 .el-input__icon {
    font-size: 20px;
    background-color: rgb(247,247,247);
    width: 52px;
    border-bottom: 1px rgb(207,208,209) solid;
  }
  >>>.input1 .el-input__prefix {
    width: 20px;
    position: absolute;
    left: 128px;
  }
  >>>.input1 .el-input__inner {
    width: 100%;
    height: 48px;
    border-radius: 0px;
    border-color: white;
    border-bottom: 1px rgb(207,208,209) solid;
    padding: 0px 5px;
  }
  >>>.input1 .el-input__inner:focus {
    background-color: rgb(239,239,240);
  }
  >>>.input2 .el-icon-time:before {
    content: "";
  }
  >>>.input2 .el-input__inner {
    width: 100%;
    height: 48px;
    border-radius: 0px;
    border-color: white;
    border-bottom: 1px rgb(207,208,209) solid;
    padding: 0px 5px;
  }
  >>>.input2 .el-input__inner:focus {
    background-color: rgb(239,239,240);
  }
  >>>.el-radio__label {
    font-size: 18px;
    padding-left: 10px;
  }
  >>>.el-radio {
    color: #606266;
    font-weight: 500;
    line-height: 2;
    cursor: pointer;
    outline: 0;
    margin-right: 40px;
  }
  .wrapper{
    width: 90%;
    height: 50px;
    overflow: hidden;
    border: 1px solid #b8c7d9;
    /*float: left;*/
    margin: 10px;
  }
  .content{
    position: relative;
    padding: 8px 8px 0 8px;
  }
  .action{
    position: absolute;
    top: 2px;
    right: 8px;
  }
  .delete{
    padding: 0 5px;
    border-radius: 3px;
    color: #0f84b0;
    font-size: 12px;
  }
  .delete:hover{
    background: -webkit-linear-gradient(top,#0ba9e3,#0099d3);
    color: #fff;
  }
  a{
    text-decoration: none;
  }
  .icon{
    width: 30px;
    height: 30px;
    display: inline-block;
    margin-right: 7px;
    margin-top: 2px;
    font-size: 26px;
  }
  .info{
    width: 300px;
    height: 50px;
    left: 44px;
    line-height: 30px;
    display: inline-block;
    color: #999;
  }
</style>
