summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhukl <contact@smyck.org>2009-04-19 13:53:24 +0200
committerhukl <contact@smyck.org>2009-04-19 13:53:24 +0200
commitb93619b221d988d8b61db0f65432ab01be371c3c (patch)
tree09acdb3323f638406ea177c481f17bbb6d44beb8
parent4e5275b36cb306a8c65054b8c4bb19c1947181e0 (diff)
added basic list of users
-rw-r--r--app/controllers/users_controller.rb1
-rw-r--r--app/views/users/index.html.erb14
2 files changed, 13 insertions, 2 deletions
diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb
index 16604fc..7e8fc9b 100644
--- a/app/controllers/users_controller.rb
+++ b/app/controllers/users_controller.rb
@@ -3,6 +3,7 @@ class UsersController < ApplicationController
3 layout 'admin' 3 layout 'admin'
4 4
5 def index 5 def index
6 @users = User.all
6 end 7 end
7 8
8 def new 9 def new
diff --git a/app/views/users/index.html.erb b/app/views/users/index.html.erb
index 51968c8..f0b5b28 100644
--- a/app/views/users/index.html.erb
+++ b/app/views/users/index.html.erb
@@ -1,2 +1,12 @@
1<h1>Users#index</h1> 1<h1>Users</h1>
2<p>Find me in app/views/users/index.html.erb</p> 2
3<table>
4 <tr>
5 <td>login</td>
6 </tr>
7 <% @users.each do |user| %>
8 <tr>
9 <td><%= user.login %></td>
10 </tr>
11 <% end %>
12</table> \ No newline at end of file