From 55365b38f2075844326a94f05f2c26346de1dd7c Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: Mar 20 2014 09:09:55 +0000 Subject: Add endpoint to view issue opened against a fork --- diff --git a/progit/fork.py b/progit/fork.py index c0ae027..45a3b49 100644 --- a/progit/fork.py +++ b/progit/fork.py @@ -454,6 +454,28 @@ def fork_new_issue(username, repo): ) +@APP.route('/fork///issue/') +def view_fork_issue(username, repo, issueid): + """ List all issues associated to a repo + """ + repo = progit.lib.get_project(SESSION, repo, user=username) + + if repo is None: + flask.abort(404, 'Project not found') + + issue = progit.lib.get_issue(SESSION, issueid) + + if issue is None: + flask.abort(404, 'Issue not found') + + return flask.render_template( + 'issue.html', + select='issues', + repo=repo, + issue=issue, + ) + + @APP.route('/fork///request-pull') @APP.route('/fork///request-pull/') def request_pull_fork(username, repo, commitid=None):