rosa-build/app/controllers/api/v1/maintainers_controller.rb

13 lines
557 B
Ruby
Raw Normal View History

2012-11-26 11:32:23 +00:00
class Api::V1::MaintainersController < Api::V1::BaseController
skip_before_action :check_auth if APP_CONFIG['anonymous_access']
2015-03-04 23:19:19 +00:00
before_action :authenticate_user! unless APP_CONFIG['anonymous_access']
2012-11-26 11:32:23 +00:00
def index
2015-03-26 00:26:24 +00:00
authorize @platform = Platform.find(params[:platform_id]), :show?
2012-11-30 17:15:37 +00:00
@maintainers = BuildList::Package.includes(:project)
.actual.by_platform(@platform)
.like_name(params[:package_name])
2012-11-30 17:15:37 +00:00
.paginate(paginate_params)
2012-11-26 11:32:23 +00:00
end
end