Merge remote-tracking branch 'parent/main' into upstream-20241113

This commit is contained in:
KMY 2024-11-13 08:17:38 +09:00
commit 910eafda63
177 changed files with 1625 additions and 659 deletions

View file

@ -16,7 +16,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: @time_period.last,
href: admin_accounts_path(origin: 'local'),
href: current_user.can?(:manage_users) ? admin_accounts_path(origin: 'local') : nil,
label: t('admin.dashboard.new_users'),
measure: 'new_users',
start_at: @time_period.first
@ -24,7 +24,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: @time_period.last,
href: admin_accounts_path(origin: 'local'),
href: current_user.can?(:manage_users) ? admin_accounts_path(origin: 'local') : nil,
label: t('admin.dashboard.active_users'),
measure: 'active_users',
start_at: @time_period.first
@ -39,7 +39,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: @time_period.last,
href: admin_reports_path,
href: current_user.can?(:manage_reports) ? admin_reports_path : nil,
label: t('admin.dashboard.opened_reports'),
measure: 'opened_reports',
start_at: @time_period.first
@ -47,7 +47,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: @time_period.last,
href: admin_reports_path(resolved: '1'),
href: current_user.can?(:manage_reports) ? admin_reports_path(resolved: '1') : nil,
label: t('admin.dashboard.resolved_reports'),
measure: 'resolved_reports',
start_at: @time_period.first

View file

@ -7,7 +7,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: period_end_at,
href: admin_accounts_path(origin: 'remote', by_domain: instance_domain),
href: current_user.can?(:manage_users) ? admin_accounts_path(origin: 'remote', by_domain: instance_domain) : nil,
label: t('admin.instances.dashboard.instance_accounts_measure'),
measure: 'instance_accounts',
params: { domain: instance_domain },
@ -43,7 +43,7 @@
.dashboard__item
= react_admin_component :counter,
end_at: period_end_at,
href: admin_reports_path(by_target_domain: instance_domain),
href: current_user.can?(:manage_reports) ? admin_reports_path(by_target_domain: instance_domain) : nil,
label: t('admin.instances.dashboard.instance_reports_measure'),
measure: 'instance_reports',
params: { domain: instance_domain },