mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-25 15:12:44 +01:00
Move input fields to add members to a team and repos to a team (#5853)
Move input fields to the top so no scrolling is needed to add new members / repos to a team. Signed-off-by: Sebastian Sauer <sauer.sebastian@gmail.com>
This commit is contained in:
parent
d663930023
commit
8656a3c62d
2 changed files with 34 additions and 34 deletions
|
@ -7,7 +7,23 @@
|
||||||
{{template "org/team/sidebar" .}}
|
{{template "org/team/sidebar" .}}
|
||||||
<div class="ui ten wide column">
|
<div class="ui ten wide column">
|
||||||
{{template "org/team/navbar" .}}
|
{{template "org/team/navbar" .}}
|
||||||
<div class="ui attached table segment members">
|
{{if .IsOrganizationOwner}}
|
||||||
|
<div class="ui attached segment">
|
||||||
|
<form class="ui form" id="add-member-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/add" method="post">
|
||||||
|
{{.CsrfTokenHtml}}
|
||||||
|
<input type="hidden" name="uid" value="{{.SignedUser.ID}}">
|
||||||
|
<div class="inline field ui left">
|
||||||
|
<div id="search-user-box" class="ui search">
|
||||||
|
<div class="ui input">
|
||||||
|
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" required>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_member"}}</button>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
{{end}}
|
||||||
|
<div class="ui bottom attached table segment members">
|
||||||
{{range .Team.Members}}
|
{{range .Team.Members}}
|
||||||
<div class="item">
|
<div class="item">
|
||||||
{{if $.IsOrganizationOwner}}
|
{{if $.IsOrganizationOwner}}
|
||||||
|
@ -24,22 +40,6 @@
|
||||||
</div>
|
</div>
|
||||||
{{end}}
|
{{end}}
|
||||||
</div>
|
</div>
|
||||||
{{if .IsOrganizationOwner}}
|
|
||||||
<div class="ui bottom attached segment">
|
|
||||||
<form class="ui form" id="add-member-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/add" method="post">
|
|
||||||
{{.CsrfTokenHtml}}
|
|
||||||
<input type="hidden" name="uid" value="{{.SignedUser.ID}}">
|
|
||||||
<div class="inline field ui left">
|
|
||||||
<div id="search-user-box" class="ui search">
|
|
||||||
<div class="ui input">
|
|
||||||
<input class="prompt" name="uname" placeholder="{{.i18n.Tr "repo.settings.search_user_placeholder"}}" autocomplete="off" required>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_member"}}</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
{{end}}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -7,8 +7,23 @@
|
||||||
{{template "org/team/sidebar" .}}
|
{{template "org/team/sidebar" .}}
|
||||||
<div class="ui ten wide column">
|
<div class="ui ten wide column">
|
||||||
{{template "org/team/navbar" .}}
|
{{template "org/team/navbar" .}}
|
||||||
<div class="ui attached table segment repositories">
|
{{$canAddRemove := and $.IsOrganizationOwner (not (eq $.Team.LowerName "owners"))}}
|
||||||
{{$canAddRemove := and $.IsOrganizationOwner (not (eq $.Team.LowerName "owners"))}}
|
{{if $canAddRemove}}
|
||||||
|
<div class="ui attached segment">
|
||||||
|
<form class="ui form" id="add-repo-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/repo/add" method="post">
|
||||||
|
{{.CsrfTokenHtml}}
|
||||||
|
<div class="inline field ui left">
|
||||||
|
<div id="search-repo-box" data-uid="{{.Org.ID}}" class="ui search">
|
||||||
|
<div class="ui input">
|
||||||
|
<input class="prompt" name="repo_name" placeholder="{{.i18n.Tr "org.teams.search_repo_placeholder"}}" autocomplete="off" required>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_repository"}}</button>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
{{end}}
|
||||||
|
<div class="ui bottom attached table segment repositories">
|
||||||
{{range .Team.Repos}}
|
{{range .Team.Repos}}
|
||||||
<div class="item">
|
<div class="item">
|
||||||
{{if $canAddRemove}}
|
{{if $canAddRemove}}
|
||||||
|
@ -25,21 +40,6 @@
|
||||||
</div>
|
</div>
|
||||||
{{end}}
|
{{end}}
|
||||||
</div>
|
</div>
|
||||||
{{if $canAddRemove}}
|
|
||||||
<div class="ui bottom attached segment">
|
|
||||||
<form class="ui form" id="add-repo-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName}}/action/repo/add" method="post">
|
|
||||||
{{.CsrfTokenHtml}}
|
|
||||||
<div class="inline field ui left">
|
|
||||||
<div id="search-repo-box" data-uid="{{.Org.ID}}" class="ui search">
|
|
||||||
<div class="ui input">
|
|
||||||
<input class="prompt" name="repo_name" placeholder="{{.i18n.Tr "org.teams.search_repo_placeholder"}}" autocomplete="off" required>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<button class="ui green button">{{.i18n.Tr "org.teams.add_team_repository"}}</button>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
{{end}}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue