Added routing to join a cluster by the UUID.
This commit is contained in:
parent
052fab1d91
commit
f122f942e3
|
@ -8,6 +8,7 @@ class CounterController < ApplicationController
|
|||
private
|
||||
|
||||
def associate!
|
||||
session[:cluster_uuid] = params[:uuid] if params[:uuid]
|
||||
redirect_to cluster_path unless valid_cluster?
|
||||
end
|
||||
end
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
Rails.application.routes.draw do
|
||||
root 'counter#show'
|
||||
|
||||
get '/cluster', to: 'cluster#new'
|
||||
get '/cluster', to: 'cluster#show'
|
||||
post '/cluster', to: 'cluster#create'
|
||||
|
||||
get '/cluster/:uuid', to: 'counter#show'
|
||||
end
|
||||
|
|
Reference in New Issue
Block a user