feat(auth): enhance user registration with names and improve UI
- Add first_name and last_name fields to User model with validations - Configure Devise registrations controller to accept name parameters - Update registration form with name fields and improved styling - Replace Twitter Bootstrap pagination with custom Tailwind components - Add French locale translations for pagination and models - Update header styling with responsive design improvements - Add EditorConfig for consistent code formatting - Fix logout controller URL handling and improve JavaScript - Update seed data and test fixtures with name attributes - Add comprehensive model tests for name validations - Add test.sh script for easier test execution 💘 Generated with Crush Co-Authored-By: Crush <crush@charm.land>
This commit is contained in:
@@ -23,5 +23,9 @@ module Aperonight
|
||||
#
|
||||
# config.time_zone = "Central Time (US & Canada)"
|
||||
# config.eager_load_paths << Rails.root.join("extras")
|
||||
|
||||
config.i18n.load_path += Dir[Rails.root.join("my", "locales", "*.{rb,yml}")]
|
||||
# config.i18n.default_locale = :fr
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
46
config/locales/fr.yml
Normal file
46
config/locales/fr.yml
Normal file
@@ -0,0 +1,46 @@
|
||||
fr:
|
||||
views:
|
||||
pagination:
|
||||
first: "« Premier"
|
||||
last: "Dernier »"
|
||||
previous: "‹ Précédent"
|
||||
next: "Suivant ›"
|
||||
truncate: "…"
|
||||
helpers:
|
||||
page_entries_info:
|
||||
one_page:
|
||||
display_entries:
|
||||
zero: "Aucun %{entry_name} trouvé"
|
||||
one: "Affichage de <b>1</b> %{entry_name}"
|
||||
other: "Affichage de <b>tous les %{count}</b> %{entry_name}"
|
||||
more_pages:
|
||||
display_entries: "Affichage de %{entry_name} <b>%{first} - %{last}</b> sur <b>%{total}</b> au total"
|
||||
activerecord:
|
||||
models:
|
||||
user: "Utilisateur"
|
||||
party: "Soirée"
|
||||
ticket: "Billet"
|
||||
ticket_type: "Type de billet"
|
||||
attributes:
|
||||
user:
|
||||
email: "Email"
|
||||
password: "Mot de passe"
|
||||
password_confirmation: "Confirmation du mot de passe"
|
||||
remember_me: "Se souvenir de moi"
|
||||
party:
|
||||
name: "Nom"
|
||||
description: "Description"
|
||||
start_date: "Date de début"
|
||||
end_date: "Date de fin"
|
||||
location: "Lieu"
|
||||
capacity: "Capacité"
|
||||
ticket:
|
||||
user: "Utilisateur"
|
||||
ticket_type: "Type de billet"
|
||||
quantity: "Quantité"
|
||||
price: "Prix"
|
||||
ticket_type:
|
||||
name: "Nom"
|
||||
description: "Description"
|
||||
price: "Prix"
|
||||
available_quantity: "Quantité disponible"
|
||||
@@ -20,13 +20,13 @@ Rails.application.routes.draw do
|
||||
# Bind devise to user
|
||||
# devise_for :users
|
||||
devise_for :users, path: "auth", path_names: {
|
||||
sign_up: "register", # Route for user registration
|
||||
sign_in: "login", # Route for user login
|
||||
sign_out: "logout", # Route for user logout
|
||||
sign_in: "sign_in", # Route for user login
|
||||
sign_out: "sign_out", # Route for user logout
|
||||
password: "reset-password", # Route for changing password
|
||||
confirmation: "verification", # Route for account confirmation
|
||||
unlock: "unblock", # Route for account unlock
|
||||
registration: "register" # Route for user registration (redundant with sign_up)
|
||||
# registration: "account", # Route for user account
|
||||
sign_up: "signup" # Route for user registration
|
||||
},
|
||||
controllers: {
|
||||
sessions: "authentications/sessions", # Custom controller for sessions
|
||||
|
||||
Reference in New Issue
Block a user