diff --git a/app/assets/stylesheets/participacion.scss b/app/assets/stylesheets/participacion.scss index 24f266b14..a8a31a6b0 100644 --- a/app/assets/stylesheets/participacion.scss +++ b/app/assets/stylesheets/participacion.scss @@ -16,6 +16,7 @@ // 14. Tables // 15. Social // 16. Pages +// 17. Verification // // 01. Variables @@ -126,6 +127,7 @@ h6 { } .button { + font-size: rem-calc(13); padding: rem-calc(15) rem-calc(32); } @@ -221,6 +223,11 @@ h6 { } } +.progress { + background-color: rgba(0,0,0,.06); + border: 0; +} + // 04. Header // - - - - - - - - - - - - - - - - - - - - - - - - - @@ -841,22 +848,8 @@ form { margin-right: rem-calc(12); } - .date { - - select { - float: left; - width: 25%; - } - } - .verify-account { padding-right: rem-calc(12); - - .verified { - color: $check; - font-weight: bold; - line-height: rem-calc(42); - } } } @@ -1141,7 +1134,91 @@ table { } } +// 17. Verification +// - - - - - - - - - - - - - - - - - - - - - - - - - +.verification { + min-height: 60%; + @media (min-width: $small-breakpoint) { + .left + .left { + margin-left: rem-calc(12); + } + } + .verify-account { + padding-right: rem-calc(12); + .verified { + color: $check; + font-weight: bold; + line-height: rem-calc(42); + } + } + + .date { + + select { + float: left; + width: 30%; + + @media (min-width: $small-breakpoint) { + width: 25%; + } + } + } + + .progress { + height: rem-calc(48); + + @media (min-width: $small-breakpoint) { + height: rem-calc(24); + } + + .meter { + background: #63D1C4; + } + } + + .verification-step { + font-size: rem-calc(11); + padding-top: rem-calc(10); + + @media (min-width: $small-breakpoint) { + line-height: $line-height; + padding-top: 0; + } + + &.active { + color: white; + } + + &.completed { + color: rgba(255,255,255,.5); + } + } + + .send-letter { + background: none; + color: $link; + + &:hover { + color: $link-hover; + } + } + + .button + form { + display: inline-block; + margin-left: rem-calc(12); + } + + .verification-list { + font-size: rem-calc(13); + list-style-type: none; + margin-left: 0; + + span { + display: inline-block; + } + } +} diff --git a/app/controllers/verification/letter_controller.rb b/app/controllers/verification/letter_controller.rb index 401ae0ed2..152590b20 100644 --- a/app/controllers/verification/letter_controller.rb +++ b/app/controllers/verification/letter_controller.rb @@ -26,7 +26,7 @@ class Verification::LetterController < ApplicationController def verify_phone_or_email! unless current_user.confirmed_phone? - redirect_to verified_user_path, alert: t('verification.letter.alert.unconfirmed_personal_data') + redirect_to verified_user_path, alert: t('verification.letter.alert.unconfirmed_code') end end end \ No newline at end of file diff --git a/app/views/account/show.html.erb b/app/views/account/show.html.erb index bf749bbd2..41ae068c0 100644 --- a/app/views/account/show.html.erb +++ b/app/views/account/show.html.erb @@ -1,21 +1,26 @@
<%= t("account.show.level_three_user") %>
- <% elsif current_user.level_two_verified? %> -<%= t("account.show.level_two_user") %>
- <% else %> - <%= link_to t("account.show.verify_my_account"), new_residence_path, class: 'button radius small success right' %> - <% end %> - ++ + <%= t("account.show.verified_account") %> +
+ <% elsif current_user.level_two_verified? %> + <%= link_to t("account.show.finish_verification"), new_letter_path, class: "button radius small success right" %> + <% else %> + <%= link_to t("account.show.verify_my_account"), new_residence_path, class: "button radius small success right" %> + <% end %> + +<%= @error %>
- <%= f.text_field :confirmation_code %> + <% if @error %> +<%= t("verification.verified_user.show.explanation") %>
<% if @verified_users.map(&:email).any? %> -Congratulations! You can now participate in discussions or support proposals of others.
To finish we need to verify your account completely provide you with a maximum security code, we ensure that no one is using your data on your behalf.
This requirement is essential to participate in final votes on motions. This can approach any Office of Citizen where you will verify in person, or in case you is impossible, we can send you a letter home with the code.
" + offices: "See Office of Citizen" + offices_url: "http://www.madrid.es/portales/munimadrid/es/Inicio/El-Ayuntamiento/Atencion-al-ciudadano/Oficinas-de-Atencion-al-Ciudadano?vgnextfmt=default&vgnextchannel=5b99cde2e09a4310VgnVCM1000000b205a0aRCRD" + send_letter: "Send me a letter with the code" + introduce_code: "Enter the security code" + send_code: "Send" create: flash: - success: "You will receive a letter to your home address in the next couple of days" + success: "Thank you for requesting a code maximum security in a few days we will send it to the address on your census data. Remember that you can save shipping collecting your code in any of the Office of Citizen Services." alert: failure: "We could not verify your address with the Census please try again later" alert: - unconfirmed_personal_data: 'You have not yet confirmed your personal data' + unconfirmed_code: "You have not yet enter the confirmation code" verified_user: show: - title: Available information - email_title: Emails - phone_title: Phones - use_another_phone: Use another phone + title: "Available information" + explanation: "We currently have the following data in the Census, choose where you want to send the confirmation code." + email_title: "Emails" + phone_title: "Phones" + use_another_phone: "Use another phone" form: - submit_button: Send \ No newline at end of file + submit_button: "Send code" \ No newline at end of file diff --git a/config/locales/verification.es.yml b/config/locales/verification.es.yml index 169decc9b..0865eb690 100644 --- a/config/locales/verification.es.yml +++ b/config/locales/verification.es.yml @@ -1,49 +1,59 @@ es: verification: + step_1: "1. Residencia" + step_2: "2. Código de confirmación" + step_3: "3. Verificación final" residence: new: - title: 'Verificar residencia' + title: "Verificar residencia" + document_type_label: "Tipo de documento" document_type: - spanish_id: 'DNI' - passport: 'Pasaporte' - residence_card: 'Tarjeta de residencia' - accept_terms_text: "Acepto los terminos de acceso al Padrón" - accept_terms_link: "Leer términos" - form_errors: 'evitaron verificar tu residencia' - error_verifying_census: 'El Padrón de Madrid no pudo verificar tu información. Revisa la información ó ponte en contacto con nosotros.' + spanish_id: "DNI" + passport: "Pasaporte" + residence_card: "Tarjeta de residencia" + document_number: "Número de documento" + date_of_birth: "Fecha de nacimiento" + postal_code: "Código postal" + accept_terms_text: "Acepto %{terms_url} al Padrón" + terms: "los terminos de acceso" + verify_residence: "Verificar residencia" + form_errors: "evitaron verificar tu residencia" + error_verifying_census: "El Padrón de Madrid no pudo verificar tu información. Revisa la información ó ponte en contacto con nosotros." create: flash: - success: 'Residencia verificada' + success: "Residencia verificada" alert: - verify_attemps_left: 'Has llegado al máximo número de intentos de verificar tu residencia.' - unconfirmed_residency: 'Aún no has verificado tu residencia' + verify_attemps_left: "Has llegado al máximo número de intentos de verificar tu residencia." + unconfirmed_residency: "Aún no has verificado tu residencia" sms: new: - title: Verificación de teléfono móvil - submit_button: Enviar + title: "Recibir código de confirmación" + phone: "Introduce tu teléfono móvil para recibir el código" + submit_button: "Enviar" create: flash: - success: 'Introduce el código de confirmación que te hemos enviado por mensaje de texto' + success: "Introduce el código de confirmación que te hemos enviado por mensaje de texto" edit: - title: 'Confirmación de código de seguridad' - resend_sms_text: '¿No has recibido un mensaje de texto con tu código de confirmación?' - resend_sms_link: 'Haz click aquí para volver a enviártelo' - submit_button: Enviar + title: "Confirmación de código de seguridad" + confirmation_code: "Introduce el código que has recibido en tu móvil" + resend_sms_text: "¿No has recibido un mensaje de texto con tu código de confirmación?" + resend_sms_link: "Haz click aquí para volver a enviártelo" + submit_button: "Enviar" update: - error: 'Código de confirmación incorrecto' + error: "Código de confirmación incorrecto" flash: level_three: - success: 'Código correcto. Ya eres un usuario verificado' + success: "Código correcto. Tu cuenta ya está verificada" level_two: - success: 'Código incorrecto' + success: "Código correcto" alert: - verify_attemps_left: 'Has llegado al máximo número de intentos de verificar tu teléfono.' + verify_attemps_left: "Has llegado al máximo número de intentos de verificar tu teléfono." email: show: flash: - success: 'Eres un usuario verificado' + success: "Eres un usuario verificado" alert: - failure: 'Código de verificación incorrecto' + failure: "Código de verificación incorrecto" create: flash: success: "Te hemos enviado un email de confirmación a tu cuenta: %{email}" @@ -51,21 +61,27 @@ es: failure: "Hubo un problema enviándote un email a tu cuenta" letter: new: - title: Final Verification - explanation: 'To completely verify your account we need to go to one of these offices or send you a letter with a special code to your home address' - submit_button: 'Send me a letter' + title: "Verificación Final" + explanation_html: + "¡Felicidades! Ya puedes participar en debates o apoyar propuestas de otras personas.
Para terminar de verificar tu cuenta completamente necesitamos proporcionarte un código de máxima seguridad, que nos asegure que nadie está utilizando tus datos en tu nombre.
Este requerimiento es esencial para participar en las votaciones finales de las propuestas. Para ello puedes acercarte a cualquier Oficina de Atención al Ciudadano donde te verificarán presencialmente, o en caso de que te sea imposible, podemos mandarte una carta a casa con el código.
" + offices: "Ver Oficinas de Atención al Ciudadano" + offices_url: "http://www.madrid.es/portales/munimadrid/es/Inicio/El-Ayuntamiento/Atencion-al-ciudadano/Oficinas-de-Atencion-al-Ciudadano?vgnextfmt=default&vgnextchannel=5b99cde2e09a4310VgnVCM1000000b205a0aRCRD" + send_letter: "Enviarme una carta con el código" + introduce_code: "Introduce el código de seguridad" + send_code: "Enviar" create: flash: - success: "You will receive a letter to your home address in the next couple of days" + success: "Gracias por solicitar tu código de máxima seguridad, en unos días te lo enviaremos a la dirección que figura en tus datos del padrón. Recuerda que puedes ahorrar el envío recogiendo tu código en cualquiera de las Oficinas de Atención al Ciudadano." alert: - failure: "We could not verify your address with the Census please try again later" + failure: "No podemos verificar tu dirección con el Padrón, por favor inténtalo otra vez más tarde" alert: - unconfirmed_personal_data: 'You have not yet confirmed your personal data' + unconfirmed_code: "Todavía no has introducido el código de confirmación" verified_user: show: - title: Información disponible - email_title: Emails - phone_title: Teléfonos - use_another_phone: Utilizar otro teléfono + title: "Información disponible" + explanation: "Actualmente disponemos de los siguientes datos en el Padrón, selecciona donde quieres que enviemos el código de confirmación." + email_title: "Emails" + phone_title: "Teléfonos" + use_another_phone: "Utilizar otro teléfono" form: - submit_button: Enviar \ No newline at end of file + submit_button: "Enviar código" \ No newline at end of file