diff options
author | Rubén Dávila <rdavila84@gmail.com> | 2016-03-02 13:12:16 -0500 |
---|---|---|
committer | Rubén Dávila <rdavila84@gmail.com> | 2016-03-03 09:55:53 -0500 |
commit | eb068b0fffe85c79dca1b8c765662de234198927 (patch) | |
tree | e44a44bb554037d1ff868b58ebe73222fbe7a404 /app/models/project_services | |
parent | 11b6aeafbafa221f34a555b8c862a1de3eb87aed (diff) | |
download | gitlab-ce-eb068b0fffe85c79dca1b8c765662de234198927.tar.gz |
Add commit message to JIRA's notification payload.
Diffstat (limited to 'app/models/project_services')
-rw-r--r-- | app/models/project_services/jira_service.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/models/project_services/jira_service.rb b/app/models/project_services/jira_service.rb index f6571fc063e..aba37921c09 100644 --- a/app/models/project_services/jira_service.rb +++ b/app/models/project_services/jira_service.rb @@ -108,7 +108,8 @@ class JiraService < IssueTrackerService }, entity: { name: noteable_name.humanize.downcase, - url: entity_url + url: entity_url, + title: noteable.title } } @@ -196,10 +197,11 @@ class JiraService < IssueTrackerService user_url = data[:user][:url] entity_name = data[:entity][:name] entity_url = data[:entity][:url] + entity_title = data[:entity][:title] project_name = data[:project][:name] message = { - body: "[#{user_name}|#{user_url}] mentioned this issue in [a #{entity_name} of #{project_name}|#{entity_url}]." + body: %Q{[#{user_name}|#{user_url}] mentioned this issue in [a #{entity_name} of #{project_name}|#{entity_url}]:\n'#{entity_title}'} } unless existing_comment?(issue_name, message[:body]) |