gitlab-org--gitlab-foss/app
Fatih Acet b01a830afe Merge branch '24877-bulk-edit-only-keeps-common-labels-when-searching' into 'master'
Improve bulk assignment

This MR improves current implementation of Label dropdown when used for bulk assignment on issuable pages (/:namespace/:project/issues, /:namespace/:project/merge_requests)

Previously this dropdown relied on `<input>` tags to get its active items and also to calculate items with indeterminate state.

Relying on `<input>` tags is not enough when we want to set/get multiple states on a dropdown.

For this case we want to get/set:

- Marked items 
- Unmarked items that were initially marked
- Unmarked items that were initially indeterminate
- Items with indeterminate state.

This MR makes the Label dropdown to save its own state as `data` so it will be easy to get and set whatever state we want no matter if the dropdown is filtering which is the issue that I initially wanted to solve as you can see in the following gif.

**Before** 
![2016-12-07_11.44.48](/uploads/cb697161b8b39cdee72fdbb95a531100/2016-12-07_11.44.48.gif)

**After**
![2016-12-07_11.32.43](/uploads/338255a302de0dd1367474f33232d2a3/2016-12-07_11.32.43.gif)

As you can see in the first gif the `bug` label is removed from the selected issues but the `enhancement` label should set but the `critical` should be kept. This is fixed on the next gif.

Fixes #24877

See merge request !7765
2016-12-15 21:03:33 +00:00
..
assets Merge branch '24877-bulk-edit-only-keeps-common-labels-when-searching' into 'master' 2016-12-15 21:03:33 +00:00
controllers Merge branch 'jej-note-search-uses-finder' into 'security' 2016-12-15 11:40:12 -03:00
finders Merge branch 'jej-24637-move-issue-visible_to_user-to-finder' into 'security' 2016-12-15 11:41:04 -03:00
helpers Merge branch 'build-statuses' into 'master' 2016-12-14 12:34:22 +00:00
mailers Add new template to handle both commit & mr notes 2016-11-25 15:23:49 +00:00
models Merge branch 'show-commit-status-from-latest-pipeline' into 'master' 2016-12-15 19:48:00 +00:00
policies Backport hooks on group policies for the EE-specific implementation 2016-12-13 11:51:09 -02:00
serializers Merge branch 'fix/ca-no-date' into 'master' 2016-11-30 10:01:56 +00:00
services Merge branch 'show-commit-status-from-latest-pipeline' into 'master' 2016-12-15 19:48:00 +00:00
uploaders Add Gitlab::Middleware::Multipart 2016-12-15 12:26:36 +01:00
validators Add nested groups support to the routing 2016-11-23 14:08:36 +02:00
views Merge branch '24877-bulk-edit-only-keeps-common-labels-when-searching' into 'master' 2016-12-15 21:03:33 +00:00
workers Merge branch 'fix/rename-mwbs-to-merge-when-pipeline-succeeds' into 'master' 2016-12-05 11:07:57 +00:00