From f95e05c88410bfca3ecbda9608be28d35d8471c6 Mon Sep 17 00:00:00 2001 From: YLQZ <34296146+YLQZ@users.noreply.github.com> Date: Tue, 25 Aug 2020 17:24:31 +0800 Subject: [PATCH] =?UTF-8?q?=E7=B4=A7=E6=80=A5=E4=BF=AE=E5=A4=8Dcrud=20tabl?= =?UTF-8?q?e=E6=A0=91=E6=A1=A9=E6=93=8D=E4=BD=9C=E9=99=90=E6=AD=BB?= =?UTF-8?q?=E4=B8=BB=E9=94=AE=E9=97=AE=E9=A2=98=20(#102)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 紧急修复 crud 自定义树桩表格的错误 之前仅支持id的,修复后 支持自定义主键 --- src/components/Crud/crud.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/Crud/crud.js b/src/components/Crud/crud.js index 1d38aa0..8976f77 100644 --- a/src/components/Crud/crud.js +++ b/src/components/Crud/crud.js @@ -511,7 +511,7 @@ function CRUD(options) { return } const lazyTreeNodeMap = table.store.states.lazyTreeNodeMap - const children = lazyTreeNodeMap[row.id] + const children = lazyTreeNodeMap[crud.getDataId(row)] row.children = children children.forEach(ele => { const id = crud.getDataId(ele)