feat: implement flash messages system with auto-dismiss notifications

- Add flash message helper and styles for consistent notifications
- Replace Devise error messages with flash-based notifications
- Add dashboard page with event statistics
- Configure SMTP settings for development and production
- Update authentication controllers to use flash messages
- Add JavaScript controller for auto-dismiss functionality
This commit is contained in:
Kevin BATAILLE
2025-08-26 18:29:56 +02:00
parent 0879b3c924
commit c226adc36c
26 changed files with 607 additions and 68 deletions

View File

@@ -60,14 +60,17 @@ Rails.application.configure do
# Set host to be used by links generated in mailer templates.
config.action_mailer.default_url_options = { host: "example.com" }
# Specify outgoing SMTP server. Remember to add smtp/* credentials via rails credentials:edit.
# config.action_mailer.smtp_settings = {
# user_name: Rails.application.credentials.dig(:smtp, :user_name),
# password: Rails.application.credentials.dig(:smtp, :password),
# address: "smtp.example.com",
# port: 587,
# authentication: :plain
# }
# Configure SMTP settings using environment variables
config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
address: ENV.fetch("SMTP_ADDRESS", "smtp.example.com"),
port: ENV.fetch("SMTP_PORT", 587),
user_name: ENV.fetch("SMTP_USERNAME", ""),
password: ENV.fetch("SMTP_PASSWORD", ""),
authentication: ENV.fetch("SMTP_AUTHENTICATION", "plain"),
domain: ENV.fetch("SMTP_DOMAIN", "example.com"),
enable_starttls_auto: ENV.fetch("SMTP_STARTTLS", true)
}
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation cannot be found).