gitlab-org--gitlab-foss/app/controllers/public/projects_controller.rb
2013-09-24 16:00:21 +03:00

13 lines
481 B
Ruby

class Public::ProjectsController < ApplicationController
skip_before_filter :authenticate_user!,
:reject_blocked, :set_current_user_for_observers,
:add_abilities
layout 'public'
def index
@projects = Project.public_only
@projects = @projects.search(params[:search]) if params[:search].present?
@projects = @projects.includes(:namespace).order("namespaces.path, projects.name ASC").page(params[:page]).per(20)
end
end