-
Notifications
You must be signed in to change notification settings - Fork 1
Add select boxes #275
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
base: main
Are you sure you want to change the base?
Add select boxes #275
Conversation
nerdinand
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@SK2108 So far so good! In the future you could also attach a screenshot to the PR so we can see what the changes look like without running your branch.
app/views/songs/index.html.erb
Outdated
| <% end %> | ||
|
|
||
| <%= form_with url: songs_path, method: :get do |form| %> | ||
| <%= form.select :language, ["English", "German"], { include_blank: true } %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eventually, these values (["English", "German"]) will have to be loaded from the database (should include all the values that are in use currently.
app/views/songs/index.html.erb
Outdated
|
|
||
| <%= form_with url: songs_path, method: :get do |form| %> | ||
| <%= form.select :language, ["English", "German"], { include_blank: true } %> | ||
| <%= submit_tag 'Apply', class: 'btn btn-primary' %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'Apply' will have to be replaced with an I18n call.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have now pushed this change.
See issue #221.
This Pull Request adds select boxes.
Currently, songs can only be filtered by language: