Browse Source

Change order of possible-owner organizations to alphabetical (#13160)

Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
tags/v1.15.0-dev
Elena Neuschild GitHub 4 years ago
parent
commit
c81ea75e36
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      models/org.go

+ 2
- 1
models/org.go View File

@@ -476,7 +476,8 @@ func GetOrgsCanCreateRepoByUserID(userID int64) ([]*User, error) {
Join("INNER", "`team`", "`team`.id = `team_user`.team_id"). Join("INNER", "`team`", "`team`.id = `team_user`.team_id").
Where(builder.Eq{"`team_user`.uid": userID}). Where(builder.Eq{"`team_user`.uid": userID}).
And(builder.Eq{"`team`.authorize": AccessModeOwner}.Or(builder.Eq{"`team`.can_create_org_repo": true})))). And(builder.Eq{"`team`.authorize": AccessModeOwner}.Or(builder.Eq{"`team`.can_create_org_repo": true})))).
Desc("`user`.updated_unix").Find(&orgs)
Asc("`user`.name").
Find(&orgs)
} }


// GetOrgUsersByUserID returns all organization-user relations by user ID. // GetOrgUsersByUserID returns all organization-user relations by user ID.


Loading…
Cancel
Save