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组件summary添加默认值 #5370

Closed
comp-squirrel opened this issue Nov 8, 2023 · 0 comments
Closed

Table组件summary添加默认值 #5370

comp-squirrel opened this issue Nov 8, 2023 · 0 comments
Labels
feature request New feature or request

Comments

@comp-squirrel
Copy link

This function solves the problem (这个功能解决的问题)

cell = (row[key] as SummaryCell).value
中可以看出,当返回的summary对象缺失部分属性时会导致报错,若要正常使用则需要在summary对象中加上不需要的统计属性或使用colSpan,前者会导致产生无用代码,而后者当align为center时会导致无法对齐,建议添加链式判断

Expected API (期望的 API)

将源码中cell = (row[key] as SummaryCell).value改为cell = (row[key] as SummaryCell)?.value

@github-actions github-actions bot added the feature request New feature or request label Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant