summaryrefslogtreecommitdiff
path: root/app/views/users/_destroy_account.html.haml
diff options
context:
space:
mode:
authorazul <azul@riseup.net>2017-04-03 08:51:56 +0000
committerazul <azul@riseup.net>2017-04-03 08:51:56 +0000
commitd4ec87744e5eed54126c78a7d2f1154d1e8e53c0 (patch)
tree70405839cd6bbf3331c94412b4178b6399dfafa3 /app/views/users/_destroy_account.html.haml
parent552483c9e3f73952839e934374e2aa8b07681f4d (diff)
parente9bdd2aa5a0662a9fc6d5ce730e26cfd560210ba (diff)
Merge branch 'feature/clear-user' into 'master'
feature: delete user clearing username Closes #26 See merge request !34
Diffstat (limited to 'app/views/users/_destroy_account.html.haml')
-rw-r--r--app/views/users/_destroy_account.html.haml15
1 files changed, 8 insertions, 7 deletions
diff --git a/app/views/users/_destroy_account.html.haml b/app/views/users/_destroy_account.html.haml
index a2c4ddd..66a7dc2 100644
--- a/app/views/users/_destroy_account.html.haml
+++ b/app/views/users/_destroy_account.html.haml
@@ -3,14 +3,15 @@
-#
%legend
- - if @user == current_user
- = t(:destroy_my_account)
- - else
- = t(:admin_destroy_account, :username => @user.login)
+ = destroy_account_text
%p= t(:destroy_account_info)
-= destroy_btn user_path(@user), :type => "danger" do
- %i.icon-remove.icon-white
- = t(:destroy_my_account)
+= form_tag user_path(@user), method: :delete do
+ .checkbox
+ = label_tag do
+ = check_box_tag 'block_username', 1, true
+ = t(:keep_username_blocked)
+ = submit_tag destroy_account_text, class: "btn btn-danger"
+
- if @user != current_user and @user.enabled?
%legend
= t(:deactivate_account, :username => @user.login)