lib/generators/mdd/scaffold/templates/views/show.html.erb in mdd-2.0.1 vs lib/generators/mdd/scaffold/templates/views/show.html.erb in mdd-2.0.2
- old
+ new
@@ -2,25 +2,25 @@
<div class="page_header">
<h1><%%= t('<%= @model.plural_name %>.show_title') %></h1>
</div>
<div class="inside">
- <%- @model.attributes.each do |attr| %>
- <div class="field">
- <label><%%= t '<%= @model.plural_name %>.index_<%= attr.name %>' %></label>
- <span>
- <%- if !attr.references? %>
- <%%= @<%= @model.singular_name %>.<%= attr.name %> %>
- <%- elsif attr.belongs_to? || attr.nested_one? %>
- <%%= @<%= @model.singular_name %>.<%= attr.type.singular_name %>.<%= attr.reference %> %>
- <%- elsif attr.has_many? or attr.nested_many? %>
- <ul>
- <%% @<%= @model.singular_name %>.<%= attr.type.plural_name %>.each do |<%= attr.type.singular_name %>| %>
- <li><%%= <%= attr.type.singular_name %>.<%= attr.reference %> %> </li>
- <%% end %>
- </ul>
- <%- end %>
- </span>
- </div>
- <%- end %>
+ <%- @model.attributes.each do |attr| -%>
+ <div class="field">
+ <label><%%= t '<%= @model.plural_name %>.index_<%= attr.name %>' %></label>
+ <span>
+ <%- if !attr.references? -%>
+ <%%= @<%= @model.singular_name %>.<%= attr.name %> %>
+ <%- elsif attr.belongs_to? || attr.nested_one? -%>
+ <%%= @<%= @model.singular_name %>.<%= attr.type.singular_name %>.<%= attr.reference %> %>
+ <%- elsif attr.has_many? or attr.nested_many? -%>
+ <ul>
+ <%% @<%= @model.singular_name %>.<%= attr.type.plural_name %>.each do |<%= attr.type.singular_name %>| %>
+ <li><%%= <%= attr.type.singular_name %>.<%= attr.reference %> %> </li>
+ <%% end %>
+ </ul>
+ <%- end -%>
+ </span>
+ </div>
+ <%- end -%>
</div>
</div>
\ No newline at end of file