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
0
Merge Requests
0
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
iv
gitlab-ce
Commits
55440ac9
Commit
55440ac9
authored
Jun 10, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make a comment to MR whne milestone was changed
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
525fa6c1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
app/services/merge_requests/base_service.rb
app/services/merge_requests/base_service.rb
+4
-0
app/services/merge_requests/update_service.rb
app/services/merge_requests/update_service.rb
+4
-0
No files found.
app/services/merge_requests/base_service.rb
View file @
55440ac9
...
@@ -16,5 +16,9 @@ module MergeRequests
...
@@ -16,5 +16,9 @@ module MergeRequests
merge_request
.
project
.
execute_hooks
(
merge_request
.
to_hook_data
,
:merge_request_hooks
)
merge_request
.
project
.
execute_hooks
(
merge_request
.
to_hook_data
,
:merge_request_hooks
)
end
end
end
end
def
create_milestone_note
(
merge_request
)
Note
.
create_milestone_change_note
(
merge_request
,
merge_request
.
project
,
current_user
,
merge_request
.
milestone
)
end
end
end
end
end
app/services/merge_requests/update_service.rb
View file @
55440ac9
...
@@ -22,6 +22,10 @@ module MergeRequests
...
@@ -22,6 +22,10 @@ module MergeRequests
if
params
.
present?
&&
merge_request
.
update_attributes
(
params
)
if
params
.
present?
&&
merge_request
.
update_attributes
(
params
)
merge_request
.
reset_events_cache
merge_request
.
reset_events_cache
if
merge_request
.
previous_changes
.
include?
(
'milestone_id'
)
create_milestone_note
(
merge_request
)
end
if
merge_request
.
previous_changes
.
include?
(
'assignee_id'
)
if
merge_request
.
previous_changes
.
include?
(
'assignee_id'
)
notification_service
.
reassigned_merge_request
(
merge_request
,
current_user
)
notification_service
.
reassigned_merge_request
(
merge_request
,
current_user
)
create_assignee_note
(
merge_request
)
create_assignee_note
(
merge_request
)
...
...
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