moves user deletion link to a partial

This commit is contained in:
Juanjo Bazán
2016-04-08 11:38:58 +02:00
committed by Juanjo Bazán
parent ce477273da
commit e4e87bf548
4 changed files with 18 additions and 18 deletions

View File

@@ -14,13 +14,4 @@
<%= f.submit t("management.document_verifications.verify"), class: "button success" %> <%= f.submit t("management.document_verifications.verify"), class: "button success" %>
<% end %> <% end %>
<%= render 'management/users/erase_user_account' %>
<%= link_to t("management.document_verifications.erase_account_link"), "#", class: "delete js-toggle-link", data: { "toggle-selector" => "#erase-account-form" } %>
<div id="erase-account-form" style="display:none">
<div class="callout alert medium-6">
<%= t("management.document_verifications.erase_warning") %>
</div>
<%= link_to t("management.document_verifications.erase_submit"), erase_management_users_path, method: :delete, class: "button alert", data: { confirm: t("management.document_verifications.erase_account_confirm") } %>
</div>

View File

@@ -0,0 +1,9 @@
<%= link_to t("management.users.erase_account_link"), "#", class: "delete js-toggle-link", data: { "toggle-selector" => "#erase-account-form" } %>
<div id="erase-account-form" style="display:none">
<div class="callout alert medium-6">
<%= t("management.users.erase_warning") %>
</div>
<%= link_to t("management.users.erase_submit"), erase_management_users_path, method: :delete, class: "button alert", data: { confirm: t("management.users.erase_account_confirm") } %>
</div>

View File

@@ -24,10 +24,6 @@ en:
title: User management title: User management
under_age: You must be over 16 to verify your account. under_age: You must be over 16 to verify your account.
verify: Verify verify: Verify
erase_account_link: Delete user
erase_account_confirm: Are you sure you want to erase the account? This action can not be undone
erase_warning: This action can not be undone. Please make sure you want to erase this account.
erase_submit: Delete account
email_label: Email email_label: Email
email_verifications: email_verifications:
already_verified: This user account is already verified. already_verified: This user account is already verified.
@@ -90,3 +86,7 @@ en:
create_user_success_html: We have sent an email to the email address <b>%{email}</b> in order to verify that it belongs to this user. It contains a link they have to click. Then they will have to set their access password before being able to log in to the website create_user_success_html: We have sent an email to the email address <b>%{email}</b> in order to verify that it belongs to this user. It contains a link they have to click. Then they will have to set their access password before being able to log in to the website
erased_notice: User account deleted. erased_notice: User account deleted.
erased_by_manager: "Deleted by manager: %{manager}" erased_by_manager: "Deleted by manager: %{manager}"
erase_account_link: Delete user
erase_account_confirm: Are you sure you want to erase the account? This action can not be undone
erase_warning: This action can not be undone. Please make sure you want to erase this account.
erase_submit: Delete account

View File

@@ -24,10 +24,6 @@ es:
title: Gestión de usuarios title: Gestión de usuarios
under_age: Debes ser mayor de 16 años para verificar tu cuenta. under_age: Debes ser mayor de 16 años para verificar tu cuenta.
verify: Verificar usuario verify: Verificar usuario
erase_account_link: Borrar cuenta
erase_account_confirm: ¿Seguro que quieres borrar a este usuario? Esta acción no se puede deshacer
erase_warning: Esta acción no se puede deshacer. Por favor asegurese de que quiere eliminar esta cuenta.
erase_submit: Borrar cuenta
email_label: Email email_label: Email
email_verifications: email_verifications:
already_verified: Esta cuenta de usuario ya está verificada. already_verified: Esta cuenta de usuario ya está verificada.
@@ -90,3 +86,7 @@ es:
create_user_success_html: Hemos enviado un correo electrónico a <b>%{email}</b> para verificar que es suya. El correo enviado contiene un link que el usuario deberá pulsar. Entonces podrá seleccionar una clave de acceso, y entrar en la web de participación. create_user_success_html: Hemos enviado un correo electrónico a <b>%{email}</b> para verificar que es suya. El correo enviado contiene un link que el usuario deberá pulsar. Entonces podrá seleccionar una clave de acceso, y entrar en la web de participación.
erased_notice: Cuenta de usuario borrada. erased_notice: Cuenta de usuario borrada.
erased_by_manager: "Borrada por el manager: %{manager}" erased_by_manager: "Borrada por el manager: %{manager}"
erase_account_link: Borrar cuenta
erase_account_confirm: ¿Seguro que quieres borrar a este usuario? Esta acción no se puede deshacer
erase_warning: Esta acción no se puede deshacer. Por favor asegurese de que quiere eliminar esta cuenta.
erase_submit: Borrar cuenta