diff --git a/app/controllers/api/v1/build_lists_controller.rb b/app/controllers/api/v1/build_lists_controller.rb index b41459394..91e8ce058 100644 --- a/app/controllers/api/v1/build_lists_controller.rb +++ b/app/controllers/api/v1/build_lists_controller.rb @@ -8,7 +8,7 @@ class Api::V1::BuildListsController < Api::V1::BaseController load_and_authorize_resource :build_list, :only => [:show, :create, :cancel, :publish, :reject_publish] def index - filter = BuildList::Filter.new(nil, current_user, params[:filter] || {}) + filter = BuildList::Filter.new(@project, current_user, params[:filter] || {}) @build_lists = filter.find.scoped(:include => [:save_to_platform, :project, :user, :arch]) @build_lists = @build_lists.recent.paginate(paginate_params) end diff --git a/config/routes.rb b/config/routes.rb index b57307f1b..a3a65c2a2 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -54,6 +54,7 @@ Rosa::Application.routes.draw do delete :remove_member put :update_member } + resources :build_lists, :only => :index end resources :users, :only => [:show] get 'user' => 'users#show_current_user'