licp
2024-04-16 56155226f104f98e8085b03a723e6102b60c1f5d
src/components/view/a6-personnel-detail.vue
@@ -112,15 +112,16 @@
         <el-tree :data="list" ref="tree" :props="{ children: 'children', label: 'name' }" node-key="id"
            :filter-node-method="filterNode" @node-click="handleNodeClick" highlight-current @node-expand="nodeOpen"
            @node-collapse="nodeClose" v-loading="treeLoad" :expand-on-click-node="false"
            :default-expanded-keys="expandedKeys">
            :default-expanded-keys="expandedKeys"
        :default-checked-keys="[1]">
            <div class="custom-tree-node" slot-scope="{ node, data }">
               <el-row style="width: 100%;">
                  <el-col :span="21" :class="{sort:node.level>3}">
                     <span><i
                           :class="`node_i ${data.children != undefined&&data.children.length>0 ? 'el-icon-folder-opened' : 'el-icon-tickets'}`"></i>
                        [{{ node.level-1 }}] {{ data.name }}</span>
                         {{ data.name }}</span>
                  </el-col>
                  <el-col :span="2" style="text-align: right;" v-if="delStandardTree">
                  <el-col :span="2" style="text-align: right;" v-if="delStandardTree&&node.level>1">
                     <el-button type="text" size="mini" @click.stop="remove(node, data)">
                        <i class="el-icon-delete"></i>
                     </el-button>
@@ -146,7 +147,7 @@
            </el-col>
         </el-row>
         <el-row class="standard_table" v-loading="tableLoad">
            <ValueTable ref="ValueTable" :url="$api.capacityScope.selectItemParameterList" :componentData="componentData" />
            <ValueTable ref="ValueTable" :url="$api.department.showUserById" :componentData="componentData" />
         </el-row>
      </div>
      <el-dialog title="架构新增" :visible.sync="addDia" width="400px">
@@ -192,6 +193,8 @@
            addStandardProduct: false,
            componentData: {
               entity: {
            name:'',
            departId:'',
                  orderBy: {
                     field: 'id',
                     order: 'asc'
@@ -199,8 +202,8 @@
               },
          init:false,
               isIndex: true,
               showSelect: true,
               select: true,
               showSelect: false,
               select: false,
               do: [],
          isPage: false,
               tagField: {
@@ -226,7 +229,8 @@
        this.$refs.ValueTable.selectList()
         },
         refresh() {
            this.upIndex++
            this.upIndex++;
        this.componentData.entity.departId = this.list[0].id;
        this.refreshTable()
         },
         handleNodeClick(val, node, el) { //树的值
@@ -240,6 +244,8 @@
            }
            this.selectTree = data2.replace(' - ', '')
        this.addOb.fatherId = val.id;
        this.componentData.entity.departId = val.id;
        this.refreshTable()
         },
         getNodeParent(val) {
            if (val.parent != null) {
@@ -274,12 +280,14 @@
               this.list.forEach(a => {
                  a.children.forEach(b => {
                     b.children.forEach(c => {
                        this.expandedKeys.push(c.name)
                        this.expandedKeys.push(c.id)
                     })
                     // this.expandedKeys.push(b.label)
                  })
               })
               this.treeLoad = false
          this.componentData.entity.departId = this.list[0].id;
          this.selectTree = '全部'
          this.refreshTable()
            })
         },
         addStandardTree() {