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

[SelectField] Sending value to the server #4271

Closed
ishwinder opened this issue May 16, 2016 · 3 comments
Closed

[SelectField] Sending value to the server #4271

ishwinder opened this issue May 16, 2016 · 3 comments
Labels
bug 🐛 Something doesn't work component: select This is the name of the generic UI component, not the React module!

Comments

@ishwinder
Copy link

SelectField is implemented as a dropdown menu rather than an input element. This means that the value can't be sent straight to form action.

Is this an expected behavior get the value by catching the form submit and then sending the value to the server ?

@tsaifi9
Copy link

tsaifi9 commented Jul 8, 2016

agreed, bit of annoyance. in the onchange handler, I've just been updating the value of a hidden input to the value selected from the select field so it gets automatically serialized when passed to the server.

@ishwinder
Copy link
Author

I did the same hack i.e handled the onClick of the Select and updated the dummy hidden field so that it gets to the server on submit of form.

@mpontikes mpontikes mentioned this issue Aug 5, 2016
13 tasks
@Bogdan-p
Copy link

Bogdan-p commented Oct 4, 2016

I came across the same issue, if we use the uncontrolled SelectField there's no input to take the selected value from

@oliviertassinari oliviertassinari added support: question Community support but can be turned into an improvement bug 🐛 Something doesn't work component: select This is the name of the generic UI component, not the React module! and removed support: question Community support but can be turned into an improvement labels Feb 12, 2017
@oliviertassinari oliviertassinari changed the title Sending SelectField Value to the server [SelectField] Sending value to the server Feb 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: select This is the name of the generic UI component, not the React module!
Projects
None yet
Development

No branches or pull requests

4 participants