<!--对了3张表字段，别的没有做-->
<template>
  <div class="examination">
    <div class="common-head-search">
      <el-form :inline="true">
        <el-form-item label='项目类型'>
          <el-select v-model="search.itemTypeCode" clearable filterable collapse-tags  size="small" style="width: 200px;">
            <el-option v-for="(item,index) in itemTypeNameType" :key="index" :label="item.baseName"
              :value="item.baseCode">
            </el-option>
          </el-select>
        </el-form-item>
        <el-form-item label='测试项目名称'>
          <el-input v-model="search.testItemName" @keyup.enter.native="searchData" size="small" placeholder="请输入查询内容" style="width: 200px;"></el-input>
        </el-form-item>
        <el-form-item>
          <el-button icon="el-icon-search" type="goon" size="mini" @click="searchData">查询</el-button>
          <el-button icon="el-icon-refresh" type="info" plain size="mini" @click="reset">重置</el-button>
        </el-form-item>
      </el-form>
    </div>
    <div class="common-title-div" style="margin-bottom:0;margin-top:0">
      <div class="common-title-name">
        <img style="width: 25px; height: 25px" src='../../../../assets/img/imgScreen/logo.png' />
        测试项目
      </div>
      <div>
      <el-button icon="el-icon-circle-plus-outline" type="goon" size="mini" @click="addData" v-privilege="activeMenu + 'ADD'">新增</el-button>
      <el-button icon="el-icon-edit" type="goon" size="mini" @click="modifyData" v-privilege="activeMenu + 'PUT'">修改</el-button>
      <el-button icon="el-icon-circle-plus-outline" type="goon" size="mini" :loading='copyLoading' v-privilege="activeMenu + 'copy'" @click="copyData">复制</el-button>
      <el-button icon="el-icon-circle-close" type="danger" size="mini" @click="deleteData" v-privilege="activeMenu + 'disable'">停用</el-button>
      <el-button icon="el-icon-check" type="goon" size="mini" @click="recoverData" v-privilege="activeMenu + 'effectivity'">启用</el-button>
      <el-button icon="el-icon-check" type="goon" size="mini" :loading='batchLoading' @click="batchData" v-privilege="activeMenu + 'syn'">批量配置同步</el-button>
      </div>
    </div>
    <div class="common-table-div" style="margin-bottom:0">
       <el-table v-loading="dataLoading" ref="dataTable" border :height="heightTop" highlight-current-row @current-change="handleCurrentChange" @selection-change="handleSelectionChange" :data="table.list" :icore-filter-flag="icoreFilterFlag"
       :header-cell-style="tableHeaderCellStyle" :row-class-name="tableRowClassName" :summary-method="getSummaries" show-summary>
        <el-table-column type="index" label="NO" fixed="left" align="center"></el-table-column>
        <el-table-column type="selection" width="55" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemNo" label="测试项目编号" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemName" label="测试项目名称" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="itemTypeName" label="项目类型" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px"  prop="validFlag1" label="数据状态" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="testCnt" label="测试次数" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="pointName" label="作业点" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="ruleName" label="业务规则" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="testPostName" label="测试岗位" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemDesc" label="测试项目描述" align="center"></el-table-column>
        <!-- <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemEng" label="测试项目英文" align="center"></el-table-column> -->
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="eqpTypeName" label="测试设备" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="testLimit" label="测试时限" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="itemTemp" label="测试温度" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isTest1" label="是否免检" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isCtrl1" label="是否控制" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="100px" prop="isAuto1" label="是否自动执行" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isSon1" label="是否子任务" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isSyn1" label="是否同步" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isMsg1" label="是否推送" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isIndex1" label="是否含指标" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isRefer1" label="是否引用" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="doOrder" label="显示顺序" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="200px" prop="memo" label="备注" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="createTime" label="创建时间" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="createMan" label="创建人" align="center"></el-table-column>
      </el-table>
    </div>
    <div class="common-foot-style">
        <el-pagination @size-change="pageSizeChange" @current-change="pageCurrentChange"
          :current-page="page.pageNum" :page-sizes="[10, 20, 50, 100, 200]" :page-size="page.pageSize" layout="total, sizes, prev, pager, next, jumper"
          :total="page.totalPage" background>
        </el-pagination>
    </div>
    <div style="margin-top:40px">
    <template>
    <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
    <el-tab-pane label="分析项目" name="first">
       <div>
    <div class="common-title-div">
      <div class="common-title-name">
        <img style="width: 25px; height: 25px" src='../../../../assets/img/imgScreen/logo.png' />
        分析项目
      </div>
      <div>
      <el-button icon="el-icon-circle-plus-outline" type="goon" size="mini" @click="addData2" v-privilege="activeMenu + 'ADD'">新增</el-button>
      <el-button icon="el-icon-edit" type="goon" size="mini" @click="modifyData2" v-privilege="activeMenu + 'PUT'">修改</el-button>
      <el-button icon="el-icon-circle-close" type="danger" size="mini" @click="deleteData2" v-privilege="activeMenu + 'disable'">停用</el-button>
      <el-button icon="el-icon-check" type="goon" size="mini" @click="recoverData2" v-privilege="activeMenu + 'effectivity'">启用</el-button>
      <el-button icon="el-icon-circle-close" type="danger" :loading='deleteLoading' size="mini" @click="deleteDatas" v-privilege="activeMenu + 'DELETE'">删除</el-button>
      </div>
    </div>
    <div class="common-table-div" style="margin-bottom:0;margin-top:0">
       <el-table v-loading="dataLoading2" ref="dataTable2" border :height="heightBot" highlight-current-row @selection-change="handleSelectionChange2" :data="table.list2" :icore-filter-flag="icoreFilterFlag2"
       :header-cell-style="tableHeaderCellStyle" :row-class-name="tableRowClassName2" :summary-method="getSummaries" show-summary>
        <el-table-column type="index" label="NO" fixed="left" align="center">
        </el-table-column>
        <el-table-column type="selection" width="55" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemNo" label="测试任务编码" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemName" label="测试任务名称" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemNo" label="分析项目编号" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemName" label="分析项目名称" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="formulaName" label="计算公式" align="center"></el-table-column>
        <!-- <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemAlias" label="分析项目别名" align="center"></el-table-column> -->
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="unitName" label="数值单位" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="defaultValue" label="默认值" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px"  prop="validFlag1" label="数据状态" align="center">
          <!-- <template slot-scope="scope">
              <span v-if="scope.row.validFlag == 1">有效</span>
              <span v-else-if="scope.row.validFlag == 0">无效</span>
          </template> -->
        </el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dspOrder" label="显示顺序" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dataTypeName" label="数据类型" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="reviseRuleName" label="修约规则" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="anlyCnt" label="分析次数" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="outputTypeName" label="输出类型" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minSign" label="下限符" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minValue" label="下限值" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxSign" label="上限符" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxValue" label="上限值" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxLimit" label="方法上限值" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minLimit" label="方法下限值" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isReport1" label="是否报出" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isRare1" label="是否贵重" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isLogin1" label="是否必检" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isAlarm1" label="是否报警" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isCompute1" label="是否计算" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isMid1" label="是否中间项" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="200px" prop="memo" label="备注" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="createTime" label="创建时间" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="createMan" label="创建人" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="updateTime" label="修改时间" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="updateMan" label="修改人" align="center"></el-table-column>
      </el-table>
    </div>
    <!-- <div class="common-foot-style">
        <el-pagination v-loading="dataLoading2" @size-change="pageSizeChange2" @current-change="pageCurrentChange2"
          :current-page="page2.pageNum" :page-sizes="[10, 20, 50, 100, 200]" :page-size="page2.pageSize" layout="total, sizes, prev, pager, next, jumper"
          :total="page2.totalPage" background>
        </el-pagination>
    </div> -->
    </div>
    </el-tab-pane>
    <el-tab-pane label="方法标准" name="second">
    <div>
    <div class="common-title-div">
      <div class="common-title-name">
        <img style="width: 25px; height: 25px" src='../../../../assets/img/imgScreen/logo.png' />
        方法标准
      </div>
      <div>
      <el-button icon="el-icon-circle-plus-outline" type="goon" size="mini" @click="addData3">新增</el-button>
      <el-button icon="el-icon-edit" type="goon" size="mini" @click="modifyData3">修改</el-button>
      <el-button icon="el-icon-circle-close" type="danger" size="mini" @click="deleteData3">停用</el-button>
      <el-button icon="el-icon-check" type="goon" size="mini" @click="recoverData3">启用</el-button>
      </div>
    </div>
    <div class="common-table-div" style="margin-bottom:0;margin-top:0">
       <el-table v-loading="dataLoading3" ref="dataTable3" border :height="heightBot" highlight-current-row @selection-change="handleSelectionChange3" :data="table.list3" :icore-filter-flag="icoreFilterFlag3"
       :header-cell-style="tableHeaderCellStyle" :row-class-name="tableRowClassName3" :summary-method="getSummaries" show-summary>
        <el-table-column type="index" label="NO" fixed="left" align="center">
        </el-table-column>
        <el-table-column type="selection" width="55" align="center" ></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testStdNo" label="测试方法编号" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="testItemName" label="测试名称" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="stdName" label="方法名称" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="stdUsedName" label="标准用途类型" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="validFlag1" label="数据状态" align="center">
          <!-- <template slot-scope="scope">
              <span v-if="scope.row.validFlag == 1">有效</span>
              <span v-else-if="scope.row.validFlag == 0">无效</span>
          </template> -->
        </el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dspOrder" label="显示顺序" align="center"></el-table-column>
        <el-table-column sortable :show-overflow-tooltip="true" min-width="200px" prop="memo" label="备注" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="createTime" label="创建时间" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="createMan" label="创建人" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="updateTime" label="修改时间" align="center"></el-table-column>
        <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="updateMan" label="修改人" align="center"></el-table-column>
      </el-table>
    </div>
    <!-- <div class="common-foot-style">
        <el-pagination v-loading="dataLoading3" @size-change="pageSizeChange3" @current-change="pageCurrentChange3"
          :current-page="page3.pageNum" :page-sizes="[10, 20, 50, 100, 200]" :page-size="page3.pageSize" layout="total, sizes, prev, pager, next, jumper"
          :total="page3.totalPage" background>
        </el-pagination>
    </div> -->
    </div>
    </el-tab-pane>
    </el-tabs>
    </template>
    </div>
    <el-dialog @close="closeDialog" :close-on-click-modal='false' :visible.sync="dialogTableVisible" width='80%'>
        <div slot="title" class="titleBox">
         <i class="el-icon-document" style="font-size: 20px"></i>
        <span style="margin-left:10px;font-size:18px;margin-right:20px">新增分析项目</span>
        <span style="font-size:16px;color:#fff;">分析项目名称</span>
        <el-input v-model="anlyItemName" size="small" @keyup.enter.native="searchData2" style="width: 150px;"></el-input>
        <el-button icon="el-icon-search" type="goon" size="mini" @click="searchData2">查询</el-button>
        </div>
        <el-row>
          <el-col :span='12'>
            <div class="common-table-div">
               <el-table v-loading="fxdataLoading" ref="dataTable" border :height="350" highlight-current-row :data="fxlist" :icore-filter-flag="icoreFilterFlag"
               :header-cell-style="tableHeaderCellStyle" :cell-class-name="fxtableRowClassName" :summary-method="getSummaries" show-summary>
              <el-table-column type="index" label="NO" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="" label="操作" align="center">
                <template slot-scope="{row}">
                  <el-button type="text" size='mini' @click="checkRow(row)">添加</el-button>
                </template>
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="100px" prop="anlyItemNo" label="分析项目编号" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemName" label="分析项目名称" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="validFlag1" label="数据状态" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="itemTypeName" label="项目类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dspOrder" label="显示顺序" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dataTypeName" label="数据类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemAlias" label="分析项目别名" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemDesc" label="分析项目描述" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemEng" label="分析项目英文" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="unitName" label="度量单位" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="formulaName" label="计算公式" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="reviseRuleName" label="修约规则" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="outputTypeName" label="输出类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="defaultValue" label="默认值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxSign" label="上限符" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxValue" label="上限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minSign" label="下限符" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minValue" label="下限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxLimit" label="方法上限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minLimit" label="方法下限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="anlyCnt" label="分析次数" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isCompute1" label="是否计算" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" prop="isMid1" min-width="90px" label="是否中间项" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" prop="isReport1" min-width="80px" label="是否报出" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isLogin1" label="是否必检" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isAlarm1" label="是否报警" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isRare1" label="是否贵重" align="center">
              </el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="createTime" label="创建时间" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="createMan" label="创建人" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="updateTime" label="修改时间" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="updateMan" label="修改人" align="center"></el-table-column>
               </el-table>
               </div>
              <div class="common-foot-style">
              <el-pagination @size-change="fxpageSizeChange" @current-change="fxpageCurrentChange"
                :current-page="fxpage.pageNum" :page-sizes="[100, 200,500]" :page-size="fxpage.pageSize" layout="total, sizes, prev, pager, next"
                :total="fxpage.totalPage" background>
              </el-pagination>
            </div>
          </el-col>
          <el-col :span='12'>
            <div class="common-table-div">
               <el-table  border :height="350"  :data="checkList" :icore-filter-flag="icoreFilterFlag"
               :header-cell-style="tableHeaderCellStyle" :cell-class-name="fxtableRowClassName" :summary-method="getSummaries" show-summary>
              <el-table-column type="index" label="NO" fixed="left" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="" label="操作" align="center">
                <template slot-scope="scope">
                  <el-button type="text" size='mini' @click="removeItem(scope.$index)">删除</el-button>
                </template>
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="100px" prop="anlyItemNo" label="分析项目编号" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemName" label="分析项目名称" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="validFlag1" label="数据状态" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="itemTypeName" label="项目类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dspOrder" label="显示顺序" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="dataTypeName" label="数据类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemAlias" label="分析项目别名" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemDesc" label="分析项目描述" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="120px" prop="anlyItemEng" label="分析项目英文" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="unitName" label="度量单位" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="formulaName" label="计算公式" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="reviseRuleName" label="修约规则" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="outputTypeName" label="输出类型" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="defaultValue" label="默认值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxSign" label="上限符" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxValue" label="上限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minSign" label="下限符" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minValue" label="下限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="maxLimit" label="方法上限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="minLimit" label="方法下限值" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="anlyCnt" label="分析次数" align="center"></el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isCompute1" label="是否计算" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="90px" prop="isMid1" label="是否中间项" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isReport1" label="是否报出" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isLogin1" label="是否必检" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isAlarm1" label="是否报警" align="center">
              </el-table-column>
              <el-table-column sortable :show-overflow-tooltip="true" min-width="80px" prop="isRare1" label="是否贵重" align="center">
              </el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="createTime" label="创建时间" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="createMan" label="创建人" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="160px" prop="updateTime" label="修改时间" align="center"></el-table-column>
              <el-table-column  sortable :show-overflow-tooltip="true" min-width="80px" prop="updateMan" label="修改人" align="center"></el-table-column>
               </el-table>
               </div>
          </el-col>
        </el-row>
       <div style="margin-top: 20px; margin-right: 50px" class="clearfix">
       <span slot="footer" class="dialog-footer" style="float:right">
        <el-button type="goon"  icon="el-icon-check" size="mini" @click="fxaddData()">确定</el-button>
        <el-button size="mini"  type="goon" icon="el-icon-remove-outline" @click="cancel">取消</el-button>
      </span>
       </div>
    </el-dialog>
    <div is="alertComponets" :showFlag="showFlag" :Params="Params" @refresh='refresh'></div>
    <!-- <div is="alertComponets2" :showFlag="showFlag2" :Params="Params2" @refresh='refresh2'></div> -->
    <div is="alertComponets3" :showFlag="showFlag3" :Params="Params3" @refresh='refresh2'></div>
    <div is="alertComponets4" :showFlag="showFlag4" :Params="Params5" :Params2="Params4" @refresh='refresh3'></div>
  </div>
