diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-10-24 21:10:18 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-10-24 21:10:18 +0300 |
commit | 84cacdae74db0de90cf88ceef2191f399e9659b2 (patch) | |
tree | 679f359bde918dd341b70937a9cf5e115851ff89 /app/models/incident_management | |
parent | cb9b55e662d4164d913ef7031adc135d3ea4d9f0 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/incident_management')
-rw-r--r-- | app/models/incident_management/timeline_event_tag.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/models/incident_management/timeline_event_tag.rb b/app/models/incident_management/timeline_event_tag.rb index cde3afcaa16..ad1ec04e1e7 100644 --- a/app/models/incident_management/timeline_event_tag.rb +++ b/app/models/incident_management/timeline_event_tag.rb @@ -4,6 +4,9 @@ module IncidentManagement class TimelineEventTag < ApplicationRecord self.table_name = 'incident_management_timeline_event_tags' + START_TIME_TAG_NAME = 'Start time' + END_TIME_TAG_NAME = 'End time' + belongs_to :project, inverse_of: :incident_management_timeline_event_tags has_many :timeline_event_tag_links, @@ -16,5 +19,9 @@ module IncidentManagement validates :name, presence: true, format: { with: /\A[^,]+\z/ } validates :name, uniqueness: { scope: :project_id } validates :name, length: { maximum: 255 } + + def self.pluck_names + pluck(:name) + end end end |