Skip to content

Add units to team - #947

Merged
lunny merged 8 commits into
go-gitea:masterfrom
lunny:lunny/team_units
May 18, 2017
Merged

Add units to team#947
lunny merged 8 commits into
go-gitea:masterfrom
lunny:lunny/team_units

Conversation

@lunny

@lunny lunny commented Feb 15, 2017

Copy link
Copy Markdown
Member

This PR allows you create one team who can only see issues or pull request or wikis.

@lunny lunny added type/feature Completely new functionality. Can only be merged if feature freeze is not active. pr/wip This PR is not ready for review labels Feb 15, 2017
@lunny lunny added this to the 1.2.0 milestone Feb 15, 2017
@lunny
lunny force-pushed the lunny/team_units branch from c534a7f to 3e23400 Compare March 19, 2017 02:22
@lunny
lunny force-pushed the lunny/team_units branch from 3e23400 to e593669 Compare April 27, 2017 05:56
@lunny lunny removed the pr/wip This PR is not ready for review label Apr 27, 2017
@lunny lunny changed the title [WIP] Add units to team Add units to team Apr 27, 2017
@lunny

lunny commented Apr 27, 2017

Copy link
Copy Markdown
Member Author

This is done and could be reviewed. When add/edit a team on organization, you could chose which units could be organization's repositories operated on the by this team. For example, we can define tester team which can only operate issues on all repositories the tester team could visit.

@tboerger tboerger added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Apr 27, 2017

@bkcsoft bkcsoft left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few comments

Comment thread models/unit.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need External as a separate unit? Can we enable both internal wiki and external wiki at the same time? (same for Tracker)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think yes. Yes, we can.

Comment thread models/unit.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above

Comment thread models/unit.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above

Comment thread routers/repo/view.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we leaking information that this repo exists but have nothing to show? IMO no valid Units should be the same as Private.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error message is only for log. The UI will only show 404.

Comment thread routers/routes/routes.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was this moved?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move this for easy add middleware contex.CheckUnit. Before this, releases URLs are put on many places.

@bkcsoft

bkcsoft commented Apr 28, 2017

Copy link
Copy Markdown
Contributor

LGTM

@tboerger tboerger added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Apr 28, 2017
@lunny
lunny force-pushed the lunny/team_units branch 2 times, most recently from e2da2af to 299b4e9 Compare May 4, 2017 08:01
@lunny
lunny force-pushed the lunny/team_units branch from b4483e7 to dd65714 Compare May 15, 2017 15:07
Comment thread models/migrations/v32.go Outdated

@sapk sapk May 18, 2017

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not an expert in xorm but can't .Where("1=1") be removed ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

@sapk

sapk commented May 18, 2017

Copy link
Copy Markdown
Member

This need rebase.
I will try to test it but looking at code, I could give my trusted LGTM.

@tboerger tboerger added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels May 18, 2017
@lunny
lunny force-pushed the lunny/team_units branch from dd65714 to 7d29013 Compare May 18, 2017 09:41
@lunny

lunny commented May 18, 2017

Copy link
Copy Markdown
Member Author

@sapk rebased

@lunny
lunny merged commit fd6034a into go-gitea:master May 18, 2017
@lunny
lunny deleted the lunny/team_units branch May 18, 2017 14:56
lunny added a commit to lunny/gitea that referenced this pull request May 19, 2017
bkcsoft added a commit that referenced this pull request May 19, 2017
@kubatyszko

Copy link
Copy Markdown
Contributor

I know this PR is closed, but I believe I found an issue that might be related.
In my installation, SOME repos can't browse source, opening the repo (even clicking on <>code) redirects to /releases.

I think this PR modified a lot of routes related to releases, I wonder if that has anything to do with it...

@lunny

lunny commented Aug 1, 2017

Copy link
Copy Markdown
Member Author

@kubatyszko could you post an issue to describe that?

@go-gitea go-gitea locked and limited conversation to collaborators Nov 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/feature Completely new functionality. Can only be merged if feature freeze is not active.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants