import { ProvidersService } from 'fccore2'; import { FcinputComponent } from '../fcinput'; import { NzFormatEmitEvent } from 'ng-zorro-antd'; /** * fc-tree树控件 * 树形控件。 * 文件夹、组织架构、生物分类、国家地区等等,世间万物的大多数结构都是树形结构。使用树控件可以完整展现其中的层级关系,并具有展开收起选择等交互功能。 */ export declare class FctreeComponent extends FcinputComponent { provider: ProvidersService; /** 选中的节点内容ID值 */ fcId: string; fcNodes: any[]; /** 配置 */ fcOption: TreeOptions; fcSelectedKeys: string[]; fcExpandKeys: string[]; fcCheckedKeys: string[]; beforeDrop: any; /** 异步取数 */ _options: { allowDrag: boolean; getChildren: (node: any) => Promise<{}>; }; constructor(provider: ProvidersService); ngOnChanges(param: any): void; /** * 选中的改变 * @param eventName 事件名称 * @param param 事件参数 */ checkChange(eventName: any, param: any): void; /** * 在子节点中获取下级节点 * @param node 当前子节点 */ getChildren(event: any, node: NzFormatEmitEvent): void; /** * * @description 数组转树结构 * @param id id值 * @param list 数据列表 * @param parentValue 上级编码的值 * @param code 编码 * @param name 名称 * @param subtitle 小标题 * @param parent 父级编码字段 * @param childFieldCode 是否有子节点的名称 * @param lastValue 是否作为判断是否是叶子节点 */ private _listtotreeasync; } export interface TreeOptions { /** 元数据id */ fcAppid: string; /** 元数据id */ /** 树结构节点显示内容 */ fcLabel: string; /** 支持#{参数名称}# #{NAME}#:#{CODE}# */ /** 关联父节点字段名称 */ fcParentCode: string; /** 'PARENT', */ /** 当前节点字段名称 */ fcChildCode: string; /** 'CODE', */ /** 叶子节点字段名称 */ fcLeafCode: string; /** 'ISLAST', */ /** 根节点条件 */ fcTopWhere: string; /** "{or:[{parent:{IS:''}},{parent:{eq:''}}]}", */ /** 展开条件 */ fcExpWhere: string; /** "{PARENT:{eq:'#{MENUID}#'}}", */ /** 排序字段 */ fcOrderby: string; /** 模式 */ fcMode: boolean; /** 展开子节点 */ fcOpenChild: boolean; /** 展开子节点 */ fcCheckable?: boolean; /** 是否多选 */ fcMutliple?: boolean; /** 是否显示线 */ fcShowLine: boolean; /** 可否拖拽 */ fcAllowDrag: boolean; /** 叶子节点的值是通过此值进行判断是否是叶子或者是否是末级 */ fcLeafValue?: string; /** 默认异步加载为false */ fcAsync?: boolean; /** 是否重新加载 */ fcRefresh?: boolean; }