Displaying 1 result from an estimated 1 matches for "invoice_default".
2006 Jul 30
1
Insert multiple new child records with the parent
...<%= text_field_tag("line_items[0][description]") %>
<%= text_field_tag("line_items[0][cost]") %>
<%= text_field_tag("line_items[1][description]") %>
<%= text_field_tag("line_items[1][cost]") %>
which results in a hash of hashes:
"invoice_default"=>{"0"=>{"cost"=>"100", "description"=>"line a"},
"1"=>{"cost"=>"200", "description"=>"line b"}}
The problem with the hash of hashes is that I need to give each new line
i...