scss org and parenthood adding

This commit is contained in:
2015-10-03 15:15:19 -05:00
parent c1f872e9a1
commit 0510f1c4c2
19 changed files with 207 additions and 162 deletions

View File

@ -12,10 +12,12 @@
= link_to 'remove', del_parenthood_path(@parent, child), method: :delete
%p Add Child:
:ruby
select_options = options_from_collection_for_select(@more_children, :id, :name)
html_options = {
include_blank: false,
prompt: 'Add a child to parent'
}
= select_tag(:child, select_options, html_options)
= form_tag add_parenthood_path(@parent) do
:ruby
select_options = options_from_collection_for_select(@more_children, :id, :name)
html_options = {
include_blank: true,
data: { id: 'children' }
}
= select_tag(:child, select_options, html_options)
= submit_tag 'Add Child to Parent'