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

fix(antd): fix Cascader in form readPretty mode display error #3250 #3253

Merged
merged 2 commits into from
Jul 6, 2022

Conversation

fengwuxp
Copy link
Contributor

@fengwuxp fengwuxp commented Jul 5, 2022

Before submitting a pull request, please make sure the following is done...

  • Ensure the pull request title and commit message follow the Commit Specific in English.
  • Fork the repo and create your branch from master or formily_next.
  • If you've added code that should be tested, add tests!
  • If you've changed APIs, update the documentation.
  • Ensure the test suite passes (npm test).
  • Make sure your code lints (npm run lint) - we've done our best to make sure these rules match our internal linting guidelines.

Please do not delete the above content


see issues Cascader readPretty 模式下回显错误
验证 fix demo

@CLAassistant
Copy link

CLAassistant commented Jul 5, 2022

CLA assistant check
All committers have signed the CLA.

?.filter((item) => isValid(item))
?.map((item) => item?.whole?.join('/'))
.join(', ')
const values = findSelectedItems(dataSource, selected)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

为了避免修改 getValueByValue 影响其他组件,重新写了查找选中值的逻辑。

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fusion组件要不要也改一下?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

好的,晚上处理一下

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fusion Cascader readPretty 已修复

测试发现一个新问题:
fusion 的级联选择组件普通模式回填表单值也有问题,参见: demo
回填查找逻辑好像是使用数组的最后一项,要是级联选择最后一个选项有重复(相对上一个选项)的话会就会有问题(参见例子的租户环境级联选中)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

那这个是fusion的问题吧,先忽略

@codecov
Copy link

codecov bot commented Jul 5, 2022

Codecov Report

Merging #3253 (aeccf89) into formily_next (ac807c1) will not change coverage.
The diff coverage is n/a.

@@              Coverage Diff              @@
##           formily_next    #3253   +/-   ##
=============================================
  Coverage         96.13%   96.13%           
=============================================
  Files               152      152           
  Lines              6580     6580           
  Branches           1835     1835           
=============================================
  Hits               6326     6326           
  Misses              225      225           
  Partials             29       29           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ac807c1...aeccf89. Read the comment docs.

@janryWang janryWang merged commit d571910 into alibaba:formily_next Jul 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants