zhangqing 1 год назад
Родитель
Сommit
e3895da84e

+ 0 - 7
src/layout/components/header-tools.vue

@@ -165,13 +165,6 @@ export default {
           .then(() => {
             userLogout().then((res) => {
               localStorage.removeItem('userId');
-              const prefix = 'Cols'; // 标识后缀
-              Object.keys(localStorage).forEach((key) => {
-                if (key.endsWith(prefix)) {
-                  localStorage.removeItem(key);
-                  // console.log(`已清除缓存: ${key}`);
-                }
-              });
               logout();
             });
           })

+ 15 - 15
src/mixins/tableColumnsMixin.js

@@ -3,34 +3,34 @@ import request from '@/utils/request';
 export default {
   data() {
     return {
-      newColumns: []
+      // newColumns: []
     };
   },
   created() {
     //从服务器获取缓存列表配置
-    this.getTabColumns();
+    // this.getTabColumns();
     // 创建防抖函数并绑定this
-    this.debouncedHandleColumnChange = this.debounce(
-      this.handleColumnChangeImpl,
-      1000
-    );
+    // this.debouncedHandleColumnChange = this.debounce(
+    //   this.handleColumnChangeImpl,
+    //   1000
+    // );
   },
   methods: {
     // 实际的列变更处理逻辑
     handleColumnChangeImpl() {
-      try {
-        const list = this.getStorage(this.cacheKeyUrl + 'Cols');
-        if (list) {
-          this.saveColumns(list);
-        }
-      } catch (error) {
-        console.error('处理列配置出错:', error);
-      }
+      // try {
+      //   const list = this.getStorage(this.cacheKeyUrl + 'Cols');
+      //   if (list) {
+      //     this.saveColumns(list);
+      //   }
+      // } catch (error) {
+      //   console.error('处理列配置出错:', error);
+      // }
     },
 
     // 列表变化回调
     handleColumnChange() {
-      this.debouncedHandleColumnChange();
+      // this.debouncedHandleColumnChange();
     },
 
     // 获取table-column配置

+ 0 - 2
src/views/enterpriseModel/dept/index.vue

@@ -9,7 +9,6 @@
         :datasource="datasource"
         :default-expand-all="false"
         :need-page="false"
-        :page-size="pageSize"
         @columns-change="handleColumnChange"
         :cache-key="cacheKeyUrl"
       >
@@ -144,7 +143,6 @@ export default {
       editData: null,
       // 上级id
       parentId: null,
-      pageSize: this.$store.state.tablePageSize,
       cacheKeyUrl: 'fc7bccc0-enterpriseModel-dept',
       columnsVersion: 1
     };

+ 0 - 2
src/views/enterpriseModel/regionalManage/index.vue

@@ -10,7 +10,6 @@
         :datasource="datasource"
         :default-expand-all="false"
         :need-page="false"
-        :page-size="pageSize"
         @columns-change="handleColumnChange"
         :cache-key="cacheKeyUrl"
       >
@@ -108,7 +107,6 @@ export default {
       // 上级id
       parentId: null,
       dictList: {},
-      pageSize: this.$store.state.tablePageSize,
       cacheKeyUrl: 'fb2f4315-enterpriseModel-organization',
       columnsVersion: 1,
     };

+ 1 - 0
src/views/technology/work/index.vue

@@ -15,6 +15,7 @@
         :selection.sync="selection"
         v-loading="loading"
         row-key="code"
+        :pageSize="this.$store.state.tablePageSize"
       >
         <!-- 表头工具栏 -->
         <template v-slot:toolbar>