I've been trying to find a decent solution for nested form,开发者_开发百科 but I couldn't find any tutorial or blog on this topic. Please come and rescue.
Firstly, you'll want to check our Ryan's screencast: http://railscasts.com/episodes/196-nested-model-form-part-1
Once you've seen the tutorial, you'll want to play around with the nested_form_for gem: https://github.com/ryanb/nested_form
If you need to see it in action, I've done a working carrierwave+nested form example here: https://github.com/galaxylord/carrierwave_nested
You can always poke around the rails guides as well for some examples: http://guides.rubyonrails.org/routing.html#nested-resources
Hope this puts you on the right track!
精彩评论