Bootstrap

element el-tree current-node-key无效 setCurrentKey()无效

可以结合 current-node-key属性和this.$refs['你绑定的值'].setCurrentKey()方法及this.$nexTick()同时使用

 <el-tree
          :data="leftList"
          :props="defaultProps"
          v-loading="loadNode"
          node-key="region"
          ref="refTree"
          :highlight-current="true"
          :default-expanded-keys="defaultShowNodes"
          :current-node-key="currentNodekey"
          @node-click="handleNodeClick" >
        </el-tree>
 this.$nextTick(() => {
        this.currentNodekey = res.data[0].region;
        this.$refs.refTree.setCurrentKey(this.currentNodekey);
      });

;