-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Add team option to grant rights for all organization repositories #8688
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
lafriks
merged 27 commits into
go-gitea:master
from
davidsvantesson:team-grant-all-repos
Nov 6, 2019
Merged
Changes from 25 commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
0b8e90e
Add field IsAllRepositories to team
ngourdon b478a10
Add AllRepositories to team UI
ngourdon e5f6d9e
Manage team with access to all repositories
ngourdon 7cca125
Add field IsAllRepositories to team API
ngourdon a02aa18
put backticks around table/column names
ngourdon 8216a2a
rename IsAllRepositories to IncludesAllRepositories
ngourdon f698385
do not reload slice if already loaded
ngourdon 0496588
add repo to teams with access to all repositories when changing repo …
ngourdon c097a29
improve tests for teams with access to all repositories
ngourdon 3a3ccf8
Merge branch 'master'
ngourdon 5fa75d4
Merge branch 'master'
ngourdon d262016
Merge branch 'master' into fix-6409
ngourdon 8f297ca
Merge branch 'master' into fix-6409
ngourdon 550cbcc
Change code for adding all repositories
davidsvantesson 5316bdf
Merge remote-tracking branch 'upstream/master' into team-grant-all-repos
davidsvantesson c1a2e26
fmt after merge
davidsvantesson cfeb1c3
Change code in API EditTeam similar to EditTeamPost web interface
davidsvantesson 06ac307
Clarify that all repositories will be added
davidsvantesson 3f291df
Merge remote-tracking branch 'upstream/master' into team-grant-all-repos
davidsvantesson 5f6a701
All repositories option under Permissions headline
davidsvantesson c4546cd
New setting group 'Repository access'
davidsvantesson ee52d2d
Merge remote-tracking branch 'upstream/master' into team-grant-all-re…
davidsvantesson 753b7d2
Move check IncludeAllRepositories to removeRepository.
davidsvantesson 7c7fa0d
Revert "Move check IncludeAllRepositories to removeRepository." and a…
davidsvantesson 30faed9
Merge branch 'master' into team-grant-all-repos
davidsvantesson ad2d925
Clarify help text what options do.
davidsvantesson 4a509e8
Merge branch 'master' into team-grant-all-repos
lafriks File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Copyright 2019 The Gitea Authors. All rights reserved. | ||
// Use of this source code is governed by a MIT-style | ||
// license that can be found in the LICENSE file. | ||
|
||
package migrations | ||
|
||
import ( | ||
"xorm.io/xorm" | ||
) | ||
|
||
func addTeamIncludesAllRepositories(x *xorm.Engine) error { | ||
|
||
type Team struct { | ||
ID int64 `xorm:"pk autoincr"` | ||
IncludesAllRepositories bool `xorm:"NOT NULL DEFAULT false"` | ||
} | ||
|
||
if err := x.Sync2(new(Team)); err != nil { | ||
return err | ||
} | ||
|
||
_, err := x.Exec("UPDATE `team` SET `includes_all_repositories` = ? WHERE `name`=?", | ||
true, "Owners") | ||
return err | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.