Use components to render charts

This commit is contained in:
Frederic Guillot
2016-11-21 22:50:57 -05:00
parent a3bb27109d
commit 8976f4d15c
22 changed files with 306 additions and 306 deletions

View File

@@ -5,9 +5,10 @@
<?php if (! $display_graph): ?>
<p class="alert"><?= t('You need at least 2 days of data to show the chart.') ?></p>
<?php else: ?>
<section id="analytic-cfd">
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>' data-date-format="<?= e('%%Y-%%m-%%d') ?>"></div>
</section>
<?= $this->app->component('chart-cumulative-flow', array(
'metrics' => $metrics,
'dateFormat' => e('%%Y-%%m-%%d'),
)) ?>
<?php endif ?>
<hr/>