diff --git a/pages/stats/PKPStatsHandler.php b/pages/stats/PKPStatsHandler.php index 79582831d14..eee4d595871 100644 --- a/pages/stats/PKPStatsHandler.php +++ b/pages/stats/PKPStatsHandler.php @@ -460,13 +460,17 @@ public function counterR5(array $args, Request $request): void $lastDate = CounterR5Report::getLastDate(); $templateMgr->setState([ - 'components' => [ + 'pageInitConfig' => [ $counterReportsListPanel->id => $counterReportsListPanel->getConfig(), + 'usageNotPossible' => $lastDate <= $earliestDate, + 'title' => __('manager.statistics.counterR5Reports'), + 'description' => __('manager.statistics.counterR5Reports.description'), ], ]); $templateMgr->assign([ - 'pageComponent' => 'CounterReportsPage', - 'usagePossible' => $lastDate > $earliestDate, + 'pageComponent' => 'Page', + 'pageTitle' => __('manager.statistics.counterR5Reports'), + 'pageWidth' => TemplateManager::PAGE_WIDTH_FULL, ]); $templateMgr->display('stats/counterReports.tpl'); } diff --git a/templates/stats/counterReports.tpl b/templates/stats/counterReports.tpl index ce5b9027ed2..0509d82d2f6 100644 --- a/templates/stats/counterReports.tpl +++ b/templates/stats/counterReports.tpl @@ -10,19 +10,5 @@ {extends file="layouts/backend.tpl"} {block name="page"} -

- {translate key="manager.statistics.counterR5Reports"} -

-

{translate key="manager.statistics.counterR5Reports.description"}

- {if !$usagePossible} - {translate key="manager.statistics.counterR5Reports.usageNotPossible"} - {/if} - - - - - + {/block}