comparison pylons_app/controllers/graph.py @ 252:3782a6d698af

licensing updates, code cleanups
author Marcin Kuzminski <marcin@python-works.com>
date Fri, 04 Jun 2010 13:08:29 +0200
parents b68b2246e5a6
children 237470e64bb8
comparison
equal deleted inserted replaced
251:127dba22e53b 252:3782a6d698af
1 #!/usr/bin/env python
2 # encoding: utf-8
3 # graph controller for pylons
4 # Copyright (C) 2009-2010 Marcin Kuzminski <marcin@python-works.com>
5
6 # This program is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU General Public License
8 # as published by the Free Software Foundation; version 2
9 # of the License or (at your opinion) any later version of the license.
10 #
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
15 #
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
19 # MA 02110-1301, USA.
20 """
21 Created on April 21, 2010
22 graph controller for pylons
23 @author: marcink
24 """
1 from mercurial.graphmod import revisions as graph_rev, colored, CHANGESET 25 from mercurial.graphmod import revisions as graph_rev, colored, CHANGESET
2 from mercurial.node import short 26 from mercurial.node import short
3 from pylons import request, response, session, tmpl_context as c, url, config, \ 27 from pylons import request, tmpl_context as c
4 app_globals as g
5 from pylons.controllers.util import abort, redirect
6 from pylons_app.lib.auth import LoginRequired 28 from pylons_app.lib.auth import LoginRequired
7 from pylons_app.lib.base import BaseController, render 29 from pylons_app.lib.base import BaseController, render
8 from pylons_app.lib.filters import age as _age, person 30 from pylons_app.lib.filters import age as _age, person
9 from pylons_app.lib.utils import get_repo_slug
10 from pylons_app.model.hg_model import HgModel 31 from pylons_app.model.hg_model import HgModel
11 from simplejson import dumps 32 from simplejson import dumps
12 from webhelpers.paginate import Page 33 from webhelpers.paginate import Page
13 import logging 34 import logging
14
15
16
17 35
18 log = logging.getLogger(__name__) 36 log = logging.getLogger(__name__)
19 37
20 class GraphController(BaseController): 38 class GraphController(BaseController):
21 39