From 69e02904fe1a5442cd429bfc307bb55eefedd5d6 Mon Sep 17 00:00:00 2001 From: Patrick Derichs Date: Thu, 11 Jul 2019 15:29:16 +0200 Subject: Add endpoint to move multiple issues Add specs for new endpoint to move multiple issues. Add changelog entry Just check the first issue for the ability to move / update Add specs for exceeding limits and malformed requests Changed name of shared examples Change title of changelog entry Use %i instead of %w Check permission to update issue on project instead of board Use admin_issue permission to check for issue move ability Changed variable name to avoid shadow issue_params method Rename route to bulk_move Change route definition Check permissions for each issue Combine methods for parameters permit check Remove extra context Change description of context Check param for type Array Add unit tests to MoveService Use before_action for permission check Use set instead of let! Use let's instead of set --- config/routes.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'config/routes.rb') diff --git a/config/routes.rb b/config/routes.rb index a42fc037227..ae14b421028 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -82,7 +82,11 @@ Rails.application.routes.draw do resources :issues, only: [:index, :create, :update] end - resources :issues, module: :boards, only: [:index, :update] + resources :issues, module: :boards, only: [:index, :update] do + collection do + put :bulk_move, format: :json + end + end Gitlab.ee do resources :users, module: :boards, only: [:index] -- cgit v1.2.1