-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
select component needs label and value parameters #587
Comments
Hi, what exactly are you looking for? Be more specific please. |
This is from documentation example:
My data looks like this:
I don't like to rename the fields from database. Maybe I missed something? |
I see now. What you can do is when you retrieve data use JS let options = selectOptions.map(opt => ({label: opt.comp_name, value: opt.comp_id})) |
Hi, |
@Dmedip use a Vue computed property |
@rstoenescu Thank you but how can id to that .In data instead of passing label and value (static data) how can I pass dynamic data ? |
@Dmedip Use a Vue computed property... :| computed: {
selectOptions () {
return [ { label: this.myLabel, value: this.myLabelValue }, ... ]
}
} |
hi @rstoenescu Thank you so much fro your time,trying but still could not workout,can you please take a look at below code .I have two dropdowns and need to display data for dropdowns using computed.Please help.Thanks data{ |
Here is what would improove SELECT component. Now, I have to rename my fields to get this component work, but this woud be much better.
Thank you for this great framework.
The text was updated successfully, but these errors were encountered: