Dead simple user list.
[zzz-spline-users.git] / spline / plugins / users / controllers / users.py
index 6cb36d5..4afb9cd 100644 (file)
@@ -41,11 +41,9 @@ class ProfileEditForm(Form):
 
 class UsersController(BaseController):
 
-    def index(self):
-        # Return a rendered template
-        #   return render('/template.mako')
-        # or, Return a response
-        return 'stub'
+    def list(self):
+        c.users = meta.Session.query(model.User).order_by(model.User.id.asc())
+        return render('/users/list.mako')
 
     def profile(self, id, name=None):
         """Main user profile.
@@ -86,5 +84,5 @@ class UsersController(BaseController):
         h.flash('Saved your profile.', icon='tick')
 
         redirect_to(controller='users', action='profile',
-                    id=c.page_user.id, name=c.page_user.name.lower(),
+                    id=c.page_user.id, name=c.page_user.name,
                     _code=303)