summaryrefslogtreecommitdiff
path: root/app/controllers/projects/clusters_controller.rb
diff options
context:
space:
mode:
authorFilipa Lacerda <filipa@gitlab.com>2017-11-28 13:16:44 +0000
committerFilipa Lacerda <filipa@gitlab.com>2017-11-28 13:33:52 +0000
commit18967d689402d6c3c2a36c844fb90aa051a69cc1 (patch)
tree332a059d12969af3515b9f8e6351530305f9cc7a /app/controllers/projects/clusters_controller.rb
parent8796e7278ecaf5e225b586499ac856957b5fad8b (diff)
downloadgitlab-ce-18967d689402d6c3c2a36c844fb90aa051a69cc1.tar.gz
Changes after Frontend and UX review:
- Moves toggle button to a shared location - Adds tests for toggle button - Transforms Clusters class into function - Improves UX
Diffstat (limited to 'app/controllers/projects/clusters_controller.rb')
-rw-r--r--app/controllers/projects/clusters_controller.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/controllers/projects/clusters_controller.rb b/app/controllers/projects/clusters_controller.rb
index 743c4d8c0a6..68dc3f5c7ea 100644
--- a/app/controllers/projects/clusters_controller.rb
+++ b/app/controllers/projects/clusters_controller.rb
@@ -102,7 +102,8 @@ class Projects::ClustersController < Projects::ApplicationController
end
def clusters
- scope = params[:scope]&.to_sym || :all
+ @scope = params[:scope] || 'all'
+ scope = @scope&.to_sym
@clusters = ClustersFinder.new(project, current_user, scope).execute
end