about summary refs log tree commit diff
path: root/app
diff options
context:
space:
mode:
authorabcang <abcang1015@gmail.com>2017-07-09 01:35:08 +0900
committerEugen Rochko <eugen@zeonfederated.com>2017-07-08 18:35:08 +0200
commit794781d1219112482e4abbc0a98683a17d170e2b (patch)
treedba9ee95fbd8bbc215ab0ef8b2229d5452e5a302 /app
parent91cacb1e8f9b2cb20a7cda2195b91d7d85c494e9 (diff)
Change account link to admin account link on report page (#4119)
Diffstat (limited to 'app')
-rw-r--r--app/views/admin/reports/show.html.haml4
-rw-r--r--app/views/authorize_follows/_card.html.haml3
2 files changed, 4 insertions, 3 deletions
diff --git a/app/views/admin/reports/show.html.haml b/app/views/admin/reports/show.html.haml
index 965b71180..44486cb42 100644
--- a/app/views/admin/reports/show.html.haml
+++ b/app/views/admin/reports/show.html.haml
@@ -4,11 +4,11 @@
 .report-accounts
   .report-accounts__item
     %strong= t('admin.reports.reported_account')
-    = render 'authorize_follows/card', account: @report.target_account
+    = render 'authorize_follows/card', account: @report.target_account, admin: true
     = render 'admin/accounts/card', account: @report.target_account
   .report-accounts__item
     %strong= t('admin.reports.reported_by')
-    = render 'authorize_follows/card', account: @report.account
+    = render 'authorize_follows/card', account: @report.account, admin: true
     = render 'admin/accounts/card', account: @report.account
 
 %p
diff --git a/app/views/authorize_follows/_card.html.haml b/app/views/authorize_follows/_card.html.haml
index 13d9c7719..e81e292ba 100644
--- a/app/views/authorize_follows/_card.html.haml
+++ b/app/views/authorize_follows/_card.html.haml
@@ -4,7 +4,8 @@
       = image_tag account.avatar.url(:original), alt: '', width: 48, height: 48, class: 'avatar'
 
     %span.display-name
-      = link_to TagManager.instance.url_for(account), class: 'detailed-status__display-name p-author h-card', target: '_blank', rel: 'noopener' do
+      - account_url = local_assigns[:admin] ? admin_account_path(account.id) : TagManager.instance.url_for(account)
+      = link_to account_url, class: 'detailed-status__display-name p-author h-card', target: '_blank', rel: 'noopener' do
         %strong.emojify= display_name(account)
         %span @#{account.acct}