简体   繁体   中英

What is the name of the path helper for a sign_in page in Devise?

I couldn't really find this in the documentation. Only thing I've found is a after_sign_in_path_for method. What I want though is something like sign_in_path_for(:account) so that I wouldn't have to hardcode "/account/sign_in" path in. Any ideas if Devise has this kind of thing?

this depends on the scope, if yours is 'account' then

new_account_session_path

you can see all the routes that devise creates doing a

$ rake routes

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM