1
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-11-02 08:57:32 -04:00

Show protection symbol if needed on default branch (#7660) (#7668)

* backport issue showing portection symbol if needet at default branch

* sugestion to use range .Branches
d57973a804
This commit is contained in:
6543 2019-07-30 16:48:53 +02:00 committed by Lunny Xiao
parent 0a9794a6bc
commit 9fbb898058

View File

@ -13,10 +13,14 @@
<tbody>
<tr>
<td>
{{range .Branches}}
{{if eq .Name $.DefaultBranch}}
{{if .IsProtected}}
<i class="octicon octicon-shield"></i>
{{end}}
{{.DefaultBranch}}
{{.Name}}
{{end}}
{{end}}
</td>
</tr>
</tbody>
@ -40,7 +44,7 @@
</tr>
</thead>
<tbody>
{{range $branch := .Branches}}
{{range .Branches}}
{{if ne .Name $.DefaultBranch}}
<tr>
<td>