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

[Bug Report] Cascader组件选中错误 #5913

Open
lihanspace opened this issue Oct 18, 2024 · 1 comment
Open

[Bug Report] Cascader组件选中错误 #5913

lihanspace opened this issue Oct 18, 2024 · 1 comment

Comments

@lihanspace
Copy link

重现链接

https://developers.weixin.qq.com/s/NhWmf1mg7DVP

Vant Weapp 版本

1.11.7

描述一下你遇到的问题。

Cascader组件

当传入的options的选项的value是number类型时,选中某一项之后,再次打开,无法自动定位到选中的项。

文档中选中项的值value和options的value是允许number类型的,而且大多数后端数据给的id也是number类型。

image

重现步骤

在编辑器中可以看到:

页面数据中的cascaderValue的值是蓝紫色,是nunber类型

Cascader组件内的options的value是蓝紫色,是number类型;

而Cascader组件内选中的value变成了淡红色,是string类型

可能是类型的变化导致无法定位到选中项。

image

image

设备/浏览器

No response

@TallNutAlt
Copy link

#5915

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

2 participants