diff pylons_app/controllers/shortlog.py @ 191:b68b2246e5a6

Authenticated controller with LoginRequired decorator, and cleaned __before__ (used in baseController now). fixed User for clone url with logged in session user. Removed login form from admin.
author Marcin Kuzminski <marcin@python-works.com>
date Sat, 22 May 2010 01:47:07 +0200
parents 20dc7a5eb748
children a83a1799480c
line wrap: on
line diff
--- a/pylons_app/controllers/shortlog.py	Sat May 22 01:43:42 2010 +0200
+++ b/pylons_app/controllers/shortlog.py	Sat May 22 01:47:07 2010 +0200
@@ -7,13 +7,15 @@
 from pylons_app.lib.utils import get_repo_slug
 from pylons_app.model.hg_model import HgModel
 from webhelpers.paginate import Page
+from pylons_app.lib.auth import LoginRequired
 
 log = logging.getLogger(__name__)
 
 class ShortlogController(BaseController):
+    
+    @LoginRequired()
     def __before__(self):
-        c.repos_prefix = config['repos_name']
-        c.repo_name = get_repo_slug(request)
+        super(ShortlogController, self).__before__()
         
     def index(self):
         hg_model = HgModel()