diff options
author | Marcia Ramos <virtua.creative@gmail.com> | 2017-05-03 12:27:16 -0300 |
---|---|---|
committer | Marcia Ramos <virtua.creative@gmail.com> | 2017-05-03 12:27:16 -0300 |
commit | 17d5b333af19ccab3685592082740ad1db0e2fb4 (patch) | |
tree | 280d52a6b0ec4e438013c5d293a5e0eda99ae572 /app/models/todo.rb | |
parent | dd91260899912956534ffffda2272053668c8f68 (diff) | |
parent | c33c23104246b14f25d4c535e7f153a0cb389f7f (diff) | |
download | gitlab-ce-new-docs-topic-issues.tar.gz |
Merge branch 'new-docs-topic-issues' of gitlab.com:gitlab-org/gitlab-ce into new-docs-topic-issuesnew-docs-topic-issues
Diffstat (limited to 'app/models/todo.rb')
-rw-r--r-- | app/models/todo.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/app/models/todo.rb b/app/models/todo.rb index f5ade1cc293..4c99aa0d3be 100644 --- a/app/models/todo.rb +++ b/app/models/todo.rb @@ -6,13 +6,15 @@ class Todo < ActiveRecord::Base BUILD_FAILED = 3 MARKED = 4 APPROVAL_REQUIRED = 5 # This is an EE-only feature + UNMERGEABLE = 6 ACTION_NAMES = { ASSIGNED => :assigned, MENTIONED => :mentioned, BUILD_FAILED => :build_failed, MARKED => :marked, - APPROVAL_REQUIRED => :approval_required + APPROVAL_REQUIRED => :approval_required, + UNMERGEABLE => :unmergeable } belongs_to :author, class_name: "User" @@ -66,6 +68,10 @@ class Todo < ActiveRecord::Base end end + def unmergeable? + action == UNMERGEABLE + end + def build_failed? action == BUILD_FAILED end |