rails route inline action code example
Example 1: get and to rails
@patient = Patient.find(params[:id])
Example 2: root route in rails
root :to => "pages#show", :id => '1'
Example 3: rails resources only
resources :controller_name, only: [:create, :new]