diff --git a/app/controllers/welcome_controller.rb b/app/controllers/welcome_controller.rb index 9211f1082..288c3ee96 100644 --- a/app/controllers/welcome_controller.rb +++ b/app/controllers/welcome_controller.rb @@ -1,7 +1,7 @@ class WelcomeController < ApplicationController skip_authorization_check - layout "devise", only: :welcome + layout "devise", only: [:welcome, :verification] def index if current_user @@ -25,5 +25,9 @@ class WelcomeController < ApplicationController render 'highlights' end + def verification + redirect_to verification_path if signed_in? + end + end diff --git a/app/views/welcome/verification.html.erb b/app/views/welcome/verification.html.erb new file mode 100644 index 000000000..13286aedc --- /dev/null +++ b/app/views/welcome/verification.html.erb @@ -0,0 +1,13 @@ +

<%= t("welcome.verification.title") %>

+ +

<%= t("welcome.verification.question", org_name: Setting["org_name"]) %>

+ +

+ <%= link_to(t("welcome.verification.i_have_an_account"), verification_path, class: "button success radius expand") %> +

+ +

+ <%= link_to(t("welcome.verification.i_dont_have_an_account"), new_user_registration_path, class: "button radius expand") %> +

+ + diff --git a/config/locales/en.yml b/config/locales/en.yml index e4c8a6280..e6064e527 100755 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -489,6 +489,11 @@ en: description: Open space for citizen proposals about the kind of city we want to live in. title: You propose signed_in_home_title: Recent activity + verification: + i_dont_have_an_account: I don't have an account + i_have_an_account: I already have an account + question: Do you already have an account in %{org_name}? + title: Account verification welcome: go_to_index: See proposals and debates title: Participate diff --git a/config/locales/es.yml b/config/locales/es.yml index 3673ea1c4..9b9cb2439 100755 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -490,6 +490,11 @@ es: description: Espacio abierto para propuestas ciudadanas sobre el tipo de ciudad en el que queremos vivir. title: Propones signed_in_home_title: Actividad reciente + verification: + i_dont_have_an_account: No tengo cuenta, quiero crear una y verificarla + i_have_an_account: Ya tengo una cuenta que quiero verificar + question: ¿Tienes ya una cuenta en %{org_name}? + title: Verificación de cuenta welcome: go_to_index: Ahora no, ver propuestas title: Empieza a participar diff --git a/config/routes.rb b/config/routes.rb index 1460e6c20..7a8a99881 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -30,7 +30,7 @@ Rails.application.routes.draw do root 'welcome#index' get '/welcome', to: 'welcome#welcome' get '/highlights', to: 'welcome#highlights', as: :highlights - + get '/cuentasegura', to: 'welcome#verification', as: :cuentasegura resources :debates do member do