[Rails] Combo Box in rails and save 2 value in diffrent field in one field at database
i have problem to make combobox in rails can you help me.
i try this syntax
<%= f.select(:Status) %>
Status is my field in database that have 2 value "perempuan" and
"laki-laki". but i always got error in my rails
and the second problem i want to get value from 2 diffrent field, first
from text_field, and second from select_date, and i want to save it in
one field "TTL" in database, this is the syntax,
<div class="field">
<%= f.label :ttl %></td><td>
<%= f.label :":" %></td><td>
<%= f.text_field :TTL %>
<tr>
<td colspan="3" align="right">
<%= select_date %></td></tr>
</div>
i confuse, how to get select_date value and concat it with value form
text_field, and then save it in field "TTL" in database.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home