mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Updating context and fixing permission issues
The boolean flags in the repo context have been replaced with mode and two methods Also, the permissions have been brought more in line with https://help.github.com/articles/permission-levels-for-an-organization-repository/ , Admin Team members are able to change settings of their repositories.
This commit is contained in:
@@ -49,7 +49,7 @@
|
||||
</a>
|
||||
</li>
|
||||
<li id="repo-header-fork">
|
||||
<a id="repo-header-fork-btn" {{if or (not $.IsRepositoryTrueOwner) $.Owner.IsOrganization}}href="{{AppSubUrl}}/repo/fork?fork_id={{.Id}}"{{end}}>
|
||||
<a id="repo-header-fork-btn" {{if or (not $.IsRepositoryAdmin) $.Owner.IsOrganization}}href="{{AppSubUrl}}/repo/fork?fork_id={{.Id}}"{{end}}>
|
||||
<button class="btn btn-gray text-bold btn-radius">
|
||||
<i class="octicon octicon-repo-forked"></i>{{$.i18n.Tr "repo.fork"}}
|
||||
<span class="num">{{.NumForks}}</span>
|
||||
|
@@ -20,7 +20,7 @@
|
||||
<!-- <li>
|
||||
<a class="radius" href="#"><i class="octicon octicon-organization"></i>contributors <span class="num right label label-gray label-radius">43</span></a>
|
||||
</li> -->
|
||||
{{if .IsRepositoryTrueOwner}}
|
||||
{{if .IsRepositoryAdmin}}
|
||||
<li class="border-bottom"></li>
|
||||
<li>
|
||||
<a class="radius" href="{{.RepoLink}}/settings"><i class="octicon octicon-tools"></i>{{.i18n.Tr "repo.settings"}}</a>
|
||||
|
@@ -35,7 +35,7 @@
|
||||
<li><a href="#">Pulse</a></li>
|
||||
<li><a href="#">Network</a></li>
|
||||
</ul>
|
||||
</li> -->{{end}}{{if .IsRepositoryTrueOwner}}
|
||||
</li> -->{{end}}{{if .IsRepositoryAdmin}}
|
||||
<li class="{{if .IsRepoToolbarSetting}}active{{end}}"><a href="{{.RepoLink}}/settings">Settings</a>
|
||||
</li>{{end}}
|
||||
</ul>
|
||||
|
Reference in New Issue
Block a user