Remove some bugs. Add warnings for renaming group. Add ability to cahnge group owner.

This commit is contained in:
Dmitriy Zaporozhets 2012-12-03 21:14:05 +03:00
parent 7f6bbf06f8
commit ba74fa1413
11 changed files with 101 additions and 51 deletions

View file

@ -4,6 +4,7 @@ class Admin::ProjectsController < AdminController
def index
@projects = Project.scoped
@projects = @projects.where(namespace_id: params[:namespace_id]) if params[:namespace_id].present?
@projects = @projects.where(namespace_id: nil) if params[:namespace_id] == Namespace.global_id
@projects = @projects.search(params[:name]) if params[:name].present?
@projects = @projects.includes(:namespace).order("namespaces.path, projects.name ASC").page(params[:page]).per(20)
end