Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
4a4adbe2
Commit
4a4adbe2
authored
Oct 02, 2017
by
Oswaldo Ferreira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update labels, weight and assignee when adding a issue to the board
parent
50a52111
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
3 deletions
+8
-3
app/assets/javascripts/boards/components/modal/footer.js
app/assets/javascripts/boards/components/modal/footer.js
+6
-2
app/controllers/concerns/issuable_actions.rb
app/controllers/concerns/issuable_actions.rb
+2
-1
No files found.
app/assets/javascripts/boards/components/modal/footer.js
View file @
4a4adbe2
...
...
@@ -30,11 +30,15 @@ gl.issueBoards.ModalFooter = Vue.extend({
const
list
=
this
.
modal
.
selectedList
||
this
.
state
.
lists
[
firstListIndex
];
const
selectedIssues
=
ModalStore
.
getSelectedIssues
();
const
issueIds
=
selectedIssues
.
map
(
issue
=>
issue
.
id
);
const
currentBoard
=
this
.
state
.
currentBoard
;
const
boardLabelIds
=
currentBoard
.
labels
.
map
(
label
=>
label
.
id
);
// Post the data to the backend
gl
.
boardService
.
bulkUpdate
(
issueIds
,
{
add_label_ids
:
[
list
.
label
.
id
],
milestone_id
:
this
.
state
.
currentBoard
.
milestone_id
,
add_label_ids
:
[
list
.
label
.
id
,
...
boardLabelIds
],
milestone_id
:
currentBoard
.
milestone_id
,
assignee_ids
:
[
currentBoard
.
assignee_id
],
weight
:
currentBoard
.
weight
}).
catch
(()
=>
{
new
Flash
(
'
Failed to update issues, please try again.
'
,
'
alert
'
);
...
...
app/controllers/concerns/issuable_actions.rb
View file @
4a4adbe2
...
...
@@ -75,9 +75,10 @@ module IssuableActions
:milestone_id
,
:state_event
,
:subscription_event
,
:weight
,
label_ids:
[],
add_label_ids:
[],
remove_label_ids:
[]
remove_label_ids:
[]
,
]
if
resource_name
==
'issue'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment