[Feature] 对于复选框类型列的需求
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 3.7k
- Forks
- 486
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 16
Description
What problem does this feature solve?
1、对于树形结构的表格,复选框的勾选,父子结构的勾选可分为联动、不联动。使用场景:1)领导向下分配任务,此时需要仅勾选所有的子进行批量分配,不应该将自身的父任务也勾选;2)领导勾选自己的父任务,来进行一些调整或对比,不应将下属的任务也带出;3)其他业务场景
2、对于表头的全选的逻辑。对于不可勾选的列,操作全选或判断全选状态时应该排除掉,不应计算进来,如图所示。使用场景:1)用户需对未完成的任务进行快速选择,应仅选择可勾选的,不应将已完成不可勾选的也选择进去
3、能有一些快捷方法:1)支持一次性获取表格中所有已勾选的条目;2)设置表格多个条目的勾选;3)设置全选或全不选
4、目前column的checked方法中,对于树形结构的子节点,参数args中获取到的row不准确,因此只能通过record去设置默认勾选,是否能支持在checked方法中设置
What does the proposed API look like?
1、可在列上增加参数配置,如:CheckStrictly等,支持配置是否父子联动的勾选;
3、增加方法,如:getSelectedRows-获取表格中已勾选的条目;setSelectedRows-设置表格多个条目的勾选等
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file or test is named. Start by reviewing the checkbox column's checked method and the tree-table selection behavior described in the issue, then compare the proposed CheckStrictly, getSelectedRows, and setSelectedRows APIs with existing selection entry points. Done means the parent-child and header-selection rules, bulk selection methods, and checked callback behavior are specified and tested.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100