OSDN Git Service

t#31470:create pager
[pettanr/pettanr.git] / app / views / authors / index.html.erb
1 <h1><%= t '.title' -%></h1>
2
3 <table>
4   <tr>
5     <th><%= t_m 'Author.name' -%></th>
6     <th><%= t_m 'Author.created_at' -%></th>
7     <th><%= t_m 'Author.updated_at' -%></th>
8   </tr>
9
10   <% @authors.each do |author| %>
11     <tr>
12       <td><%= link_to h(truncate(author.name, :length => 12)), author_path(author) %></td>
13       <td><%= distance_of_time_in_words_to_now author.created_at %></td>
14       <td><%= distance_of_time_in_words_to_now author.updated_at %></td>
15     </tr>
16   <% end %>
17 </table>
18 <%= paginate(@paginate) %>