Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

table 如果设置了expandedRowRender,则默认每行都带展开加号 #41294

Closed
wgod9527 opened this issue Mar 17, 2023 · 4 comments
Closed

Comments

@wgod9527
Copy link

What problem does this feature solve?

那些不需要展开的,前面的 加 号依然存在,特殊的一行, 号不显示

What does the proposed API look like?

rowClassName={this.setRowClassName}
setRowClassName = (record) => {
if(!record.orderCount){
return 'expandSpan'
}
}
.expandSpan{
span.ant-table-row-expand-icon.ant-table-row-collapsed{
position: absolute;
left: -900px;
}
}
这是一种实现方式,但table应该通过一个新的属性,通过绑定的id,去判断item的数据项是否是否显示 加 号
如:isRowKeys=[ 需要展示 加 号的ID ]

@zombieJ
Copy link
Member

zombieJ commented Mar 17, 2023

https://ant.design/components/table-cn#components-table-demo-expand

截屏2023-03-17 11 41 16

@zombieJ zombieJ closed this as completed Mar 17, 2023
@afc163
Copy link
Member

afc163 commented Mar 17, 2023

rowExpandable

@wgod9527
Copy link
Author

行可扩展
可是antd版本是3.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants