2020-06-21 21:29:25 +02:00
|
|
|
<?php
|
2021-09-06 11:17:25 +02:00
|
|
|
// $Parsedown = new Parsedown();
|
|
|
|
// echo $Parsedown->text($md);
|
|
|
|
?>
|
|
|
|
|
2021-09-07 09:59:36 +02:00
|
|
|
<h2><?= __('Home') ?></h2>
|
2021-09-06 11:17:25 +02:00
|
|
|
<div class="row">
|
|
|
|
<?php foreach ($statistics as $modelName => $statistics): ?>
|
|
|
|
<div class="col-sm-6 col-md-4 col-l-3 col-xl-2 mb-2">
|
|
|
|
<?php
|
2021-09-07 09:59:36 +02:00
|
|
|
$exploded = explode('.', $modelName);
|
|
|
|
$modelForDisplay = $exploded[count($exploded)-1];
|
|
|
|
$panelTitle = $this->Html->link(
|
|
|
|
h($modelForDisplay),
|
|
|
|
$this->Url->build([
|
|
|
|
'controller' => $modelForDisplay,
|
|
|
|
'action' => 'index',
|
|
|
|
]),
|
|
|
|
['class' => 'text-white']
|
|
|
|
);
|
2021-09-06 11:17:25 +02:00
|
|
|
echo $this->element('widgets/highlight-panel', [
|
2021-09-07 09:59:36 +02:00
|
|
|
'titleHtml' => $panelTitle,
|
2021-09-06 11:17:25 +02:00
|
|
|
'number' => $statistics['amount'],
|
|
|
|
'variation' => $statistics['variation'] ?? '',
|
|
|
|
'chartData' => $statistics['timeline'] ?? []
|
|
|
|
]);
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
<?php endforeach ?>
|
2021-09-17 17:12:33 +02:00
|
|
|
</div>
|