branches.py
20 lines
| 620 B
| text/x-python
|
PythonLexer
r245 | from pylons import tmpl_context as c, app_globals as g | |||
from pylons_app.lib.auth import LoginRequired | ||||
from pylons_app.lib.base import BaseController, render | ||||
from pylons_app.model.hg_model import HgModel | ||||
r93 | import logging | |||
r127 | log = logging.getLogger(__name__) | |||
r93 | ||||
class BranchesController(BaseController): | ||||
r191 | ||||
@LoginRequired() | ||||
r127 | def __before__(self): | |||
r191 | super(BranchesController, self).__before__() | |||
r93 | def index(self): | |||
r127 | hg_model = HgModel() | |||
c.repo_info = hg_model.get_repo(c.repo_name) | ||||
c.repo_branches = c.repo_info.branches | ||||
return render('branches/branches.html') | ||||