Fix global search for inventories (#1988)

This commit is contained in:
aignatov-bio 2019-08-19 09:23:59 +02:00 committed by GitHub
parent 5adb745743
commit d741e52427
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 2 deletions

View file

@ -311,7 +311,7 @@ class RepositoriesController < ApplicationController
def load_parent_vars
@team = current_team
render_404 unless @team
@repositories = Repository.accessible_by_teams(@team)
@repositories = Repository.accessible_by_teams(@team).order('repositories.created_at ASC')
end
def check_team

View file

@ -36,7 +36,6 @@ class Repository < ApplicationRecord
'OR team_repositories.team_id IN (?) '\
'OR repositories.shared = true', teams, teams)
.distinct
.order(:created_at)
}
def self.search(