Show More
Commit Description:
better naming...
Commit Description:
better naming git-svn-id: http://theory.cpe.ku.ac.th/grader/web/trunk@36 6386c4cd-e34a-4fa8-8920-d93eb39b512e
File last commit:
Show/Diff file:
Action:
app/views/users/list.rhtml | 27 lines | 814 B | text/html+ruby | RhtmlLexer |
<h1>Listing users</h1>
<table>
<tr>
<% for column in User.content_columns %>
<th><%= column.human_name %></th>
<% end %>
</tr>
<% for user in @users %>
<tr>
<% for column in User.content_columns %>
<td><%=h user.send(column.name) %></td>
<% end %>
<td><%= link_to 'Show', :action => 'show', :id => user %></td>
<td><%= link_to 'Edit', :action => 'edit', :id => user %></td>
<td><%= link_to 'Destroy', { :action => 'destroy', :id => user }, :confirm => 'Are you sure?', :method => :post %></td>
</tr>
<% end %>
</table>
<%= link_to 'Previous page', { :page => @user_pages.current.previous } if @user_pages.current.previous %>
<%= link_to 'Next page', { :page => @user_pages.current.next } if @user_pages.current.next %>
<br />
<%= link_to 'New user', :action => 'new' %>