debian-mirror-gitlab/app/models/user_callout_enums.rb

26 lines
784 B
Ruby
Raw Normal View History

2019-02-15 15:39:39 +05:30
# frozen_string_literal: true
module UserCalloutEnums
# Returns the `Hash` to use for the `feature_name` enum in the `UserCallout`
# model.
#
# This method is separate from the `UserCallout` model so that it can be
# extended by EE.
2019-09-04 21:01:54 +05:30
#
# If you are going to add new items to this hash, check that you're not going
2019-12-04 20:38:33 +05:30
# to conflict with EE-only values: https://gitlab.com/gitlab-org/gitlab/blob/master/ee/app/models/ee/user_callout_enums.rb
2019-02-15 15:39:39 +05:30
def self.feature_names
{
gke_cluster_integration: 1,
gcp_signup_offer: 2,
2019-09-04 21:01:54 +05:30
cluster_security_warning: 3,
2020-01-01 13:55:28 +05:30
suggest_popover_dismissed: 9,
2020-04-08 14:13:33 +05:30
tabs_position_highlight: 10,
2020-04-22 19:07:51 +05:30
webhooks_moved: 13,
admin_integrations_moved: 15
2019-02-15 15:39:39 +05:30
}
end
end
2019-12-04 20:38:33 +05:30
UserCalloutEnums.prepend_if_ee('EE::UserCalloutEnums')