i have two models:
GeoRegion & GeoRegionSub
which have a has_many relation to each other.
how can include the has_many relation in the collection_select helper? i
want to have that dropdown where the parent is in black and the children
<%= collection_select :dl,:parent_id, GeoRegion.all.???, :id, :title %>
It’s such a pain to find the appropriate documentation to do that.
u can do that:
<%= select_tag :skillset_id,
:children, :title, :id, :title) %>
Skillset is a act_as_tree model!
hope that helps
You just made my day!
I tried your solution then find out this equivalent (better?)
Thanks for the help.