<template>
  <div class="common-page-content">
    <div class="common-search-container" ref="contentPanel">
      <el-form
        ref="form"
        :model="searchForm"
        label-width="auto"
        label-position="right "
        :inline="true"
        type="flex"
        justify="left"
      >
        <el-form-item label="供应商名称">
          <el-input
            size="small"
            v-model="searchForm.supplier_name_"
            clearable
            placeholder="请输入供应商名称"
          ></el-input>
        </el-form-item>
        <el-form-item label="状态">
          <el-select
            v-model="searchForm.reviewStatus"
            size="small"
            clearable
            style="width: 100%"
            placeholder="状态"
          >
            <el-option
              v-for="item in statusList"
              :key="item.value"
              :label="item.label"
              :value="item.value"
            >
            </el-option>
          </el-select>
        </el-form-item>
      </el-form>
      <div class="container-btn">
        <el-button
          size="small"
          icon="el-icon-search"
          type="danger"
          class="btn btn-plus"
          @click="handleSearch"
        >
          搜索
        </el-button>
        <el-button
          size="small"
          icon="el-icon-refresh-right"
          class="btn btn-plus"
          @click="clearSearchForm"
        >
          重置
        </el-button>
      </div>
    </div>
    <el-row
      class="common-table-container flex searchPanel"
      :style="SearchPanel"
    >
      <el-col :span="24" class="common-table-wrapper">
        <div class="common-btn-group">
          <el-button
            size="small"
            icon="el-icon-plus"
            type="primary"
            class="btn btn-plus"
            @click="handleAdd"
          >
            新增
          </el-button>
          <el-button
            size="small"
            slot="reference"
            icon="el-icon-delete"
            type="danger"
            class="btn btn-delete"
            @click="handleDelete"
          >
            {{ this.$t('common.delete') }}
          </el-button>
          <el-button
            size="small"
            icon="el-icon-thumb"
            :loading="rejectDialog"
            type="primary"
            v-if="searchForm.reviewStatus == 0"
            class="btn btn-plus"
            @click="handleSend"
          >
            发送至企业
          </el-button>
        </div>
        <!-- LJ：表格高度自适应需配合样式  btn-pagenation 有按钮有分页  btngroup只有按钮  pagenation只有分页 -->
        <div class="common-table-content btn-pagenation">
          <el-table
            :border="true"
            stripe
            fit
            size="mini"
            v-loading="tableLoading"
            ref="multipleSelection"
            :data="tableData"
            @selection-change="handleSelectionChange"
          >
            <el-table-column type="selection" min-width="50px" align="center">
            </el-table-column>
            <el-table-column
              prop="enterpriseCode"
              show-overflow-tooltip
              min-width="110px"
              align="center"
              label="企业编号"
              resizable
            >
            </el-table-column>
            <el-table-column
              prop="enterpriseName"
              show-overflow-tooltip
              min-width="130px"
              align="center"
              label="企业名称"
              resizable
            >
            </el-table-column>
            <el-table-column
              prop="supplierCode"
              min-width="110px"
              label="供应商编号"
              align="center"
              resizable
            >
            </el-table-column>
            <el-table-column
              prop="supplierName"
              min-width="130px"
              label="供应商名称"
              align="center"
              show-overflow-tooltip
              resizable
            >
            </el-table-column>
            <el-table-column
              prop="categoryName"
              min-width="100px"
              label="供应商分类"
              align="center"
              resizable
            >
            </el-table-column>
            <!-- <el-table-column
              prop="level"
              min-width="100px"
              label="供应商分级"
              align="center"
              resizable
            >
              <template v-slot="{row}">
                {{ getDictName('gysfj', row.level) }}
              </template>
            </el-table-column> -->
            <el-table-column
              prop="level"
              min-width="100px"
              label="审核状态"
              align="center"
              resizable
            >
              <template slot-scope="scope">
                <el-tag type="info" v-if="scope.row.reviewStatus == 0"
                  >未审核</el-tag
                >
                <el-tag type="waring" v-if="scope.row.reviewStatus == 1"
                  >审核中</el-tag
                >
                <el-tag type="success" v-if="scope.row.reviewStatus == 2"
                  >已审核</el-tag
                >
                <el-tag type="danger" v-if="scope.row.reviewStatus == 3"
                  >驳回</el-tag
                >
              </template>
            </el-table-column>

            <el-table-column min-width="150px" align="center" label="操作">
              <template slot-scope="scope">
                <el-button
                  @click="handleOpen(scope.row)"
                  icon="el-icon-upload2"
                  size="small"
                  v-if="
                    scope.row.reviewStatus == 0 &&
                    scope.row.createOrgId != currentUser.org[0].orgId
                  "
                  type="primary"
                  >资质上传</el-button
                >
                <el-button
                  @click="handleEdit(scope.row)"
                  icon="el-icon-thumb"
                  size="small"
                  v-if="
                    scope.row.reviewStatus == 0 &&
                    scope.row.createOrgId == currentUser.org[0].orgId
                  "
                  type="primary"
                  >编辑</el-button
                >
                <el-button
                  @click="handleOpen(scope.row)"
                  icon="el-icon-upload2"
                  size="small"
                  v-if="scope.row.reviewStatus == 3"
                  type="primary"
                  >再次上传</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </div>
        <div class="common-pagenation">
          <el-pagination
            ref="paginationPanel"
            background
            @size-change="handleSizeChange"
            @current-change="handleCurrentChange"
            :current-page="pageResult.page"
            :page-sizes="[20, 30, 40, 50]"
            :page-size="pageResult.pageSize"
            layout="total, sizes, prev, pager, next, jumper"
            :total="pageResult.total"
          >
          </el-pagination>
        </div>
      </el-col>
    </el-row>
    <!-- 资质附件上传 -->
    <el-dialog
      title="资质文件上传"
      :visible.sync="dialogVisible"
      width="80%"
      :close-on-click-modal="false"
      :before-close="cancelConfirm"
    >
      <el-form ref="formInfo" label-width="auto" label-position="right">
        <div class="rows">
          <div class="rows-left">
            <div class="rows-hr"></div>
          </div>
          <div class="rows-title">
            <div class="text-overflow">资质信息</div>
          </div>
        </div>

        <el-form
          ref="form"
          v-for="(item, index) in parameter.qualificationLabelList"
          :key="index"
          label-width="80px"
        >
          <el-form-item :label="item.qualificationCategoryName">
            <div style="text-align: left">
              <el-button
                type="primary"
                size="mini"
                icon="el-icon-plus"
                @click="addTable(item)"
                style="margin-left: 10px"
                >添加</el-button
              >
            </div>
          </el-form-item>
          <el-table
            class="down"
            :data="item.dataList"
            border
            stripe
            style="width: 100%; margin-top: 20px"
          >
            <el-table-column prop="qualificationCode" label="资质编码">
              <template slot-scope="scope">
                <el-input
                  v-model="scope.row.qualificationCode"
                  placeholder="输入或选择资质编码"
                  clearable
                  @focus="openQualification(scope.row)"
                  prefix-icon="el-icon-search"
                >
                </el-input>
              </template>
            </el-table-column>
            <el-table-column prop="qualificationName" label="资质名称">
              <template slot-scope="scope">
                <el-input
                  v-model="scope.row.qualificationName"
                  placeholder="请输入资质名称"
                >
                </el-input>
              </template>
            </el-table-column>
            <el-table-column
              prop="qualificationAcquisitionDate"
              label="取得日期"
            >
              <template slot-scope="scope">
                <el-date-picker
                  v-model="scope.row.qualificationAcquisitionDate"
                  type="date"
                  placeholder="请选择取得日期"
                  style="width: 100%"
                  clearable
                  value-format="yyyy-MM-dd"
                ></el-date-picker>
              </template>
            </el-table-column>
            <el-table-column prop="expiryDate" label="到期日期">
              <template slot-scope="scope">
                <el-select
                  style="width: 100%"
                  clearable
                  v-model="scope.row.expiryDate"
                  placeholder="选择有效截止期"
                >
                  <el-option
                    v-for="item in options"
                    :key="item.value"
                    :label="item.name"
                    :value="item.name"
                  >
                  </el-option>
                  <el-option style="height: 100%">
                    <template>
                      <el-date-picker
                        value-format="yyyy-MM-dd"
                        v-model="scope.row.expiryDate"
                        style="width: 100%; margin-top: 10px"
                        clearable
                        placeholder="请选择有效期至"
                      ></el-date-picker>
                    </template>
                  </el-option>
                </el-select>
              </template>
            </el-table-column>
            <el-table-column
              prop="name"
              show-overflow-tooltip
              label="文件名称"
            ></el-table-column>
            <el-table-column
              prop="createTime"
              show-overflow-tooltip
              label="上传时间"
            >
            </el-table-column>
            <el-table-column width="100px" label="附件">
              <template slot-scope="scope">
                <el-button
                  size="small"
                  type="text"
                  v-if="scope.row.accessoryList.length != 0"
                >
                  <a
                    target="_blank"
                    @click="downloadFile(scope.row.name, scope.row.url)"
                    >下载</a
                  >
                </el-button>
                <el-button
                  size="small"
                  v-if="scope.row.accessoryList.length != 0"
                  type="text"
                  @click="deleteHandle(scope.row, scope.$index)"
                  >删除</el-button
                >
                <el-upload
                  class="upload-demo"
                  ref="upload"
                  :headers="headers"
                  v-else
                  :action="action"
                  :file-list="scope.row.accessoryList"
                  :multiple="true"
                  accept=".png,.jpg,.jpeg,.xlsx,.xls,.pdf,.docx,.doc,.zip,.rar"
                  :show-file-list="false"
                  :before-upload="
                    (res) => {
                      return beforeUpload(res, scope.row, scope.$index)
                    }
                  "
                  :on-success="
                    (res) => {
                      return handleSuccess(res, scope.row, scope.$index)
                    }
                  "
                >
                  <el-button slot="trigger" size="small" type="primary"
                    >上传文件</el-button
                  >
                </el-upload>
              </template>
            </el-table-column>
            <el-table-column width="120px" label="操作">
              <template slot-scope="scope">
                <el-button
                  size="mini"
                  type="danger"
                  circle
                  class="closeBtn"
                  icon="el-icon-close"
                  @click="delTable(item, scope.$index)"
                />
              </template>
            </el-table-column>
          </el-table>
        </el-form>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button size="small" @click="cancelConfirm()">取 消</el-button>
        <el-button
          size="small"
          type="primary"
          @click="submitImport"
          plain
          :loading="loadingBtn"
          element-loading-text="拼命导入中"
          v-loading.fullscreen.lock="fullscreenLoading"
          >确 定</el-button
        >
      </div>
    </el-dialog>
    <qualificationDialog
      ref="qualification"
      :useOrgList="qualificationList"
      @load="getLoad"
    ></qualificationDialog>
    <!-- 准入流程 -->
    <flowDialog ref="flowDialog" @reload="loadData"></flowDialog>
  </div>
