From 12bf2514c17843aab17c9e3fa5ce8933cfefd7f6 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期二, 26 十一月 2024 00:56:47 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 src/components/VisibilityToolbar/index.vue |   18 +++++++++++++++++-
 1 files changed, 17 insertions(+), 1 deletions(-)

diff --git a/src/components/VisibilityToolbar/index.vue b/src/components/VisibilityToolbar/index.vue
index 2773bb6..d58270f 100644
--- a/src/components/VisibilityToolbar/index.vue
+++ b/src/components/VisibilityToolbar/index.vue
@@ -68,6 +68,7 @@
       table: false,
       currentPage: 1,
       columnRef: null,
+      cpList: []
     };
   },
   props: {
@@ -123,7 +124,22 @@
       this.currentPage = page;
     },
     sortChange(row, val) {
-      this.$emit('update:sort', { key: row.key, serialNumber: val });
+      // // 鍒涘缓涓�涓柊鐨刢olumns鏁扮粍锛屼互閬垮厤鐩存帴淇敼鍘熷鏁扮粍
+      // this.cpList = this.columns.map(item => ({ ...item })); // 浣跨敤瑙f瀯鏉ュ垱寤哄璞$殑娴呮嫹璐�
+      //
+      // // 鏇存柊鎸囧畾椤圭殑serialNumber
+      // this.cpList.forEach(item => {
+      //   if (item.key ===  row.key) {
+      //     item.serialNumber =  row.serialNumber;
+      //   }
+      // });
+      //
+      // // 鏍规嵁serialNumber瀵筺ewColumns杩涜鎺掑簭
+      // this.cpList = this.cpList.sort((a, b) => a.serialNumber - b.serialNumber);
+      //
+      // // 瑙﹀彂浜嬩欢閫氱煡鐖剁粍浠禼olumns宸叉洿鏂帮紙濡傛灉鐖剁粍浠堕渶瑕佺煡閬撹繖涓彉鍖栵級
+      // this.$emit('update:sort', this.cpList);
+      this.$emit('update:sort', row);
     },
     resetSort() {
       this.$emit('update:resetSort');

--
Gitblit v1.8.0