Merge pull request #244 from AyuntamientoMadrid/organization-login-226
Organization login 226
This commit is contained in:
@@ -150,6 +150,19 @@ h1, h2, h3, h4, h5, h6 {
|
||||
}
|
||||
}
|
||||
|
||||
.margin {
|
||||
margin-top: $line-height;
|
||||
margin-bottom: $line-height;
|
||||
}
|
||||
|
||||
.margin-top {
|
||||
margin-top: $line-height;
|
||||
}
|
||||
|
||||
.margin-bottom {
|
||||
margin-bottom: $line-height;
|
||||
}
|
||||
|
||||
// 04. Header
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
|
||||
@@ -494,9 +507,14 @@ footer {
|
||||
|
||||
h2 {
|
||||
clear: both;
|
||||
font-size: rem-calc(30);
|
||||
font-size: rem-calc(18);
|
||||
font-weight: bold;
|
||||
line-height: $line-height*2;
|
||||
line-height: $line-height;
|
||||
|
||||
@media (min-width: $small-breakpoint) {
|
||||
font-size: rem-calc(30);
|
||||
line-height: $line-height*2;
|
||||
}
|
||||
}
|
||||
|
||||
.back, .icon-angle-left {
|
||||
|
||||
@@ -84,6 +84,7 @@ $comment-official: rgba(70,219,145,.3);
|
||||
// 06. Responsive
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
|
||||
$small: em-calc(480);
|
||||
$small-breakpoint: em-calc(640);
|
||||
$medium-breakpoint: em-calc(1024);
|
||||
$large-breakpoint: em-calc(1440);
|
||||
|
||||
@@ -5,6 +5,9 @@ class Organizations::RegistrationsController < Devise::RegistrationsController
|
||||
end
|
||||
end
|
||||
|
||||
def success
|
||||
end
|
||||
|
||||
def create
|
||||
build_resource(sign_up_params)
|
||||
if resource.valid_with_captcha?
|
||||
@@ -17,6 +20,11 @@ class Organizations::RegistrationsController < Devise::RegistrationsController
|
||||
end
|
||||
end
|
||||
|
||||
protected
|
||||
def after_inactive_sign_up_path_for(resource)
|
||||
organizations_sign_up_success_path
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def sign_up_params
|
||||
|
||||
15
app/views/organizations/registrations/success.html.erb
Normal file
15
app/views/organizations/registrations/success.html.erb
Normal file
@@ -0,0 +1,15 @@
|
||||
<div class="auth row">
|
||||
<div class="small-12 medium-8 column small-centered">
|
||||
<div class="panel">
|
||||
<h2><%= t("devise_views.organizations.registrations.success.title") %></h2>
|
||||
<p><%= t("devise_views.organizations.registrations.success.thank_you") %></p>
|
||||
<p><%= t("devise_views.organizations.registrations.success.instructions_1_html") %></p>
|
||||
<p><%= t("devise_views.organizations.registrations.success.instructions_2_html") %></p>
|
||||
<p><%= t("devise_views.organizations.registrations.success.instructions_3_html") %></p>
|
||||
<p>
|
||||
<%= link_to t("devise_views.organizations.registrations.success.back_to_index"),
|
||||
root_path, class: "button radius small margin-top" %>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -66,6 +66,13 @@ en:
|
||||
phone_number_label: "Phone number"
|
||||
password_confirmation_label: "Confirm password"
|
||||
submit: "Sign up"
|
||||
success:
|
||||
title: "Registration of organization / collective"
|
||||
thank_you: "Thank you for registering your organization or collective in the website. Now is <b>pending verification</b>."
|
||||
instructions_1_html: "We will <b>contact you soon</b> in order to verify that you represent your collective."
|
||||
instructions_2_html: "Meanwhile, <b>review your email</b>. We have sent you a <b>confirmation link to activate your account</b>."
|
||||
instructions_3_html: "When you confirm your account will then be able to participate as a non-verified organization."
|
||||
back_to_index: "Ok, go back to index"
|
||||
sessions:
|
||||
new:
|
||||
title: "Log in"
|
||||
|
||||
@@ -66,6 +66,13 @@ es:
|
||||
phone_number_label: "Teléfono"
|
||||
password_confirmation_label: "Confirmar contraseña"
|
||||
submit: "Registrarse"
|
||||
success:
|
||||
title: "Registro de organización / colectivo"
|
||||
thank_you: "Gracias por registrar tu colectivo en la web. Ahora está <b>pendiente de verificación</b>."
|
||||
instructions_1_html: "En breve <b>nos pondremos en contacto contigo</b> para verificar que realmente representas a este colectivo."
|
||||
instructions_2_html: "Mientras <b>revisa tu correo electrónico</b>, te hemos enviado un <b>enlace para confirmar tu cuenta</b>."
|
||||
instructions_3_html: "Una vez confirmado, podrás empezar a participar como colectivo no verificado."
|
||||
back_to_index: "Entendido, volver a la página principal"
|
||||
sessions:
|
||||
new:
|
||||
title: "Entrar"
|
||||
|
||||
@@ -10,6 +10,10 @@ Rails.application.routes.draw do
|
||||
},
|
||||
skip: [:omniauth_callbacks]
|
||||
|
||||
devise_scope :organization do
|
||||
get "organizations/sign_up/success", to: "organizations/registrations#success"
|
||||
end
|
||||
|
||||
devise_scope :user do
|
||||
get :finish_signup, to: 'users/registrations#finish_signup'
|
||||
patch :do_finish_signup, to: 'users/registrations#do_finish_signup'
|
||||
|
||||
Reference in New Issue
Block a user