diff options
Diffstat (limited to 'app/models/concerns')
-rw-r--r-- | app/models/concerns/analytics/cycle_analytics/stage.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/app/models/concerns/analytics/cycle_analytics/stage.rb b/app/models/concerns/analytics/cycle_analytics/stage.rb index dde73b567db..39e8408f794 100644 --- a/app/models/concerns/analytics/cycle_analytics/stage.rb +++ b/app/models/concerns/analytics/cycle_analytics/stage.rb @@ -15,8 +15,8 @@ module Analytics validates :name, exclusion: { in: Gitlab::Analytics::CycleAnalytics::DefaultStages.names }, if: :custom? validates :start_event_identifier, presence: true validates :end_event_identifier, presence: true - validates :start_event_label, presence: true, if: :start_event_label_based? - validates :end_event_label, presence: true, if: :end_event_label_based? + validates :start_event_label_id, presence: true, if: :start_event_label_based? + validates :end_event_label_id, presence: true, if: :end_event_label_based? validate :validate_stage_event_pairs validate :validate_labels @@ -109,8 +109,8 @@ module Analytics end def validate_labels - validate_label_within_group(:start_event_label, start_event_label_id) if start_event_label_id_changed? - validate_label_within_group(:end_event_label, end_event_label_id) if end_event_label_id_changed? + validate_label_within_group(:start_event_label_id, start_event_label_id) if start_event_label_id_changed? + validate_label_within_group(:end_event_label_id, end_event_label_id) if end_event_label_id_changed? end def validate_label_within_group(association_name, label_id) |