Topic: Best way to create multiple-table-row entry form for my app?
I'm new to rails, but have already built a working application up until this point.
Basically I need an input form that can insert multiple rows into the database in one go, and hopefully display data in the same way (once the db is populated). The form can be a view/edit/update form all-in-one. If there is no db record available for a cell it should be an empty cell that creates a new record upon form submit.
I've drawn a picture to show the sort of form I am trying to achieve (and to show how it relates to the db table). In my head it seems like it would be rather complex to make it work (basically generating a virtual 'table' input structure that is not actually replicated in the database). However it would be good for the user.
The purpose of this form is to store 'adjustment' settings for a given 'shock' and 'bike' already chosen by the user. The weight (rider weight) is a preset range. The adjustments vary depending on shock choice, thus number + name of columns are dynamic.
Any tips or suggestions on the best/easiest way to make this work?
I am flexible on the layout and design of the form, the easier to code the better.
Appreciate any thoughts, especially any rails specific commands or goodies I should look into that might make life easier.
Last edited by udi (2012-04-13 22:50:19)