Fix mongoid deeply nested polimorphic

Got the commit from github. The roles and sub_roles save.
This commit is contained in:
chris2tof committed 2011-12-19 21:22:26 +08:00
1 parent d27d7a623c
commit 4108ebf06d
11 files changed
+45 -41

No files matched your search

+5 -5
View File
@@ -13,11 +13,11 @@
<tbody>
<tr class="list_item">
<td><%= is_new ? (f.text_field :key, {:style => "width:150px"}) : @attribute.key %></td>
<% @site_valid_locales.each do |locale| %>
<td>
<%= text_field_tag "#{@attribute_type}[i18n_variable][#{locale}]", (@i18n_variable[locale] if @i18n_variable), :style => "width:150px" %>
</td>
<% end %>
<%= f.fields_for :i18n_variable, (@attribute.new_record? ? @attribute.build_i18n_variable : @attribute.i18n_variable) do |f| %>
<% @site_valid_locales.each do |locale| %>
<td><%= f.text_field locale, :style => "width:150px" %></td>
<% end %>
<% end %>
</tr>
</tbody>
</table>