diff options
author | Sean McGivern <sean@mcgivern.me.uk> | 2018-03-20 08:45:08 +0000 |
---|---|---|
committer | Sean McGivern <sean@mcgivern.me.uk> | 2018-03-20 08:45:08 +0000 |
commit | 439c63365f196badda401be0f8517ec9a561b99a (patch) | |
tree | 078cb92cce28fc91fceec63c9d79e1ce52b0ab67 /app/models/service.rb | |
parent | bce962a87c9aa76b63f96b1c7ce302ba233ea68e (diff) | |
parent | 2ee197086a87d22c9203c9a3642f9db6d40f54c4 (diff) | |
download | gitlab-ce-439c63365f196badda401be0f8517ec9a561b99a.tar.gz |
Merge branch 'issue_25542' into 'master'
Improve JIRA event descriptions
Closes #25542
See merge request gitlab-org/gitlab-ce!17811
Diffstat (limited to 'app/models/service.rb')
-rw-r--r-- | app/models/service.rb | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/app/models/service.rb b/app/models/service.rb index 2556db68146..1dcb79157a2 100644 --- a/app/models/service.rb +++ b/app/models/service.rb @@ -304,6 +304,29 @@ class Service < ActiveRecord::Base end end + def self.event_description(event) + case event + when "push", "push_events" + "Event will be triggered by a push to the repository" + when "tag_push", "tag_push_events" + "Event will be triggered when a new tag is pushed to the repository" + when "note", "note_events" + "Event will be triggered when someone adds a comment" + when "issue", "issue_events" + "Event will be triggered when an issue is created/updated/closed" + when "confidential_issue", "confidential_issue_events" + "Event will be triggered when a confidential issue is created/updated/closed" + when "merge_request", "merge_request_events" + "Event will be triggered when a merge request is created/updated/merged" + when "pipeline", "pipeline_events" + "Event will be triggered when a pipeline status changes" + when "wiki_page", "wiki_page_events" + "Event will be triggered when a wiki page is created/updated" + when "commit", "commit_events" + "Event will be triggered when a commit is created/updated" + end + end + def valid_recipients? activated? && !importing? end |