I am looking for the possibility to build a table in my view dynamically, depending on selection.
Currently i have 2 combox ,2 submit buttons and a text_area in my view eg.:
<%= select_tag :user_selected, options_from_collection_for_select(@user, 'id', 'lastname') %>
<%= select_tag(:rights_id, options_for_select([['Read', 1], ['Read/Write', 2], ['Read/Write/Delete', 3]])) %>
<%= submit_tag "add" %>
<%= fields_for :content do |tf| %>
<%= tf.text_area :text , :id => 'text', :cols => '100', :rows => '25' %>
<% end %>
<%= tf.submit 'Save' %>
Every time if i hit the add button, i will expand the table with my selection, but the content from the text_area shoud be unchanged.
Is this possible in rails? If yes, how can i do it?