From 4e7d7f8fbc128718d6251bdd7dbf41d0be0ed0d5 Mon Sep 17 00:00:00 2001 From: likunming Date: Wed, 26 Jun 2024 18:28:57 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=A8=E6=A0=BC=E4=BC=98=E5=8C=96=E6=8F=90?= =?UTF-8?q?=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- io.sc.platform.core.frontend/package.json | 2 +- .../src/platform/components/grid/WGrid.vue | 20 ++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/io.sc.platform.core.frontend/package.json b/io.sc.platform.core.frontend/package.json index 11a407d5..79237dc2 100644 --- a/io.sc.platform.core.frontend/package.json +++ b/io.sc.platform.core.frontend/package.json @@ -1,6 +1,6 @@ { "name": "platform-core", - "version": "8.1.238", + "version": "8.1.239", "description": "前端核心包,用于快速构建前端的脚手架", "//main": "库的主文件", "main": "dist/platform-core.js", diff --git a/io.sc.platform.core.frontend/src/platform/components/grid/WGrid.vue b/io.sc.platform.core.frontend/src/platform/components/grid/WGrid.vue index 0b70b0ab..b204d9c2 100644 --- a/io.sc.platform.core.frontend/src/platform/components/grid/WGrid.vue +++ b/io.sc.platform.core.frontend/src/platform/components/grid/WGrid.vue @@ -1748,15 +1748,17 @@ const getLocalData = () => { }; // 替换全部行 const setLocalData = (rows: any) => { - if (props.tree && props.treeRelationship === 'parent') { - const treeRows = TreeBuilder.build(rows, props.foreignKey, props.primaryKey); - table.rows = treeRows; - } else { - table.rows = rows; - } - setRowDataExtraProperty(table.rows); - state.pagination.rowsNumber = table.rows.length; - stickyHeaderColumn(); + setTimeout(() => { + if (props.tree && props.treeRelationship === 'parent') { + const treeRows = TreeBuilder.build(rows, props.foreignKey, props.primaryKey); + table.rows = treeRows; + } else { + table.rows = rows; + } + setRowDataExtraProperty(table.rows); + state.pagination.rowsNumber = table.rows.length; + stickyHeaderColumn(); + }, 100); }; const replaceRowHandler = (arr, row) => {