ale*_*nco 10 ruby-on-rails-3.2
我刚刚更新到Rails 3.2并在启动WEBrick后出现以下错误:
[DEVISE] devise.registrations.reasons in yml files is deprecated, please use devise.registrations.signed_up_but_REASON instead. The default values are:
en:
devise:
registrations:
signed_up_but_unconfirmed: 'A message with a confirmation link has been sent to your email address. Please open the link to activate your account.'
signed_up_but_inactive: 'You have signed up successfully. However, we could not sign you in because your account is not yet activated.'
signed_up_but_locked: 'You have signed up successfully. However, we could not sign you in because your account is locked.'
[DEVISE] devise.registrations.inactive_signed_up in yml files is deprecated, please use devise.registrations.signed_up_but_REASON instead. The default values are:
en:
devise:
registrations:
signed_up_but_unconfirmed: 'A message with a confirmation link has been sent to your email address. Please open the link to activate your account.'
signed_up_but_inactive: 'You have signed up successfully. However, we could not sign you in because your account is not yet activated.'
signed_up_but_locked: 'You have signed up successfully. However, we could not sign you in because your account is locked.'
Run Code Online (Sandbox Code Playgroud)
在我的设计语言环境文件中,我有另一行:
registrations:
signed_up: 'Welcome! You have signed up successfully.'
inactive_signed_up: 'You have signed up successfully. However, we could not sign you in because your account is %{reason}.'
updated: 'You updated your account successfully.'
destroyed: 'Bye! Your account was successfully cancelled. We hope to see you again soon.'
reasons:
inactive: 'inactive'
unconfirmed: 'unconfirmed'
locked: 'locked'
Run Code Online (Sandbox Code Playgroud)
对不起,我是Rails的初学者.我到底需要改变什么?如何?
小智 12
我也遇到过这个问题.这似乎工作正常:
在config> locales> devise.en.yml> about about 36,将注册块更改为:
registrations:
signed_up: 'Welcome! You have signed up successfully.'
updated: 'You updated your account successfully.'
destroyed: 'Bye! Your account was successfully cancelled. We hope to see you again soon.'
signed_up_but_unconfirmed: 'A message with a confirmation link has been sent to your email address. Please open the link to activate your account.'
signed_up_but_inactive: 'You have signed up successfully. However, we could not sign you in because your account is not yet activated.'
signed_up_but_locked: 'You have signed up successfully. However, we could not sign you in because your account is locked.'
Run Code Online (Sandbox Code Playgroud)
顺便说一句:确保你删除该位:
reasons:
inactive: 'inactive'
unconfirmed: 'unconfirmed'
locked: 'locked'
Run Code Online (Sandbox Code Playgroud)
干杯,哑光
| 归档时间: |
|
| 查看次数: |
1848 次 |
| 最近记录: |