From d208d763ddc3c0a4be8661dd5fddbc98988e2186 Mon Sep 17 00:00:00 2001 From: Andrey Nering Date: Wed, 12 Oct 2016 10:28:51 -0300 Subject: [PATCH] Show issue/PR number on title --- routers/repo/issue.go | 2 +- routers/repo/pull.go | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/routers/repo/issue.go b/routers/repo/issue.go index 21d4c7d96..7d97bcf99 100644 --- a/routers/repo/issue.go +++ b/routers/repo/issue.go @@ -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 { diff --git a/routers/repo/pull.go b/routers/repo/pull.go index d5d9bc9b0..9215ba057 100644 --- a/routers/repo/pull.go +++ b/routers/repo/pull.go @@ -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 {