Displaying 1 result from an estimated 1 matches for "cc_fields".
Did you mean:
c_fields
2010 Aug 13
2
Rails 3 / ActiveModel for Credit Card information?
...d class would be on the same form as
an ActiveRecord Order class but I have not been able to get an
ActiveModel to work as a nested object on a form.
something like this.. on the order new form
<%= form_for @order do |f| -%>
. order stuff here....
<% f.fields_for :credit_card do |cc_fields| %>
<%= cc_fields.label :card_number, ''*Number'' %>
<%= cc_fields.text_field :card_number, :class =>
''text'', :autocomplete => ''off'' %>
<% end %>
I have not found what magic I need to add to th...