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
a41fa5f8
Commit
a41fa5f8
authored
Aug 13, 2020
by
Sean Arnold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Seperate create params from update params
parent
9d01d1b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
app/controllers/projects/issues_controller.rb
app/controllers/projects/issues_controller.rb
+12
-3
No files found.
app/controllers/projects/issues_controller.rb
View file @
a41fa5f8
...
...
@@ -90,7 +90,7 @@ class Projects::IssuesController < Projects::ApplicationController
params
[
:issue
]
||=
ActionController
::
Parameters
.
new
(
assignee_ids:
""
)
build_params
=
issue_params
.
merge
(
build_params
=
issue_
create_
params
.
merge
(
merge_request_to_resolve_discussions_of:
params
[
:merge_request_to_resolve_discussions_of
],
discussion_to_resolve:
params
[
:discussion_to_resolve
],
confidential:
!!
Gitlab
::
Utils
.
to_boolean
(
params
[
:issue
][
:confidential
])
...
...
@@ -110,7 +110,7 @@ class Projects::IssuesController < Projects::ApplicationController
end
def
create
create_params
=
issue_params
.
merge
(
spammable_params
).
merge
(
create_params
=
issue_
create_
params
.
merge
(
spammable_params
).
merge
(
merge_request_to_resolve_discussions_of:
params
[
:merge_request_to_resolve_discussions_of
],
discussion_to_resolve:
params
[
:discussion_to_resolve
]
)
...
...
@@ -290,10 +290,19 @@ class Projects::IssuesController < Projects::ApplicationController
task_num
lock_version
discussion_locked
issue_type
]
+
[{
label_ids:
[],
assignee_ids:
[],
update_task:
[
:index
,
:checked
,
:line_number
,
:line_source
]
}]
end
def
issue_create_params
create_params
=
%i[
issue_type
]
params
.
require
(
:issue
).
permit
(
*
create_params
).
merge
(
issue_params
)
end
def
reorder_params
params
.
permit
(
:move_before_id
,
:move_after_id
,
:group_full_path
)
end
...
...
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