gitlab-org--gitlab-foss/app/controllers/projects/boards_controller.rb

18 lines
379 B
Ruby
Raw Normal View History

2016-08-01 16:09:41 +00:00
class Projects::BoardsController < Projects::ApplicationController
2016-08-30 13:50:46 +00:00
include IssuableCollections
respond_to :html
before_action :authorize_read_board!, only: [:show]
2016-08-01 16:09:41 +00:00
def show
::Boards::CreateService.new(project, current_user).execute
2016-08-01 16:09:41 +00:00
end
private
def authorize_read_board!
return access_denied! unless can?(current_user, :read_board, project)
end
2016-08-01 16:09:41 +00:00
end