・ Ruby: 2.5.7 Rails: 5.2.4 ・ Vagrant: 2.2.7 -VirtualBox: 6.1 ・ OS: macOS Catalina
The following has been implemented.
-Login function implementation
Gemfile
#Postscript
gem 'devise-i18n'
application.rb
module Bookers2Debug
  class Application < Rails::Application
    config.load_defaults 5.2
    config.i18n.default_locale = :ja #Postscript
  end
end
devise.ja.yml file$ touch config/locales/devise.ja.yml
yml:devise.ja.yml
ja:
  activerecord:
    errors:
      models:
        user:
          attributes:
            email:
              taken: "Is already in use."
              blank: "Is not entered."
              too_short: "Is%{count}Please set more than characters."
              too_long: "Is%{count}Please set it below the character."
              invalid: "Is not valid."
            password:
              taken: "Is already in use."
              blank: "Is not entered."
              too_short: "Is%{count}Please set more than characters."
              too_long: "Is%{count}Please set it below the character."
              invalid: "Is not valid."
              confirmation: "Does not match the content."
    attributes:
      user:
        current_password: "Current password"
        name:name
        email: "mail address"
        password: "password"
        password_confirmation: "Confirmation password"
        remember_me: "login automatically from now on"
        name:Full name
        sex:sex
        postcode:Postal code
        prefecture_code:Prefectures
        address_city:Municipality
        address_street:address
        address_building:Building name
    models:
      user: "user"
  devise:
    confirmations:
      new:
        resend_confirmation_instructions: "Resend account confirmation email"
    mailer:
      confirmation_instructions:
        action: "Account confirmation"
        greeting: "Welcome,%{recipient}Mr.!"
        instruction: "The following link will complete the confirmation of your email address:"
      reset_password_instructions:
        action: "Change Password"
        greeting: "Hello,%{recipient}Mr.!"
        instruction: "Someone wants to reset my password. You can reset your password at the following link."
        instruction_2: "Ignore this email if you didn't want it."
        instruction_3: "Your password will not change until you access the link above and set a new password."
      unlock_instructions:
        action: "Account unlock"
        greeting: "Hello,%{recipient}Mr.!"
        instruction: "Click the link below to unlock your account."
        message: "Your account is locked due to repeated login failures."
    passwords:
      edit:
        change_my_password: "change the password"
        change_your_password: "Change password"
        confirm_new_password: "New password for confirmation"
        new_password: "new password"
      new:
        forgot_your_password: "Did you forget your password??"
        send_me_reset_password_instructions: "Send how to reset your password"
    registrations:
      edit:
        are_you_sure: "Is it really good?"
        cancel_my_account: "Account deletion"
        currently_waiting_confirmation_for_email: "%{email}Waiting for confirmation"
        leave_blank_if_you_don_t_want_to_change_it: "If left blank, do not change"
        title: "%{resource}Edit"
        unhappy: "I don't like it"
        update: "update"
        we_need_your_current_password_to_confirm_your_changes: "Please enter your current password for the changes to take effect"
      new:
        sign_up: "account registration"
    sessions:
      new:
        sign_in: "Login"
    shared:
      links:
        back: "Return"
        didn_t_receive_confirmation_instructions: "Did you receive an account confirmation email??"
        didn_t_receive_unlock_instructions: "Have you received an email on how to unfreeze your account??"
        forgot_your_password: "Did you forget your password??"
        sign_in: "Login"
        sign_in_with_provider: "%{provider}Login with"
        sign_up: "account registration"
    unlocks:
      new:
        resend_unlock_instructions: "Resend account unfreeze method"
        Recommended Posts