refactoring views

This commit is contained in:
albert
2011-08-16 18:47:01 -04:00
parent c8067a4691
commit 24bf21540a
46 changed files with 244 additions and 298 deletions

View File

@@ -1,24 +1,28 @@
<h1>Forum</h1>
<div id="c-forum-topics">
<div id="a-index">
<h1>Forum</h1>
<table width="100%" class="striped">
<thead>
<tr>
<th>Title</th>
<th>Creator</th>
<th>Updated by</th>
<th>Updated at</th>
</tr>
</thead>
<tbody>
<% @forum_topics.each do |topic| %>
<tr>
<td><% if topic.is_sticky? %><span class="sticky">Sticky:</span> <% end %><%= link_to topic.title, forum_topic_path(topic) %></td>
<td><%= topic.creator.name %></td>
<td><%= topic.updater.name %></td>
<td><%= compact_time topic.updated_at %></td>
</tr>
<% end %>
</tbody>
</table>
<table width="100%" class="striped">
<thead>
<tr>
<th>Title</th>
<th>Creator</th>
<th>Updated by</th>
<th>Updated at</th>
</tr>
</thead>
<tbody>
<% @forum_topics.each do |topic| %>
<tr>
<td><% if topic.is_sticky? %><span class="sticky">Sticky:</span> <% end %><%= link_to topic.title, forum_topic_path(topic) %></td>
<td><%= topic.creator.name %></td>
<td><%= topic.updater.name %></td>
<td><%= compact_time topic.updated_at %></td>
</tr>
<% end %>
</tbody>
</table>
</div>
</div>
<%= render "secondary_links" %>

View File

@@ -6,7 +6,7 @@
</div>
<% end %>
<%= render :partial => "forum_posts/listing", :locals => {:forum_posts => @forum_posts} %>
<%= render "forum_posts/listing", :forum_posts => @forum_posts %>
<%= render "paginator" %>
</div>
</div>
@@ -14,5 +14,5 @@
<%= render "secondary_links" %>
<%= content_for(:page_title) do %>
forum/<%= @forum_topic.title %>
forum/<%= @forum_topic.title %>
<% end %>