gitlab-org--gitlab-foss/app/services/merge_requests
Douwe Maan d57d892e3f Merge branch 'assign-issues-for-merge-request-18876' into 'master'
Ability to bulk assign issues to author of merge request

## What does this MR do?
Provides a link to auto-assign issues to the author of a merge request, when they are mentioned as being closed by the MR.

## Are there points in the code the reviewer needs to double check?


## Why was this MR needed?
To help avoid working on a MR without having assigned related issues to self

## What are the relevant issue numbers?
Fixes #18876 

## Screenshots (if relevant)
![ScreenShot-P216](/uploads/1af5e71a0a0ff0a60c5d7b54c0e09d9c/ScreenShot-P216.png)

## Tasks
- [x] Refactor or move away from using `BulkUpdateService`
- [x] ~~Consider alternate link message when only a subset of issues will be assigned~~
- [x] Minimize repeated calls to expensive `closes_issues` method
- [x] Move away from using inflector for pluralization and fix flash message
- [x] Change auth `before_action` and fallback to error flash message
- [x] Shouldn't overwrite current assignee if one exists

## Does this MR meet the acceptance criteria?

- [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added
- [x] ~~[Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~
- [x] ~~API support added~~
- Tests
  - [x] Added for this feature/bug
  - [x] All builds are passing
- [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides)
- [x] Branch has no merge conflicts with `master` (if you do - rebase it please)
- [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits)

See merge request !5725
2016-10-11 17:20:38 +00:00
..
add_todo_when_build_fails_service.rb
assign_issues_service.rb fixup! Added link to bulk assign issues to MR author. (Issue #18876) 2016-10-07 17:16:42 +01:00
base_service.rb Add a /wip slash command 2016-10-03 09:36:21 +02:00
build_service.rb Allow empty merge requests 2016-10-11 10:50:49 +02:00
close_service.rb Enforce permissions in `{Issues,MergeRequests}::{Close,Reopen}Service` 2016-08-13 00:06:11 +02:00
create_service.rb Use the `IssuableBaseService` lifecycle hooks to cache `MergeRequestsClosingIssues` 2016-09-21 01:22:20 +05:30
get_urls_service.rb Project tools visibility level 2016-09-01 11:47:59 -03:00
merge_request_diff_cache_service.rb switch from diff_file_collection to diffs 2016-08-03 07:00:20 +02:00
merge_service.rb Properly abort a merge when merge conflicts occur 2016-07-29 11:21:21 -07:00
merge_when_build_succeeds_service.rb Rename MergeRequest methods that return commits or shas to be more clear and consistent 2016-07-06 18:50:58 -04:00
post_merge_service.rb Close todos when accepting a MR via the API. 2016-09-29 14:51:12 -04:00
refresh_service.rb Add a spec for merge request metric caching while refreshing a merge request from a forked project. 2016-09-21 02:15:02 +05:30
reopen_service.rb Enforce permissions in `{Issues,MergeRequests}::{Close,Reopen}Service` 2016-08-13 00:06:11 +02:00
resolve_service.rb Use Repository#fetch_ref 2016-08-30 16:23:45 +01:00
resolved_discussion_notification_service.rb Address review feedback 2016-08-16 11:04:26 -05:00
update_service.rb Add a /wip slash command 2016-10-03 09:36:21 +02:00