qinxianzhangyao
2024-02-26 63eccc037b6df07de5470635e084c1d2dc1ef3a7
qxtj
1个文件已修改
7 ■■■■ 已修改文件
src/views/system/user/index.vue 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/user/index.vue
@@ -901,7 +901,7 @@
  watch: {
    // 根据名称筛选部门树
    deptName(val) {
      this.$refs.tree.filter(val);
      console.log(val)
    },
    treeId(newVal, oldVal) {
      if (newVal) {
@@ -935,6 +935,7 @@
    /** 查询用户列表 */
    getList() {
      this.loading = true;
      if(this.queryParams.deptId){
      listUser(this.addDateRange(this.queryParams, this.dateRange)).then(
        (response) => {
          response.rows.forEach((item, index) => {
@@ -948,6 +949,8 @@
          this.loading = false;
        }
      );
      }
    },
    /** 查询岗位列表 */
    getPostList() {
@@ -980,8 +983,10 @@
    getDeptTree() {
      deptTreeSelect().then((response) => {
        this.deptOptions = response.data;
        console.log( this.deptOptions)
        this.treeId.push(this.deptOptions[0].id)
        this.queryParams.deptId = this.deptOptions[0].id
        console.log(this.queryParams.deptId)
      });
    },
    // 筛选节点