Skip to content

使用TreeSelect时碰到的一些友好性问题 #81

@wjsq0705

Description

@wjsq0705
  • I have searched the issues of this repository and believe that this is not a duplicate.

What problem does this feature solve?

1、使用treeData构成树节点时。如果存在children这个属性,但是值为null就会报错。这点在使用时比较尴尬。因为树结构是在后端生成的,后端要把每个树节点的children至少赋值一个空的数组。
2、新功能描述:目前树节点支持了key、value、name等常用属性。但是在使用时很难满足实际需求。如果我给树节点多弄个属性,在change事件或者select事件拿到的参数中,不是组件内置的参数,都会被舍弃。还有,如果能用 param:{key:userId,value:userId,name:userName} 这种方式去指定参数的名称会更友好些。否则树节点属性被写死也件很尴尬的事情。

What does the proposed API look like?

按照以前的API描述就可以了

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions