From b0f2130a09dd58d38a0b84e5aa6e36f6dfb25118 Mon Sep 17 00:00:00 2001 From: youki Date: Mon, 23 Aug 2021 19:48:55 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A0JIRA=E4=BB=BB=E5=8A=A1=20chore:=20?= =?UTF-8?q?=E8=A1=A5=E5=85=85=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- typescript/index.ts | 6 ++++++ .../multilayerselecttree.leveltree.ts | 21 +++++++++++++++++++ .../widget/selecttree/selecttree.expander.ts | 13 ++++++++++++ 3 files changed, 40 insertions(+) create mode 100644 typescript/widget/multilayerselecttree/multilayerselecttree.leveltree.ts create mode 100644 typescript/widget/selecttree/selecttree.expander.ts diff --git a/typescript/index.ts b/typescript/index.ts index bc977f9f1..4b17463cc 100644 --- a/typescript/index.ts +++ b/typescript/index.ts @@ -175,6 +175,8 @@ import { MultiSelectTree } from './widget/multiselecttree/multiselecttree'; import { HtmlLabel } from "./base/single/label/html.label"; import { TreeValueChooserPane } from './component/treevaluechooser/pane.treevaluechooser'; import { TdLayout } from './core/wrapper/layout/layout.td'; +import { MultiLayerSelectLevelTree } from './widget/multilayerselecttree/multilayerselecttree.leveltree'; +import { SelectTreeExpander } from './widget/selecttree/selecttree.expander'; export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { @@ -357,6 +359,8 @@ export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { HtmlLabel: typeof HtmlLabel; TreeValueChooserPane: typeof TreeValueChooserPane; TdLayout: typeof TdLayout; + MultiLayerSelectLevelTree: typeof MultiLayerSelectLevelTree; + SelectTreeExpander: typeof SelectTreeExpander; } export default { @@ -539,4 +543,6 @@ export { HtmlLabel, TreeValueChooserPane, TdLayout, + MultiLayerSelectLevelTree, + SelectTreeExpander, }; diff --git a/typescript/widget/multilayerselecttree/multilayerselecttree.leveltree.ts b/typescript/widget/multilayerselecttree/multilayerselecttree.leveltree.ts new file mode 100644 index 000000000..df6d7b731 --- /dev/null +++ b/typescript/widget/multilayerselecttree/multilayerselecttree.leveltree.ts @@ -0,0 +1,21 @@ +import { Pane } from '../../base/pane'; + +export declare class MultiLayerSelectLevelTree extends Pane { + static xtype: string; + + static EVENT_CHANGE: string; + + initTree(nodes: T): void; + + populate(nodes?: T[]): void; + + setValue(v: string[] | string): void; + + getValue(): string[]; + + getAllLeaves(): T[]; + + getNodeById(id: string): T; + + getNodeByValue(id: string): T; +} diff --git a/typescript/widget/selecttree/selecttree.expander.ts b/typescript/widget/selecttree/selecttree.expander.ts new file mode 100644 index 000000000..a50de06e4 --- /dev/null +++ b/typescript/widget/selecttree/selecttree.expander.ts @@ -0,0 +1,13 @@ +import { Widget } from '../../core/widget'; + +export declare class SelectTreeExpander extends Widget { + static xtype: string; + + getAllLeaves(): T[]; + + setValue(v: any): void; + + getValue(): T; + + populate(items: T[]): void; +}