diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-09-20 16:18:24 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-09-20 16:18:24 +0300 |
commit | 0653e08efd039a5905f3fa4f6e9cef9f5d2f799c (patch) | |
tree | 4dcc884cf6d81db44adae4aa99f8ec1233a41f55 /app/models/user_callout.rb | |
parent | 744144d28e3e7fddc117924fef88de5d9674fe4c (diff) |
Add latest changes from gitlab-org/gitlab@14-3-stable-eev14.3.0-rc42
Diffstat (limited to 'app/models/user_callout.rb')
-rw-r--r-- | app/models/user_callout.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/app/models/user_callout.rb b/app/models/user_callout.rb index 1172b2ee5e8..04bc29755f8 100644 --- a/app/models/user_callout.rb +++ b/app/models/user_callout.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true class UserCallout < ApplicationRecord - belongs_to :user + include Calloutable enum feature_name: { gke_cluster_integration: 1, @@ -15,7 +15,7 @@ class UserCallout < ApplicationRecord suggest_popover_dismissed: 9, tabs_position_highlight: 10, threat_monitoring_info: 11, # EE-only - account_recovery_regular_check: 12, # EE-only + two_factor_auth_recovery_settings_check: 12, # EE-only web_ide_alert_dismissed: 16, # no longer in use active_user_count_threshold: 18, # EE-only buy_pipeline_minutes_notification_dot: 19, # EE-only @@ -39,13 +39,8 @@ class UserCallout < ApplicationRecord terraform_notification_dismissed: 38 } - validates :user, presence: true validates :feature_name, presence: true, uniqueness: { scope: :user_id }, inclusion: { in: UserCallout.feature_names.keys } - - def dismissed_after?(dismissed_after) - dismissed_at > dismissed_after - end end |