Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-04-20 17:36:54 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-04-20 17:36:54 +0300
commitf61bb2a16a514b71bf33aabbbb999d6732016a24 (patch)
tree9548caa89e60b4f40b99bbd1dac030420b812aa8 /app/helpers/user_callouts_helper.rb
parent35fc54e5d261f8898e390aea7c2f5ec5fdf0539d (diff)
Add latest changes from gitlab-org/gitlab@13-11-stable-eev13.11.0-rc42
Diffstat (limited to 'app/helpers/user_callouts_helper.rb')
-rw-r--r--app/helpers/user_callouts_helper.rb13
1 files changed, 8 insertions, 5 deletions
diff --git a/app/helpers/user_callouts_helper.rb b/app/helpers/user_callouts_helper.rb
index 6a242d000ae..7a90984cd77 100644
--- a/app/helpers/user_callouts_helper.rb
+++ b/app/helpers/user_callouts_helper.rb
@@ -5,7 +5,7 @@ module UserCalloutsHelper
GKE_CLUSTER_INTEGRATION = 'gke_cluster_integration'
GCP_SIGNUP_OFFER = 'gcp_signup_offer'
SUGGEST_POPOVER_DISMISSED = 'suggest_popover_dismissed'
- SERVICE_TEMPLATES_DEPRECATED = 'service_templates_deprecated'
+ SERVICE_TEMPLATES_DEPRECATED_CALLOUT = 'service_templates_deprecated_callout'
TABS_POSITION_HIGHLIGHT = 'tabs_position_highlight'
WEBHOOKS_MOVED = 'webhooks_moved'
CUSTOMIZE_HOMEPAGE = 'customize_homepage'
@@ -41,16 +41,19 @@ module UserCalloutsHelper
!user_dismissed?(SUGGEST_POPOVER_DISMISSED)
end
- def show_service_templates_deprecated?
- !user_dismissed?(SERVICE_TEMPLATES_DEPRECATED)
+ def show_service_templates_deprecated_callout?
+ !Gitlab.com? &&
+ current_user&.admin? &&
+ Service.for_template.active.exists? &&
+ !user_dismissed?(SERVICE_TEMPLATES_DEPRECATED_CALLOUT)
end
def show_webhooks_moved_alert?
!user_dismissed?(WEBHOOKS_MOVED)
end
- def show_customize_homepage_banner?(customize_homepage)
- customize_homepage && !user_dismissed?(CUSTOMIZE_HOMEPAGE)
+ def show_customize_homepage_banner?
+ !user_dismissed?(CUSTOMIZE_HOMEPAGE)
end
def show_feature_flags_new_version?