about summary refs log tree commit diff
path: root/app/views/admin/accounts/show.html.haml
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-11-07 19:06:44 +0100
committerGitHub <noreply@github.com>2017-11-07 19:06:44 +0100
commit1032f3994fdbd61c2f517057261ddc3559199b6b (patch)
treed039701515efc050dbf91124e8d32da2014498fb /app/views/admin/accounts/show.html.haml
parentcbbeec05be5cd0930a7be73bf673acc8d8105c12 (diff)
Add ability to disable login and mark accounts as memorial (#5615)
Fix #5597
Diffstat (limited to 'app/views/admin/accounts/show.html.haml')
-rw-r--r--app/views/admin/accounts/show.html.haml11
1 files changed, 11 insertions, 0 deletions
diff --git a/app/views/admin/accounts/show.html.haml b/app/views/admin/accounts/show.html.haml
index 1f5c8fcf5..b5ce56dbc 100644
--- a/app/views/admin/accounts/show.html.haml
+++ b/app/views/admin/accounts/show.html.haml
@@ -19,6 +19,15 @@
           %th= t('admin.accounts.email')
           %td= @account.user_email
         %tr
+          %th= t('admin.accounts.login_status')
+          %td
+            - if @account.user&.disabled?
+              = t('admin.accounts.disabled')
+              = table_link_to 'unlock', t('admin.accounts.enable'), enable_admin_account_path(@account.id), method: :post
+            - else
+              = t('admin.accounts.enabled')
+              = table_link_to 'lock', t('admin.accounts.disable'), disable_admin_account_path(@account.id), method: :post
+        %tr
           %th= t('admin.accounts.most_recent_ip')
           %td= @account.user_current_sign_in_ip
         %tr
@@ -65,6 +74,8 @@
       = link_to t('admin.accounts.reset_password'), admin_account_reset_path(@account.id), method: :create, class: 'button'
       - if @account.user&.otp_required_for_login?
         = link_to t('admin.accounts.disable_two_factor_authentication'), admin_user_two_factor_authentication_path(@account.user.id), method: :delete, class: 'button'
+      - unless @account.memorial?
+        = link_to t('admin.accounts.memorialize'), memorialize_admin_account_path(@account.id), method: :post, data: { confirm: t('admin.accounts.are_you_sure') }, class: 'button'
     - else
       = link_to t('admin.accounts.redownload'), redownload_admin_account_path(@account.id), method: :post, class: 'button'