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

Picker为什么result只返回value,而不返回label? #20

Closed
Mavis-0211 opened this issue Dec 17, 2016 · 4 comments
Closed

Picker为什么result只返回value,而不返回label? #20

Mavis-0211 opened this issue Dec 17, 2016 · 4 comments

Comments

@Mavis-0211
Copy link

在表单中需要填入label值,提交表单时需要提交value值。目前result只返回了value值,请问使用者们怎么把label值填入表单页面显示出来的......
不返回一个对象,只返回value,是出于什么特殊的考虑吗?

@sklme
Copy link
Collaborator

sklme commented Dec 19, 2016

当时是考虑到尽量让result结构简单一些,所以label只作为展示而不作返回值。
因为现在label和value都是可以自己定制,你可以考虑先将value直接定义成你想要的样子。

我们讨论一下返回label是否必要。

@quzhilin
Copy link

还好

@baiyapeng
Copy link

确实,我现在只能把value + '-' + label整体作为value再自己截取

@BearJ
Copy link
Collaborator

BearJ commented Feb 9, 2017

现在v1.1.0 picker将同时返回label和value了

@BearJ BearJ closed this as completed Feb 23, 2017
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

5 participants