tab/config/routes.rb

29 lines
704 B
Ruby
Raw Normal View History

2015-09-07 09:44:48 +00:00
Rails.application.routes.draw do
devise_for :users, controllers: {
omniauth_callbacks: 'callbacks'
}
2015-09-08 11:34:29 +00:00
devise_scope :user do
delete '/sign_out', to: 'devise/sessions#destroy'
end
2017-01-11 20:18:23 +00:00
authenticated :user do
root 'pages#landing', as: :authenticated_root
end
2017-01-14 15:22:44 +00:00
root to: 'pages#sign_in_page'
2015-09-08 13:16:08 +00:00
2015-09-11 11:16:53 +00:00
resources :transactions, only: [:index, :create]
2017-01-09 14:46:43 +00:00
resources :users, only: [:index, :show] do
2017-01-09 15:22:58 +00:00
resources :requests, only: [:index], shallow: true do
2017-01-09 14:46:43 +00:00
post :confirm
post :decline
end
2017-01-09 15:22:58 +00:00
resources :notifications, only: [:index], shallow: true do
post :read
end
2017-01-09 14:46:43 +00:00
end
get 'datatables/:id' => 'datatables#transactions_for_user', as: "user_transactions"
2015-09-07 09:44:48 +00:00
end