</template>

<script>
import supplierManger from '@/api/supplierManger.js'
import pagination from '@/components/pagination'
import {TableMixin} from '@/mixins/tableMixin'
import routerManagement from '@/api/BasicDataManagement/routerManagement.js'
import req from '@/request.js'
import utils from '@/utils.js'
import {mapState} from 'vuex'
import qualificationDialog from '@/components/dialog/qualificationDialog.vue'
import flowDialog from './module/flowDialog.vue'

export default {
  name: 'DemandEntry',
  components: {
    pagination,
    qualificationDialog,
    flowDialog,
  },
  mixins: [TableMixin],
  data() {
    return {
      currentPage: 1,
      tableMaxHeight: 400,
      loading: false,
      tableLoading: false,
      visible: false,
      tableData: [],
      index: '',
      loadingBtn: false,
      fullscreenLoading: false,
      multipleSelection: [],
      qualificationList: [],
      dialogVisible: false,
      form: {},
      authList: [],
      options: [{id: 1, name: '永久', value: 1}],
      statusList: [
        {label: '未审核', value: 0},
        {label: '审核中', value: 1},
        {label: '已审核', value: 2},
        {label: '驳回', value: 3},
      ],
      parameter: {
        qualificationLabelList: [],
      },
      rejectDialog: false,
      params: {
        pageBean: {
          page: 1,
          pageSize: 20,
          total: 0,
        },
        sorter: [
          {
            direction: 'DESC',
            property: 'createTime',
          },
        ],
      },
      queryParam: {
        pageBean: {
          page: 1,
          pageSize: 20,
          total: 0,
        },
      },
      searchForm: {
        type: 1,
        reviewStatus: 0,
      }, // 顶部搜索对象
      deleteIds: '', // 是否选中列表解锁删除按钮
      activeCollapse1: ['1', '2'],
      fileList: [], // 文件上传
      edit: false, // 是否是修改功能
      currentDataDel: [], // 删除时排查是否有在审核的数据
      auditing: false,
      currentUser: {},
    }
  },
  created() {
    this.currentUser = JSON.parse(sessionStorage.getItem('currentUserDetail'))
    if (this.$route.params.pageBean) {
      this.params = this.$route.params.pageBean
      this.pageResult = this.$route.params.pageBean.pageBean
    }
    this.handleSearch()
  },
  methods: {
    //获取数据
    loadData() {
      this.tableLoading = true
      this.$http
        .post(
          '${portal}/supplier/bizSupplierEnterprise/v1/queryBySupplier',
          this.params
        )
        .then((res) => {
          this.tableLoading = false
          this.tableData = res.data.rows
          this.pageResult = {
            page: res.data.page,
            pageSize: res.data.pageSize,
            total: res.data.total,
          }
        })
    },

    // 上传附件成功回调
    handleSuccess(res, row, index) {
      row.accessoryList.push(res.value)
      let data = {...row, ...res.value}
      this.parameter.qualificationLabelList.forEach((item) => {
        item.dataList.forEach((val) => {
          if (val.key == data.key) {
            val['name'] = data.name
            val['createTime'] = data.createTime
            return val
          }
        })
      })
      this.$forceUpdate()
    },
    beforeUpload(file, row, index) {
      if (this.searchForm.reviewStatus != 3) {
        const isLt = file.size / 1024 / 1024 < row.fileSize
        if (!isLt) {
          this.$message.error(`上传的文件大小不能超过${row.fileSize}M!`)
        }
        return isLt
      }
    },
    openQualification(row) {
      this.$refs.qualification.add(row)
    },
    getLoad(data) {
      console.log(data, 'wewqe')
      this.qualificationList = data
      this.$http
        .post('${portal}/bizQualificationLabel/v1/getById?id=' + data[0].id)
        .then((res) => {
          let result = res.data.value
          data.forEach((val) => {
            val.accessoryList = []
            console.log(this.parameter.qualificationLabelList)
            this.parameter.qualificationLabelList.forEach((item) => {
              if (
                item.dataList.length &&
                (val.qualificationTypeCode == item.qualificationCategoryCode ||
                  val.qualificationTypeCode == item.qualificationTypeCode)
              ) {
                item.dataList = data
                if (result.accessoryList && result.accessoryList.length != 0) {
                  item.dataList.forEach((e) => {
                    if (e.id == result.id) {
                      e.accessoryList = result.accessoryList
                      e.name = result.accessoryList[0].name
                      e.url = result.accessoryList[0].url
                    }
                  })
                }
              }
            })
          })
        })
      this.$forceUpdate()
    },
    // 删除
    deleteHandle(row, index) {
      this.$confirm('是否确认删除该附件', '提示', {
        confirmButtonText: '确定',
        cancelButtonText: '取消',
        type: 'warning',
      }).then(() => {
        row.accessoryList.splice(index, 1)
        row.name = ''
        row.fileTime = ''
        row.url = ''
        row.createTime = ''
        row.accessoryList = []
      })
    },
    addTable(item) {
      item.dataList.push({
        qualificationTypeName: item.qualificationCategoryName,
        qualificationTypeCode: item.qualificationCategoryCode,
        qualificationAcquisitionDate: '',
        fileSize: item.fileSize,
        qualificationCode: '',
        expiryDate: '',
        accessoryList: [],
        key: Math.random() + '',
        qualificationForm: 1,
      })
    },
    // 审核
    handleAudit() {
      this.auditing = true
      this.$http
        .post(
          '${portal}/supplier/bizSupplierEnterprise/v1/updateReviewStatus?id=' +
            this.multipleSelection[0].id +
            '&status=2&rejectionReason='
        )
        .then((res) => {
          if (res.data.state) {
            this.$message.success(res.data.message)
          }
          this.handleSearch()
          this.auditing = false
        })
    },
    submitImport() {
      let arr = []
      if (this.form.reviewStatus == 3) {
        this.form.reviewStatus = 0
        this.parameter.qualificationLabelList.forEach((item) => {
          if (item.dataList && item.dataList.length) {
            delete item.dataList
          }
          item.qualificationMemberId = this.form.qualificationMemberId
          item.qualificationMember = this.form.qualificationMember
          arr.push(item)
        })
      } else {
        this.parameter.qualificationLabelList.forEach((item) => {
          item.dataList.forEach((val) => {
            if (val.key) {
              delete val.key
            }
            val.qualificationMemberId = this.form.qualificationMemberId
            val.qualificationMember = this.form.qualificationMember
            arr.push(val)
          })
        })
      }
      console.log(this.form)
      this.form.qualificationLabelList = arr
      this.$http
        .post(
          '${portal}/supplier/bizSupplierEnterprise/v1/uploadAccessory',
          this.form
        )
        .then((res) => {
          console.log(res, 111111111111)
          if (res.data.state) {
            this.loadData()
            this.dialogVisible = false
          }
          this.loadingBtn = false
        })
    },
    handleOpen(row) {
      this.form = row
      if (row.reviewStatus != 3) {
        this.form.qualificationMember = row.supplierName
        this.form.qualificationMemberId = row.supplierId
        this.parameter.qualificationLabelList =
          row.suppliersQualificationList.filter((item, index, self) => {
            return (
              self.findIndex(
                (t) =>
                  JSON.stringify(t.qualificationCategoryCode) ===
                  JSON.stringify(item.qualificationCategoryCode)
              ) === index
            )
          })
        this.parameter.qualificationLabelList.forEach((item) => {
          this.$set(item, 'dataList', [])
          item.qualificationTypeName = item.qualificationCategoryName
        })
      } else {
        this.$http
          .get('${portal}/supplier/bizSupplierEnterprise/v1/getById/' + row.id)
          .then((res) => {
            let data = res.data
            this.parameter.qualificationLabelList = data.qualificationLabelList
            this.parameter.qualificationLabelList.forEach((item) => {
              this.$set(item, 'dataList', [])
              item.qualificationCategoryName = item.qualificationTypeName
            })
            this.parameter.qualificationLabelList.forEach((item) => {
              item.dataList.push(item)
              if (item.accessoryList && item.accessoryList.length != 0) {
                item.accessoryList.forEach((val) => {
                  if (val.sourceId == item.id) {
                    val.qualificationCode = item.qualificationCode
                    val.qualificationName = item.qualificationName
                    val.qualificationAcquisitionDate =
                      item.qualificationAcquisitionDate
                    val.expiryDate = item.expiryDate
                  }
                })
              }
            })
          })
      }

      this.dialogVisible = true
    },
    handleSelectionChange(val) {
      this.multipleSelection = val
      if (this.multipleSelection.length > 1) {
        this.$refs.multipleSelection.toggleRowSelection(
          this.multipleSelection[0],
          false
        )
      }
    },
    //列表删除行
    delTable(row, index) {
      if (this.searchForm.reviewStatus != 3) {
        this.parameter.qualificationLabelList.forEach((item, i) => {
          if (
            index == i &&
            item.qualificationCategoryCode == row.qualificationTypeCode
          ) {
            item.dataList.splice(index, 1)
          }
        })
      } else {
        this.parameter.qualificationLabelList.forEach((item) => {
          item.dataList.forEach((val) => {
            row.dataList.forEach((e, i) => {
              if (val.id) {
                if (val.id == e.id) {
                  row.dataList.splice(i, 1)
                }
              } else {
                row.dataList.splice(i, 1)
              }
            })
          })
        })
      }
      this.$forceUpdate()
    },
    cancelConfirm() {
      this.fileList = []
      this.dialogVisible = false
    },
    //添加
    handleAdd() {
      this.$router.push({
        path: '/onboardingAddDialog',
      })
    },
    // 驳回
    handleReject(row) {
      this.form = row
    },
    // 编辑
    handleEdit(rows) {
      this.$router.push({
        path: `/onboardingAddDialog/${rows.id}`,
        query: {pageBean: this.params},
      })
    },
    // 详情
    handleDetail(rows) {
      this.$router.push({
        path: `/onboardingDetail/${rows.id}`,
      })
    },
    //下载按钮回调
    downloadFile(name, url) {
      var a = document.createElement('a')
      var event = new MouseEvent('click')
      a.download = name
      a.target = '_blank'
      a.href = url
      a.dispatchEvent(event)
    },
    save() {
      this.parameter.qualificationLabelList.forEach((item, index) => {
        if (index == this.index) {
          this.multipleSelection.forEach((val) => {
            item.qualificationTypeName = val.name
            item.qualificationTypeCode = val.code
          })
        }
      })
      this.visible = false
    },
    // 删除
    handleDelete() {
      let selection = this.$refs.multipleSelection.selection
      if (selection.length === 0) {
        this.$alert('请选择要删除的数据！', this.$t('common.tips'), {
          confirmButtonText: this.$t('common.confirm'),
          type: 'warning',
        })
      } else {
        let ids = []
        selection.forEach((item) => {
          let str = 'ids=' + item.id
          ids.push(str)
        })
        ids = ids.join('&')
        this.$confirm(this.$t('common.sureDelete'), this.$t('common.tips'), {
          confirmButtonText: this.$t('common.confirm'),
          cancelButtonText: this.$t('common.cancel'),
          type: 'warning',
        }).then(() => {
          this.tableLoading = true
          supplierManger.delManage(ids).then((res) => {
            this.tableLoading = false
            if (res.data.state) {
              this.$message.success('删除成功！')
              this.handleSearch()
            } else {
              this.$message.error('删除失败！')
            }
          })
        })
      }
    },
    //重置
    clearSearchForm() {
      this.searchForm = {type: 1, reviewStatus: 0}
      this.handleSearch()
    },
    // 顶部搜索
    handleSearch() {
      let obj = this.searchForm
      let querys = []
      for (let i in obj) {
        querys.push({
          group: 'main',
          operation:
            i == 'supplier_name_' || i == 'reviewStatus' ? 'LIKE' : 'EQUAL',
          parentGroup: '',
          property: i,
          relation: 'AND',
          value: obj[i],
        })
      }
      this.params.querys = querys
      this.loadData(this.params)
    },
    handleCurrentChange(page) {
      this.params.pageBean = {...this.params.pageBean, page}
      this.loadData(this.params)
    },
    handleSizeChange(pageSize) {
      this.params.pageBean = {...this.params.pageBean, pageSize}
      this.loadData(this.params)
    },
    selectChange(val) {
      this.multipleSelection = val
      if (this.multipleSelection.length > 1) {
        this.$refs.multipleSelection.toggleRowSelection(
          this.multipleSelection[0],
          false
        )
      }
    },
    dialogBeforeClose() {
      this.visible = false
      this.dialogVisible = false
    },
    handleSend() {
      if (this.multipleSelection.length == 0) {
        this.$message.warning('请选择数据!')
        return
      }
      if (this.multipleSelection.length > 1) {
        this.$message.warning('请选择一条数据!')
        return
      }
      this.rejectDialog = true
      this.$confirm('是否发送至企业', '提示', {
        confirmButtonText: '确 定',
        cancelButtonText: '取 消',
        type: 'warning',
      }).then(() => {
        this.$http
          .post(
            '${portal}/supplier/bizSupplierEnterprise/v1/modifyReviewStatusById?id=' +
              this.multipleSelection[0].id +
              '&status=1'
          )
          .then((res) => {
            this.rejectDialog = false
            if (res.data.state) {
              this.$message.success(res.data.message)
              this.loadData()
            }
          })
      })
    },
  },
  computed: {
    SearchPanel() {
      return {
        '--searchPanel': this.searchPanel + 'px',
      }
    },
    ...mapState({
      headers: (state) => {
        return {Authorization: `Bearer ${state.login.currentUser.token}`}
      },
      action: function () {
        return window.context.portal + '/biz/universal/v1/minioUpload'
      },
    }),
  },
}
</script>

<style lang="scss" scoped>
.cloumn-btn {
  border: 1px solid #2761ff;
  padding: 3px 10px;
  border-radius: 5px;
  &:nth-child(1) {
    margin-right: 5px;
  }
  &:nth-child(2) {
    margin-right: 5px;
  }
  &:nth-child(1):hover {
    background-color: #2761ff;
    color: #fff;
  }
  &:nth-child(2):hover {
    background-color: #2761ff;
    color: #fff;
  }
  /deep/ i,
  span {
    font-size: 16px;
  }
}

/deep/ .el-tree-node__content {
  padding: 5px 0;
}

/deep/ .el-table thead tr th {
  background-color: #eee !important;
  border-right: 1px solid #dfe2e8 !important;
}
/deep/ .el-table {
  border-collapse: collapse !important;
}
.searchBtn {
  width: 100% !important;
  border: 0px;
}
.closeBtn {
  /deep/.el-icon-close {
    font-size: 18px !important;
  }
}
</style>
