実現したいこと
herokuで正常にアプリを動かしたい
発生している問題・エラーメッセージ
2020-02-24T05:28:58.842253+00:00 app[web.1]: [7b46f7c6-f242-4fb2-9750-0087c479495a] ActionController::RoutingError (No route matches [GET] "/users"):
言語名
ruby on rails
試したこと
ここに問題に対して試したことを記載してください。
herokuにデプロイしたアプリがエラーが出たので,
ターミナルでheroku logsでエラーを見たところ上記のエラー文がありましたが、どこのファイルに書けば良いのかわかりません。
補足情報(FW/ツールのバージョンなど)
rake routesでは下記のようになっています
Prefix Verb URI Pattern Controller#Action
new_user_session GET /users/sign_in(.:format) devise/sessions#new
user_session POST /users/sign_in(.:format) devise/sessions#create
destroy_user_session DELETE /users/sign_out(.:format) devise/sessions#destroy
new_user_password GET /users/password/new(.:format) devise/passwords#new
edit_user_password GET /users/password/edit(.:format) devise/passwords#edit
user_password PATCH /users/password(.:format) devise/passwords#update
PUT /users/password(.:format) devise/passwords#update
POST /users/password(.:format) devise/passwords#create
cancel_user_registration GET /users/cancel(.:format) devise/registrations#cancel
new_user_registration GET /users/sign_up(.:format) devise/registrations#new
edit_user_registration GET /users/edit(.:format) devise/registrations#edit
user_registration PATCH /users(.:format) devise/registrations#update
PUT /users(.:format) devise/registrations#update
DELETE /users(.:format) devise/registrations#destroy
POST /users(.:format) devise/registrations#create
new_user_confirmation GET /users/confirmation/new(.:format) devise/confirmations#new
user_confirmation GET /users/confirmation(.:format) devise/confirmations#show
POST /users/confirmation(.:format) devise/confirmations#create
root GET / top#index
edit_user GET /users/:id/edit(.:format) users#edit
user GET /users/:id(.:format) users#show
PATCH /users/:id(.:format) users#update
PUT /users/:id(.:format) users#update
edit_group GET /groups/:id/edit(.:format) groups#edit
group GET /groups/:id(.:format) groups#show
PATCH /groups/:id(.:format) groups#update
PUT /groups/:id(.:format) groups#update
questions POST /questions(.:format) questions#create
question GET /questions/:id(.:format) questions#show
answers POST /answers(.:format) answers#create
new_answer GET /answers/new(.:format) answers#new
edit_answer GET /answers/:id/edit(.:format) answers#edit
answer PATCH /answers/:id(.:format) answers#update
PUT /answers/:id(.:format) answers#update
rails_service_blob GET /rails/active_storage/blobs/:signed_id/*filename(.:format) active_storage/blobs#show
rails_blob_representation GET /rails/active_storage/representations/:signed_blob_id/:variation_key/*filename(.:format) active_storage/representations#show
rails_disk_service GET /rails/active_storage/disk/:encoded_key/*filename(.:format) active_storage/disk#show
update_rails_disk_service PUT /rails/active_storage/disk/:encoded_token(.:format) active_storage/disk#update
rails_direct_uploads POST /rails/active_storage/direct_uploads(.:format) active_storage/direct_uploads#create
routes.rbは下記のようになってます
Rails.application.routes.draw do
devise_for :users
root to: "top#index"
resources :users, only: [:show, :edit, :update]
resources :groups, only: [:show, :edit, :update]
resources :questions, only: [:create, :show]
resources :answers, only: [:new, :create, :edit, :update]
end
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。