summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzeripath <art27@cantab.net>2020-02-10 02:53:41 +0000
committerGitHub <noreply@github.com>2020-02-09 21:53:41 -0500
commit9789e0ad531a76f708eba9dddab5381419c6eebe (patch)
tree0cc7b546fef96aae469adcfe73dcf1c8ba4a4ab0
parent875c5e13050e4f7b95773c3b8ef5deac8b4b581b (diff)
downloadgitea-9789e0ad531a76f708eba9dddab5381419c6eebe.tar.gz
gitea-9789e0ad531a76f708eba9dddab5381419c6eebe.zip
Only show conflicted files if not merged (#10197)
* Only show conflicted files if not merged * try again Co-authored-by: Antoine GIRARD <sapk@users.noreply.github.com> Co-authored-by: techknowlogick <matti@mdranta.net>
-rw-r--r--templates/repo/issue/list.tmpl2
-rw-r--r--templates/user/dashboard/issues.tmpl2
2 files changed, 2 insertions, 2 deletions
diff --git a/templates/repo/issue/list.tmpl b/templates/repo/issue/list.tmpl
index 9cf6cdd972..ca6fa72b98 100644
--- a/templates/repo/issue/list.tmpl
+++ b/templates/repo/issue/list.tmpl
@@ -268,7 +268,7 @@
</a>
{{end}}
{{if .IsPull}}
- {{if (len .PullRequest.ConflictedFiles) gt 0}}
+ {{if and (not .PullRequest.HasMerged) ((len .PullRequest.ConflictedFiles) gt 0)}}
<span class="conflicting"><i class="octicon octicon-mirror"></i> {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
{{end}}
{{end}}
diff --git a/templates/user/dashboard/issues.tmpl b/templates/user/dashboard/issues.tmpl
index a5d7c1454e..c8cc8b09df 100644
--- a/templates/user/dashboard/issues.tmpl
+++ b/templates/user/dashboard/issues.tmpl
@@ -152,7 +152,7 @@
</span>
{{end}}
{{if .IsPull}}
- {{if (len .PullRequest.ConflictedFiles) gt 0}}
+ {{if and (not .PullRequest.HasMerged) ((len .PullRequest.ConflictedFiles) gt 0)}}
<span class="conflicting"><i class="octicon octicon-mirror"></i> {{$.i18n.Tr (TrN $.i18n.Lang (len .PullRequest.ConflictedFiles) "repo.pulls.num_conflicting_files_1" "repo.pulls.num_conflicting_files_n") (len .PullRequest.ConflictedFiles)}}</span>
{{end}}
{{end}}