</template>
<script>
import {
  getCookie
} from '@/utils/util.js';
import {
  cookieUserId,
  cookieUserName
} from '@/config/config.js';
import alertComponets from './alertComponents';
import alertComponets3 from './alertComponents3';
import alertComponets4 from './alertComponents4';
let userName = getCookie(cookieUserName);
let userId = getCookie(cookieUserId);
export default {
  components: {alertComponets, alertComponets3, alertComponets4},
  data () {
    return {
      table: {
        list: [],
        list2: [],
        list3: []
      },
      fxlist:[],
      checkList:[],
      fxdataLoading:false,
      deleteLoading:false,
      dataLoading: false,
      dataLoading2: false,
      dataLoading3: false,
      icoreFilterFlag: true,
      icoreFilterFlag2: true,
      icoreFilterFlag3: true,
      activeName: 'first',
      copyLoading:false,
      page: {
        pageSize: 50,
        pageNum: 1,
        totalPage: 0
      },
      fxpage: {
        pageSize: 500,
        pageNum: 1,
        totalPage: 0
      },
      page2: {
        pageSize: 990,
        pageNum: 1,
        totalPage: 0
      },
      page3: {
        pageSize: 990,
        pageNum: 1,
        totalPage: 0
      },
      dialogTableVisible:false,
      anlyItemName:'',
      testItemNo: '',
      showFlag: false,
      showFlag2: false,
      showFlag3: false,
      showFlag4: false,
      Params: {},
      Params2: {},
      Params3: {},
      Params4: {},
      Params5: {},
      multipleSelection: [],
      multipleSelection2: [],
      multipleSelection3: [],
      testItemNameType: [],
      search: {
        itemTypeCode:'',
        testItemName: ''
      },
      curItemTypeCode: '',
      batchLoading:false,
      itemTypeNameType:[],
      heightTop:0,
      heightBot:0,
      activeMenu:''
    }
  },
  created(){
    this.heightTop = window.innerHeight/2 - 130 < 249  ? 249 : window.innerHeight/2 - 130;
    this.heightBot = window.innerHeight/2 - 130 < 249  ? 249 : window.innerHeight/2 - 130;
    this.activeMenu = window.top.localStorage.getItem('activeMenu')
    console.log('this.activeMenu', this.activeMenu)
  },
  mounted () {
    this.axios.post("pass/baseManagement/v1/limsbaseinfos/queryBaseInfoByBaseCode",{validFlag:1,baseCode:4804}, {individualType: 'json'}).then(res => {
      this.itemTypeNameType = res.data
    })
    this.getList()
    this.getDataList();
    // this.getDataList2();
    // this.getDataList3();
    this.gettestItemNameTypeList();
    this.addScreen();
    this.addScreen2();
    this.addScreen3();
  },
  methods: {
    handleClick(tab, event) {
    },
    gettestItemNameTypeList () {
       this.axios.get('pass/baseManagement/v1/limsstdtestitems/'+ '?validFlag=1')
            .then(res => {
              this.testItemNameType = res.data.list;
            })  
    },
    getSummaries(param) {
      const { columns, data } = param;
      const sums = [];
      columns.forEach((column, index) => {
        if (index === 0) {
          sums[index] = "合计";
        }
        if (index === 1) {
          sums[index] = data.length;
        } 
      });
      return sums;
    },
    closeDialog () {
      this.checkList = []
      this.anlyItemName = ''
      },
    cancel () {
      this.checkList = []
      this.anlyItemName = ''
      this.dialogTableVisible = false
      },
    refresh () {
      this.getDataList();
      this.getDataList2(this.testItemNo);
      this.getDataList3(this.testItemNo);
    },
    refresh2 () {
      this.getDataList2(this.testItemNo);
    },
    refresh3 () {
      this.getDataList3(this.testItemNo);
    },
    addData () {
      let _this = this;
      _this.showFlag = !_this.showFlag;
      _this.Params = null;
    },
    modifyData () {
      let _this = this;
      if (_this.multipleSelection.length !== 1) {
        this.$message.warning('请勾选您要修改的一条数据！')
      } else {
        _this.showFlag = !_this.showFlag;
        _this.Params = _this.multipleSelection
      }
    },
    recoverData () {
       let _this = this;
        if (_this.multipleSelection.length < 1) {
        this.$message.warning('请勾选您要启用的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection.length; j++) {
          if (_this.multipleSelection[j].validFlag === '1') {
          this.$message.warning('请勾选状态为已停用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible = false;
        for (var i = 0; i < _this.multipleSelection.length; i++) {
        _this.multipleSelection[i].updateMan = userName;
        _this.multipleSelection[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestitems/recover', _this.multipleSelection, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('启用成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    batchData () {
      if (this.multipleSelection.length < 1) {
        this.$message.warning('请勾选您要批量处理的数据！')
        return
      } 
      let tempArr = []
      this.multipleSelection.map(item =>{
        tempArr.push(item.id)
      })
      this.batchLoading = true
      this.axios.post('pass/baseManagement/v1/limsstdtestitems/syncTestItem', tempArr, {individualType: 'json'}).then(res => {
        if (res.succeed) {
          this.$message.success(res.message);
          this.refresh()
        } else {
          this.$message.error(res.message)
        }
        this.batchLoading = false
      }).catch(e => {
        this.batchLoading = false
        this.$message.error(e.message)
      })
    },
    //复制
    copyData(){
      if (this.multipleSelection.length != 1) {
        this.$message.warning('请勾选您要复制的一条数据！')
        return
      }
      this.copyLoading = true
      this.axios.post('pass/baseManagement/v1/limsstdtestitems/copyLimsStdTestItem?id='+this.multipleSelection[0].id, {individualType: 'json'}).then(res => {
        if (res.code == 0 || res.code == 200) {
         this.$message.success(res.message);
         this.searchData()
        } else {
         this.$message.error(res.message)
        }
        this.copyLoading = false
      }).catch(e => {
        this.copyLoading = false
        this.$message.error(e.message)
      })
    },
    deleteData () {
       let _this = this;
        if (_this.multipleSelection.length < 1) {
        this.$message.warning('请勾选您要删除的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection.length; j++) {
          if (_this.multipleSelection[j].validFlag === '0') {
          this.$message.warning('请勾选状态为已启用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible = false;
        for (var i = 0; i < _this.multipleSelection.length; i++) {
        _this.multipleSelection[i].updateMan = userName;
        _this.multipleSelection[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestitems/abolish', _this.multipleSelection, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('删除成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    searchData () {
      this.page.pageNum = 1;
      this.getDataList()
       
    },
    searchData2(){
      this.fxpage.pageNum = 1
      this.getList()
    },
    fxaddData () {
      let _this = this;
      if(_this.checkList.length <= 0){
        this.$message.warning('请先添加数据到右边的表格中')
        return
      }
      this.checkList.forEach(item =>{
        item.testItemNo = this.multipleSelection[0].testItemNo
        item.testItemName = this.multipleSelection[0].testItemName
      })
      this.axios.post('pass/baseManagement/v1/limsstdtestitemds/addLimsStdTestItemDList', this.checkList, {individualType: 'json'}).then(res => {
         if (res.succeed) {
          _this.dialogTableVisible = false;
          this.$message.success('添加成功')
          this.getDataList2(this.testItemNo)
         } else {
          this.$message.error(res.message)
         }
         }).catch(e => {
          this.$message.error(e.message)
        })
    },
    checkRow(row){
      this.checkList.push(row)
    },
    removeItem(index){
      this.checkList.splice(index,1)
    },
    reset () {
      let _this = this;
      this.search.itemTypeCode = ''
      _this.search.testItemNo = '';
      _this.search.testItemName = '';
      _this.searchData();
    },
    addData2 () {
      let _this = this;
      if (_this.multipleSelection.length !== 1) {
        this.$message.warning('请选择一条测试项目数据！');
        return
      }
      this.dialogTableVisible = true
    },
    modifyData2 () {
      let _this = this;
       if (_this.multipleSelection2.length !== 1) {
        this.$message.warning('请选择您要修改的数据！');
      } else {
        _this.Params3 = _this.multipleSelection2;
        _this.Params3[0].itemTypeCode = _this.curItemTypeCode;
        _this.showFlag3 = !_this.showFlag3;
      }
    },
    recoverData2 () {
      let _this = this;
        if (_this.multipleSelection2.length < 1) {
        this.$message.warning('请勾选您要启用的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection2.length; j++) {
          if (_this.multipleSelection2[j].validFlag === '1') {
          this.$message.warning('请勾选状态为已停用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible2 = false;
        for (var i = 0; i < _this.multipleSelection2.length; i++) {
        _this.multipleSelection2[i].updateMan = userName;
        _this.multipleSelection2[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestitemds/recover', _this.multipleSelection2, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('启用成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    deleteData2 () {
       let _this = this;
        if (_this.multipleSelection2.length < 1) {
        this.$message.warning('请勾选您要停用的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection2.length; j++) {
          if (_this.multipleSelection2[j].validFlag === '0') {
          this.$message.warning('请勾选状态为已启用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible2 = false;
        for (var i = 0; i < _this.multipleSelection2.length; i++) {
        _this.multipleSelection2[i].updateMan = userName;
        _this.multipleSelection2[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestitemds/abolish', _this.multipleSelection2, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('删除成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    //删除分析项目数据
    deleteDatas () {
      if (this.multipleSelection2.length < 1) {
        this.$message.warning('请勾选您要删除的数据！')
      }
      let tempArr = []
      this.multipleSelection2.map(item =>{
        tempArr.push(item.id)
      })
      this.deleteLoading = true
      this.axios.post('pass/baseManagement/v1/limsstdtestitemds/deleteLimsstdtestitemd', tempArr, {individualType: 'json'}).then(res => {
        if (res.code == 0 || res.code == 200) {
          this.$message.success(res.message);
          this.getDataList2(this.testItemNo);
        } else {
         this.$message.error(res.message)
        }
        this.deleteLoading = false
      }).catch(e => {
        this.deleteLoading = false
        this.$message.error(e.message)
      })
    },
    addData3 () {
      let _this = this;
       if (_this.multipleSelection.length !== 1) {
        this.$message.warning('请选择一条测试项目数据！');
      } else {
      _this.showFlag4 = !_this.showFlag4;
      _this.Params4 = this.multipleSelection;
      _this.Params5 = null;
      }
    },
    modifyData3 () {
      let _this = this;
      if (_this.multipleSelection3.length !== 1) {
        this.$message.warning('请选择您要修改的数据！');
      } else {
      _this.showFlag4 = !_this.showFlag4;
      _this.Params4 = null;
      _this.Params5 = this.multipleSelection3;
      }
    },
    recoverData3 () {
       let _this = this;
        if (_this.multipleSelection3.length < 1) {
        this.$message.warning('请勾选您要启用的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection3.length; j++) {
          if (_this.multipleSelection3[j].validFlag === '1') {
          this.$message.warning('请勾选状态为已停用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible3 = false;
        for (var i = 0; i < _this.multipleSelection3.length; i++) {
        _this.multipleSelection3[i].updateMan = userName;
        _this.multipleSelection3[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestmatchs/recover', _this.multipleSelection3, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('启用成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    deleteData3 () {
        let _this = this;
        if (_this.multipleSelection3.length < 1) {
        this.$message.warning('请勾选您要删除的数据！')
      } else {
        for (var j= 0; j < _this.multipleSelection3.length; j++) {
          if (_this.multipleSelection3[j].validFlag === '0') {
          this.$message.warning('请勾选状态为已启用的数据！')  
          return 
          }
        }
        _this.dialogTableVisible3 = false;
        for (var i = 0; i < _this.multipleSelection3.length; i++) {
        _this.multipleSelection3[i].updateMan = userName;
        _this.multipleSelection3[i].updateNo = userId
        }
        _this.axios.post('pass/baseManagement/v1/limsstdtestmatchs/abolish', _this.multipleSelection3, {individualType: 'json'}).then(res => {
        if (res.succeed) {
         this.$message.success('删除成功');
         _this.refresh()
        } else {
         this.$message.error(res.message)
        }
        }).catch(e => {
         this.$message.error(e.message)
       })
      }
    },
    handleSelectionChange (val) {
      this.multipleSelection = val;
      if (val.length > 0) {
        this.testItemNo = val[val.length-1].testItemNo
        this.curItemTypeCode = val[val.length-1].itemTypeCode;
        this.getDataList2(this.testItemNo);
        this.getDataList3(this.testItemNo);
      }
    },
    pageSizeChange (size) {
      this.page.pageSize = size;
      this.getDataList();
    },
    pageCurrentChange (index) {
      this.page.pageNum = index;
      this.getDataList();
    },
    handleSelectionChange2 (val) {
      this.multipleSelection2 = val;
    },
    pageSizeChange2 (size) {
      this.page2.pageSize = size;
      this.getDataList2(this.testItemNo);
    },
    pageCurrentChange2 (index) {
      this.page2.pageNum = index;
      this.getDataList2(this.testItemNo);
    },
    handleSelectionChange3 (val) {
      this.multipleSelection3 = val;
    },
    pageSizeChange3 (size) {
      this.page3.pageSize = size;
      this.getDataList3(this.testItemNo);
    },
    pageCurrentChange3 (index) {
      this.page3.pageNum = index;
      this.getDataList3(this.testItemNo);
    },
    fxpageSizeChange (size) {
        this.fxpage.pageSize = size;
        this.getList();
      },
    fxpageCurrentChange (index) {
      this.fxpage.pageNum = index;
      this.getList();
    },
    handleCurrentChange (val) {
      this.curItemTypeCode = ''
      if (val){
        this.curItemTypeCode = val.itemTypeCode;
      }
      if (val.testItemNo === null) {
        this.testItemNo = '';
      } else {
        this.testItemNo = val.testItemNo;
      }
      this.getDataList2 (this.testItemNo);
      this.getDataList3 (this.testItemNo);
    },
    addScreen () {
      this.$nextTick(() => {
          let ss = document.createElement('div');
          ss.innerHTML = '筛选';
          ss.style = 'text-align: center;'
          this.$refs.dataTable.$el.getElementsByClassName('el-table__fixed')[0].getElementsByTagName('td')[0].appendChild(ss);
       });
    },
    addScreen2 () {
      this.$nextTick(() => {
          let ss = document.createElement('div');
          ss.innerHTML = '筛选';
          ss.style = 'text-align: center;'
          this.$refs.dataTable2.$el.getElementsByClassName('el-table__fixed')[0].getElementsByTagName('td')[0].appendChild(ss);
       });
    },
    addScreen3 () {
      this.$nextTick(() => {
          let ss = document.createElement('div');
          ss.innerHTML = '筛选';
          ss.style = 'text-align: center;'
          this.$refs.dataTable3.$el.getElementsByClassName('el-table__fixed')[0].getElementsByTagName('td')[0].appendChild(ss);
       });
    },
    getList () {
        this.fxdataLoading = true;
        let obj = {
          object:{
            anlyItemName:this.anlyItemName,
            validFlag:1
          },
          pageIndex:this.fxpage.pageNum,
          pageSize:this.fxpage.pageSize
        }
        this.axios.post('pass/baseManagement/v1/limsstdanlyitems/queryLimsStdAnlyItemPage/',obj,{individualType: 'json'}).then(res => {
          this.fxdataLoading = false;
          this.fxlist = res.data.list;
          this.fxlist.forEach(item =>{
            item.validFlag1 = item.validFlag == 1 ? '有效' : item.validFlag == 0 ? '无效' : ''
            item.isCompute1 = item.isCompute == 1 ? '是' : item.isCompute == 0 ? '否' : ''
            item.isMid1 = item.isMid == 1 ? '是' : item.isMid == 0 ? '否' : ''
            item.isReport1 =  item.isReport == 1 ? '是' : item.isReport == 0 ? '否' : ''
            item.isLogin1 = item.isLogin == 1 ? '是' : item.isLogin == 0 ? '否' : ''
            item.isAlarm1 = item.isAlarm == 1 ? '是' : item.isAlarm == 0 ? '否' : ''
            item.isRare1 = item.isRare == 1 ? '是' : item.isRare == 0 ? '否' : ''
          })
          this.fxpage.totalPage = res.data.total;
        }).catch(e => {
          this.fxdataLoading = false;
        });
      },
    getDataList () {
      this.dataLoading = true;
      let obj = {
        object:{
          validFlag:'',
          testItemName:this.search.testItemName,
          itemTypeCode:this.search.itemTypeCode,
        },
        pageIndex:this.page.pageNum,
        pageSize:this.page.pageSize,
      }
      this.axios.post('pass/baseManagement/v1/limsstdtestitems/queryLimsStdTestItemPage',obj, {individualType: 'json'}).then(res => {
        this.dataLoading = false;
        this.table.list = res.data.list;
        this.table.list.forEach(item =>{
          item.validFlag1 = item.validFlag === '0' ? '无效' : item.validFlag === '1' ? '有效' : ''
          item.isTest1 = item.isTest === '0' ? '否' : item.isTest === '1' ? '是' : ''
          item.isCtrl1 = item.isCtrl === '0' ? '否' : item.isCtrl === '1' ? '是' : ''
          item.isAuto1 = item.isAuto === '0' ? '否' : item.isAuto === '1' ? '是' : ''
          item.isSon1 = item.isSon === '0' ? '否' : item.isSon === '1' ? '是' : ''
          item.isSyn1 = item.isSyn === '0' ? '否' : item.isSyn === '1' ? '是' : ''
          item.isMsg1 = item.isMsg === '0' ? '否' : item.isMsg === '1' ? '是' : ''
          item.isIndex1 = item.isIndex === '0' ? '否' : item.isIndex === '1' ? '是' : ''
          item.isRefer1 = item.isRefer === '0' ? '否' : item.isRefer === '1' ? '是' : ''
        })
        this.page.totalPage = res.data.total;
      }).catch(e => {
        this.dataLoading = false;
      });
    },
    getDataList2 (testItemNo) {
      this.dataLoading2 = true;
      if (testItemNo === null || testItemNo === '') {
        this.table.list2 = [];
        this.dataLoading2 = false;
        return
      }
      let obj ={
        object:{
          testItemNo: testItemNo
        },
        pageIndex:this.page2.pageNum,
        pageSize:this.page2.pageSize
      }
      this.axios.post('pass/baseManagement/v1/limsstdtestitemds/queryLimsStdTestItemDPage',obj, {individualType: 'json'}).then(res => {
        if (res.code == 0 || res.code == 200) {
          this.table.list2 = res.data.list;
          this.page2.totalPage = res.data.total;
          this.table.list2.forEach(item =>{
            item.validFlag1 = item.validFlag == 0 ? '无效' : item.validFlag == 1 ? '有效' : ''
            item.isCompute1 = item.isCompute == 0 ? '否' : item.isCompute == 1 ? '是' : ''
            item.isMid1 = item.isMid == 0 ? '否' : item.isCompute == 1 ? '是' : ''
            item.isReport1 = item.isReport == 0 ? '否' : item.isReport == 1 ? '是' : ''
            item.isLogin1 = item.isLogin == 0 ? '否' : item.isLogin == 1 ? '是' : ''
            item.isAlarm1 = item.isAlarm == 0 ? '否' : item.isAlarm == 1 ? '是' : ''
            item.isRare1 = item.isRare == 0 ? '否' : item.isRare == 1 ? '是' : ''
          })
        }else{
          this.$message.error(res.message)
        }
        this.dataLoading2= false;
      }).catch(e => {
        this.dataLoading2 = false;
        this.$message.error(e.message)
      });
    },
    getDataList3 (testItemNo) {
      this.dataLoading3 = true;
      if (testItemNo === null || testItemNo === '') {
        this.table.list3 = [];
        this.dataLoading3 = false;
        return 0
      } else {
        let obj ={
          object:{
            testItemNo: testItemNo
          },
          pageIndex:this.page3.pageNum,
          pageSize:this.page3.pageSize
        }
        this.axios.post('pass/baseManagement/v1/limsstdtestmatchs/queryLimsStdTestMatchPage',obj, {individualType: 'json'}).then(res => {
              this.dataLoading3 = false;
              this.table.list3 = res.data.list;
              for (let i = 0; i < this.table.list3.length; i++) {
              if (this.table.list3[i].validFlag === '0') {
                this.table.list3[i].validFlag1 = '无效'
              } else if (this.table.list3[i].validFlag === '1') {
                this.table.list3[i].validFlag1 = '有效'
              }
              }
              this.page3.totalPage = res.data.total;
            }).catch(e => {
              this.dataLoading3 = false;
            });
      }
    },
    tableRowClassName ({
      row, column, rowIndex, columnIndex}) {
      if (row.validFlag !== '1') {
        return 'error-row';
      }
      return '';
    },
    fxtableRowClassName ({
        row, column, rowIndex, columnIndex
      }) {
        if (columnIndex === 4) {
        if (row.validFlag !== '1') {
          return 'error-row';
        }
        return '';
        }
      },
    tableRowClassName2 ({row, column, rowIndex, columnIndex}) {
      if (row.validFlag !== '1') {
        return 'error-row';
      }
      return '';
    },
    tableRowClassName3 ({row, column, rowIndex, columnIndex}) {
      if (row.validFlag !== '1') {
        return 'error-row';
      }
      return '';
    },
    tableHeaderCellStyle () {
      return 'color: rgb(255,255,255);border-bottom: 1px solid #DCDFE7;'
    }
  }
}
</script>
<style  scoped>
.customWidth_test4{
  width: 1000px !important
}
.clearfix:after{/*伪元素是行内元素 正常浏览器清除浮动方法*/
        content: "";
        display: block;
        height: 0;
        clear:both;
        visibility: hidden;
    }
    .clearfix{
        *zoom: 1;/*ie6清除浮动的方式 *号只有IE6-IE7执行，其他浏览器不执行*/
    }
</style>
