Noob here. I’m building a recipe website and am having issues with 1 little piece. If you have the time to point me in the right direction it would be great.
I have a recipe table with title, desc, photo, time to prepare.
I also have a ingredients table with amount, modifier (eg cups, ml), ingredient, modifier2 (chopped, diced, etc)
I wasn’t to be able to add/edit a recipe and its ingredients in 1 page and have it populate both tables.
I’m assuming its dead simple and I’m just overlooking something basic.
I don’t need a verbose answer, just pointing on the right direction
You need to look up nested forms:
http://railscasts.com/episodes/196-nested-model-form-part-1
http://railscasts.com/episodes/197-nested-model-form-part-2
Short pseudo example: