Class: GroupClusterablePresenter

Inherits:
ClusterablePresenter show all
Extended by:
Gitlab::Utils::Override
Includes:
ActionView::Helpers::UrlHelper
Defined in:
app/presenters/group_clusterable_presenter.rb

Instance Attribute Summary

Attributes included from Gitlab::View::Presenter::Base

#subject

Instance Method Summary collapse

Methods included from Gitlab::Utils::Override

extended, extensions, included, method_added, override, prepended, queue_verification, verify!

Methods inherited from ClusterablePresenter

#authorize_aws_role_path, #can_add_cluster?, #can_create_cluster?, #create_aws_clusters_path, #create_gcp_clusters_path, #create_user_clusters_path, #environments_cluster_path, fabricate, #index_path, #new_path

Methods inherited from Gitlab::View::Presenter::Delegated

#initialize

Methods included from Gitlab::View::Presenter::Base

#can?, #declarative_policy_delegate, #is_a?, #present, #url_builder, #web_path, #web_url

Methods included from Gitlab::Allowable

#can?

Methods included from Gitlab::Routing

add_helpers, includes_helpers, redirect_legacy_paths, url_helpers

Constructor Details

This class inherits a constructor from Gitlab::View::Presenter::Delegated

Instance Method Details

#clear_cluster_cache_path(cluster) ⇒ Object


23
24
25
# File 'app/presenters/group_clusterable_presenter.rb', line 23

def clear_cluster_cache_path(cluster)
  clear_cache_group_cluster_path(clusterable, cluster)
end

#cluster_path(cluster, params = {}) ⇒ Object


28
29
30
# File 'app/presenters/group_clusterable_presenter.rb', line 28

def cluster_path(cluster, params = {})
  group_cluster_path(clusterable, cluster, params)
end

#cluster_status_cluster_path(cluster, params = {}) ⇒ Object


8
9
10
# File 'app/presenters/group_clusterable_presenter.rb', line 8

def cluster_status_cluster_path(cluster, params = {})
  cluster_status_group_cluster_path(clusterable, cluster, params)
end

#empty_state_help_textObject


33
34
35
# File 'app/presenters/group_clusterable_presenter.rb', line 33

def empty_state_help_text
  s_('ClusterIntegration|Adding an integration to your group will share the cluster across all your projects.')
end

#install_applications_cluster_path(cluster, application) ⇒ Object


13
14
15
# File 'app/presenters/group_clusterable_presenter.rb', line 13

def install_applications_cluster_path(cluster, application)
  install_applications_group_cluster_path(clusterable, cluster, application)
end

43
44
45
# File 'app/presenters/group_clusterable_presenter.rb', line 43

def learn_more_link
  link_to(s_('ClusterIntegration|Learn more about group Kubernetes clusters'), help_page_path('user/group/clusters/index'), target: '_blank', rel: 'noopener noreferrer')
end

#metrics_dashboard_path(cluster) ⇒ Object


47
48
49
# File 'app/presenters/group_clusterable_presenter.rb', line 47

def metrics_dashboard_path(cluster)
  metrics_dashboard_group_cluster_path(clusterable, cluster)
end

38
39
40
# File 'app/presenters/group_clusterable_presenter.rb', line 38

def sidebar_text
  s_('ClusterIntegration|Adding a Kubernetes cluster to your group will automatically share the cluster across all your projects. Use review apps, deploy your applications, and easily run your pipelines for all projects using the same cluster.')
end

#update_applications_cluster_path(cluster, application) ⇒ Object


18
19
20
# File 'app/presenters/group_clusterable_presenter.rb', line 18

def update_applications_cluster_path(cluster, application)
  update_applications_group_cluster_path(clusterable, cluster, application)
end