diff --git a/app/controllers/supporters_controller.rb b/app/controllers/supporters_controller.rb index a87eb59..7ef374a 100644 --- a/app/controllers/supporters_controller.rb +++ b/app/controllers/supporters_controller.rb @@ -12,7 +12,7 @@ class SupportersController < ApplicationController mailchimp_registration redirect_to thanks_path else - flash.now[:danger] = t '.timeout' if input_to_fast? + flash.now[:danger] = input_to_fast? ? t('.timeout') : t('input_error') render :new end end diff --git a/app/views/layouts/application.html.slim b/app/views/layouts/application.html.slim index 5c927cf..be16573 100644 --- a/app/views/layouts/application.html.slim +++ b/app/views/layouts/application.html.slim @@ -1,6 +1,9 @@ html lang="#{I18n.locale}" head - title #CH420 - #{content_for(:title)} + title + - flash.each do |type, message| + = message + | #CH420 - #{content_for(:title)} = stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true = javascript_include_tag 'application', 'data-turbolinks-track' => true = csrf_meta_tags diff --git a/config/locales/de.yml b/config/locales/de.yml index 495202a..f406215 100644 --- a/config/locales/de.yml +++ b/config/locales/de.yml @@ -1,4 +1,6 @@ de: + input_error: Deine Eingaben konnte nicht gespeichert werden. Überprüfe deine Eingaben. + welcome_email: subject: Besten Dank für deine Unterstützung! diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 39f05e9..f6c7775 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -1,4 +1,6 @@ fr: + input_error: Vos entrées ne peuvent pas être enregistrées. Vérifiez les entrées. + welcome_email: subject: Merci beaucoup pour ton soutien! diff --git a/config/locales/it.yml b/config/locales/it.yml index ac3ba9a..33366ca 100644 --- a/config/locales/it.yml +++ b/config/locales/it.yml @@ -1,4 +1,6 @@ it: + input_error: I dati immessi non potevano essere salvati. Verificare i dati immessi. + welcome_email: subject: Grazie mille per il tuo sostegno!