From c193dd7f076fed13a8d9bc24ac8744087748a949 Mon Sep 17 00:00:00 2001 From: Renzo Date: Thu, 29 Feb 2024 15:18:57 +0800 Subject: [PATCH 1/2] =?UTF-8?q?JSY-38096=20fix:=20TreeValueChooserPane?= =?UTF-8?q?=E4=B8=ADitem=E6=94=AF=E6=8C=81=E6=98=BE=E7=A4=BA=E5=9B=BE?= =?UTF-8?q?=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../component/treevaluechooser/abstract.treevaluechooser.js | 3 +++ .../src/component/treevaluechooser/pane.treevaluechooser.js | 2 ++ packages/fineui/src/widget/multiselecttree/multiselecttree.js | 1 + .../fineui/src/widget/multiselecttree/multiselecttree.popup.js | 1 + 4 files changed, 7 insertions(+) diff --git a/packages/fineui/src/component/treevaluechooser/abstract.treevaluechooser.js b/packages/fineui/src/component/treevaluechooser/abstract.treevaluechooser.js index 651ce58e1..cc582a3eb 100644 --- a/packages/fineui/src/component/treevaluechooser/abstract.treevaluechooser.js +++ b/packages/fineui/src/component/treevaluechooser/abstract.treevaluechooser.js @@ -169,6 +169,7 @@ export class AbstractTreeValueChooser extends Widget { value: node.value, open: true, disabled: node.disabled, + iconCls: node.iconCls, }); } } @@ -531,6 +532,7 @@ export class AbstractTreeValueChooser extends Widget { halfCheck: half, flag, disabled: node.disabled, + iconCls: node.iconCls, }); } @@ -702,6 +704,7 @@ export class AbstractTreeValueChooser extends Widget { disabled: nodes[i].disabled, title: nodes[i].title || nodes[i].text, warningTitle: nodes[i].warningTitle, + iconCls: nodes[i].iconCls, }); if (openState) { getResult(parentValues.concat([nodes[i].value]), { checked: state[0], half: state[1] }); diff --git a/packages/fineui/src/component/treevaluechooser/pane.treevaluechooser.js b/packages/fineui/src/component/treevaluechooser/pane.treevaluechooser.js index ff5aad90f..1ecd52f6c 100644 --- a/packages/fineui/src/component/treevaluechooser/pane.treevaluechooser.js +++ b/packages/fineui/src/component/treevaluechooser/pane.treevaluechooser.js @@ -15,6 +15,7 @@ export class TreeValueChooserPane extends AbstractTreeValueChooser { items: null, itemsCreator: emptyFn, showLine: true, + showIcon: false, //searcherPaneAutoShrink和searcherPaneIsSelectedAny同时为false时,返回值和非搜索状态下的树逻辑一致 searcherPaneAutoShrink: true,//其搜索树是否会判别子结点全选则取父结点的值 searcherPaneIsSelectedAny: true, //其搜索树是否返回所有被checked的结点(包括被checked的结点的子结点) @@ -28,6 +29,7 @@ export class TreeValueChooserPane extends AbstractTreeValueChooser { type: o.hideSearch ? MultiSelectTreePopup.xtype : MultiSelectTree.xtype, element: this, showLine: o.showLine, + showIcon: o.showIcon, searcherPaneIsSelectedAny: o.hideSearch || o.searcherPaneIsSelectedAny, itemsCreator: (options, callback) => { options.searcherPaneAutoShrink = o.hideSearch || o.searcherPaneAutoShrink; diff --git a/packages/fineui/src/widget/multiselecttree/multiselecttree.js b/packages/fineui/src/widget/multiselecttree/multiselecttree.js index 1047a9601..e14984fca 100644 --- a/packages/fineui/src/widget/multiselecttree/multiselecttree.js +++ b/packages/fineui/src/widget/multiselecttree/multiselecttree.js @@ -30,6 +30,7 @@ export class MultiSelectTree extends Single { type: MultiSelectTreePopup.xtype, itemsCreator: o.itemsCreator, showLine: o.showLine, + showIcon: o.showIcon, }); this.adapter.on(MultiSelectTreePopup.EVENT_CHANGE, () => { if (self.searcher.isSearching()) { diff --git a/packages/fineui/src/widget/multiselecttree/multiselecttree.popup.js b/packages/fineui/src/widget/multiselecttree/multiselecttree.popup.js index 3782d209b..1c45ceb3b 100644 --- a/packages/fineui/src/widget/multiselecttree/multiselecttree.popup.js +++ b/packages/fineui/src/widget/multiselecttree/multiselecttree.popup.js @@ -22,6 +22,7 @@ export class MultiSelectTreePopup extends Widget { this.popup = createWidget({ type: AsyncTree.xtype, showLine: o.showLine, + showIcon: o.showIcon, element: this, itemsCreator: o.itemsCreator, }); From 4af5234695fd1df91a72236d851e2164d1b96c61 Mon Sep 17 00:00:00 2001 From: Renzo Date: Thu, 29 Feb 2024 15:25:46 +0800 Subject: [PATCH 2/2] =?UTF-8?q?JSY-38096=20fix:=20TreeValueChooserPane?= =?UTF-8?q?=E7=9A=84=E6=90=9C=E7=B4=A2=E4=B8=ADitem=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/fineui/src/widget/multiselecttree/multiselecttree.js | 1 + .../src/widget/multitree/trigger/multi.tree.search.pane.js | 1 + 2 files changed, 2 insertions(+) diff --git a/packages/fineui/src/widget/multiselecttree/multiselecttree.js b/packages/fineui/src/widget/multiselecttree/multiselecttree.js index e14984fca..779e86d7a 100644 --- a/packages/fineui/src/widget/multiselecttree/multiselecttree.js +++ b/packages/fineui/src/widget/multiselecttree/multiselecttree.js @@ -46,6 +46,7 @@ export class MultiSelectTree extends Single { this.searcherPane = createWidget({ type: MultiTreeSearchPane.xtype, cls: "bi-border-left bi-border-right bi-border-bottom", + showIcon: o.showIcon, isSelectedAny: o.searcherPaneIsSelectedAny, keywordGetter() { return self.searcher.getKeyword(); diff --git a/packages/fineui/src/widget/multitree/trigger/multi.tree.search.pane.js b/packages/fineui/src/widget/multitree/trigger/multi.tree.search.pane.js index 01bb92499..d947b8d82 100644 --- a/packages/fineui/src/widget/multitree/trigger/multi.tree.search.pane.js +++ b/packages/fineui/src/widget/multitree/trigger/multi.tree.search.pane.js @@ -31,6 +31,7 @@ export class MultiTreeSearchPane extends Pane { opts.itemsCreator(op, callback); }, value: opts.value, + showIcon: opts.showIcon, listeners: [ { eventName: Controller.EVENT_CHANGE,