app/views/archangel/backend/pages/index.html.erb in archangel-0.0.7 vs app/views/archangel/backend/pages/index.html.erb in archangel-0.0.8
- old
+ new
@@ -27,28 +27,10 @@
<th class="actions text-right" scope="col"><%= Archangel.t(:actions) %></th>
</tr>
</thead>
<tbody>
- <% @pages.each do |page| %>
- <tr class="<%= page.published_status %>">
- <td>
- <%= page.title %>
-
- <%= fa_icon("home") if page.homepage? %>
- </td>
- <td>
- <%= URI.decode(frontend_page_path(page.path)) %>
- </td>
- <td><%= page.published_at %></td>
- <td class="actions text-right">
- <%= link_to(fa_icon("info-circle", text: Archangel.t(:show)), backend_page_path(page), class: "btn btn-info btn-sm") %>
- <%= link_to(fa_icon("check-circle", text: Archangel.t(:edit)), edit_backend_page_path(page), class: "btn btn-warning btn-sm") %>
- <%= link_to(fa_icon("times-circle", text: Archangel.t(:destroy)), backend_page_path(page), class: "btn btn-danger btn-sm",
- method: :delete, data: { confirm: Archangel.t(:are_you_sure) }) %>
- </td>
- </tr>
- <% end %>
+ <%= render partial: "page", collection: @pages %>
</tbody>
</table>
</div>
<%= paginate @pages %>