]> source.dussan.org Git - gitea.git/commitdiff
Show issue/PR number on title 60/head
authorAndrey Nering <andrey.nering@gmail.com>
Wed, 12 Oct 2016 13:28:51 +0000 (10:28 -0300)
committerAndrey Nering <andrey.nering@gmail.com>
Thu, 3 Nov 2016 22:28:05 +0000 (20:28 -0200)
routers/repo/issue.go
routers/repo/pull.go

index 76d81d0e76f9b0ba1753d569be64043eb995d47c..f638b6f51f9b4de0a1512d6c222c6011b2d5e374 100644 (file)
@@ -502,7 +502,7 @@ func ViewIssue(ctx *context.Context) {
                }
                return
        }
-       ctx.Data["Title"] = issue.Title
+       ctx.Data["Title"] = fmt.Sprintf("#%d - %s", issue.Index, issue.Title)
 
        // Make sure type and URL matches.
        if ctx.Params(":type") == "issues" && issue.IsPull {
index d345dbee06e0bd88897386cddb07aaf5d02cf2d5..baa8c1d0b5d6443866b91848452f377ac06d770a 100644 (file)
@@ -6,6 +6,7 @@ package repo
 
 import (
        "container/list"
+       "fmt"
        "path"
        "strings"
 
@@ -148,7 +149,7 @@ func checkPullInfo(ctx *context.Context) *models.Issue {
                }
                return nil
        }
-       ctx.Data["Title"] = issue.Title
+       ctx.Data["Title"] = fmt.Sprintf("#%d - %s", issue.Index, issue.Title)
        ctx.Data["Issue"] = issue
 
        if !issue.IsPull {