lib/generators/haml/scaffold/templates/index.html.haml in haml-rails-0.5.3 vs lib/generators/haml/scaffold/templates/index.html.haml in haml-rails-0.6.0
- old
+ new
@@ -1,23 +1,25 @@
%h1 Listing <%= plural_table_name %>
%table
- %tr
+ %thead
+ %tr
<% for attribute in attributes -%>
- %th <%= attribute.human_name %>
+ %th <%= attribute.human_name %>
<% end -%>
- %th
- %th
- %th
-
- - @<%= plural_table_name %>.each do |<%= singular_table_name %>|
- %tr
+ %th
+ %th
+ %th
+
+ %tbody
+ - @<%= plural_table_name %>.each do |<%= singular_table_name %>|
+ %tr
<% for attribute in attributes -%>
- %td= <%= singular_table_name %>.<%= attribute.name %>
+ %td= <%= singular_table_name %>.<%= attribute.name %>
<% end -%>
- %td= link_to 'Show', <%= singular_table_name %>
- %td= link_to 'Edit', edit_<%= singular_table_name %>_path(<%= singular_table_name %>)
- %td= link_to 'Destroy', <%= singular_table_name %>, :method => :delete, :data => { :confirm => 'Are you sure?' }
+ %td= link_to 'Show', <%= singular_table_name %>
+ %td= link_to 'Edit', edit_<%= singular_table_name %>_path(<%= singular_table_name %>)
+ %td= link_to 'Destroy', <%= singular_table_name %>, :method => :delete, :data => { :confirm => 'Are you sure?' }
%br
= link_to 'New <%= human_name %>', new_<%= singular_table_name %>_path