jiangping
2025-05-13 09a49f7cd53acba5261802daf491cf01a10f8d9b
admin/src/views/business/internalMember.vue
@@ -18,6 +18,12 @@
            <el-option label="有" value="1"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="" prop="authStatus">
          <el-select v-model="searchForm.authStatus" @keypress.enter.native="search" clearable placeholder="是否授权">
            <el-option label="否" value="0"></el-option>
            <el-option label="是" value="1"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="" prop="canVisit">
          <el-select v-model="searchForm.canVisit" clearable @keypress.enter.native="search" placeholder="可拜访">
            <el-option label="是" value="1"></el-option>
@@ -36,6 +42,9 @@
            <el-option label="同步成功" value="1"></el-option>
            <el-option label="同步失败" value="2"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="" prop="idcardNo">
          <el-input v-model="searchForm.idcardNo" placeholder="身份证号" @keypress.enter.native="search"></el-input>
        </el-form-item>
        <section>
          <el-button type="primary" @click="search">搜索</el-button>
@@ -59,7 +68,7 @@
        <li><el-button type="primary" v-permissions="['business:member:sync']" :loading="loading"
            @click="synchronous()">同步</el-button></li>
        <li><el-button type="primary"
            @click="$refs.OperaMemberWindow.open('新建员工', null, department, searchForm.companyType)" icon="el-icon-plus"
            @click="add" icon="el-icon-plus"
            v-permissions="['business:member:create']">新建员工</el-button></li>
        <li><el-button type="primary" @click="$refs.OperaMemberImportWindow.open('人员导入', searchForm.companyType)"
            icon="el-icon-plus" v-permissions="['business:member:create']">人员导入</el-button></li>
@@ -72,7 +81,7 @@
            @change="search">是否包含下级组织</el-checkbox>
        </li>
      </ul>
      <el-table :max-height="tableHeight" v-loading="isWorking.search" :data="tableData.list" stripe @selection-change="handleSelectionChange">
      <el-table :height="tableHeightNew" v-loading="isWorking.search" :data="tableData.list" stripe @selection-change="handleSelectionChange">
        <el-table-column type="selection" width="55"></el-table-column>
        <el-table-column fixed="left" prop="name" label="姓名" min-width="80px">
          <template slot-scope="{row}">
@@ -162,21 +171,21 @@
            <div v-else>-</div>
          </template>
        </el-table-column>
        <el-table-column prop="code" label="工号" min-width="100px"></el-table-column>
<!--        <el-table-column prop="code" label="工号" min-width="100px"></el-table-column>
        <el-table-column label="卡片" min-width="80px">
          <template slot-scope="{row}">
            <el-button @click="$refs.cardOpeningRecord.open('开卡记录', row.id)" type="text">{{ row.memberCardCount ||
              '0' }}</el-button>
          </template>
        </el-table-column>
        </el-table-column>-->
        <el-table-column prop="editorName" label="操作人" min-width="100px"></el-table-column>
        <el-table-column prop="editDate" label="最后操作时间" min-width="150px"></el-table-column>
        <el-table-column
          v-if="containPermissions(['business:member:update', 'business:member:delete', 'business:empower:create'])"
          label="操作" min-width="280">
          <template slot-scope="{row}">
            <el-button type="text" icon="el-icon-edit" @click="$refs.OperaMemberWindow.open('编辑员工信息', row, department)"
              v-permissions="['business:empower:update']">编辑</el-button>
            <el-button type="text" icon="el-icon-edit" @click="edit(row)"
              v-permissions="['business:member:update']">编辑</el-button>
            <el-button type="text" icon="el-icon-plus" @click="empower(row.id)"
              v-permissions="['business:empower:create']">重新授权</el-button>
            <el-button type="text" :loading="heading" style="color: red" icon="el-icon-delete"
@@ -233,7 +242,9 @@
        workStatus: '',
        positionId: '',
        companyId: '',
        hasFace: ''
        hasFace: '',
        authStatus: '',
        idcardNo: ''
      },
      loading: false,
      heading: false,
@@ -256,11 +267,19 @@
    this.getPositionList()
  },
  mounted() {
    this.$nextTick(() => {
      this.tableHeight = document.body.scrollHeight - this.$refs.QueryFormRef.offsetHeight - 276
    })
    // this.$nextTick(() => {
    //   this.tableHeight = document.body.scrollHeight - this.$refs.QueryFormRef.offsetHeight - 276
    // })
  },
  methods: {
    edit(row) {
      this.$refs.OperaMemberWindow.treeData = this.companyTree
      this.$refs.OperaMemberWindow.open('编辑员工信息', row, this.department, this.searchForm.companyType)
    },
    add() {
      this.$refs.OperaMemberWindow.treeData = this.companyTree
      this.$refs.OperaMemberWindow.open('新建员工', null, this.department, this.searchForm.companyType)
    },
    startEmpowerBatch() {
      if (this.tableData.selectedRows.length === 0) {
        this.$tip.warning('请至少选择一条数据')
@@ -298,7 +317,7 @@
    },
    // 获取组织树
    getfindCompanyTreePage() {
      fetchList()
      fetchList(1)
        .then(res => {
          if (res && res.length > 0) {
            res[0].fsStatus = 1