Fix potential issue with json_encode() in templates
This commit is contained in:
parent
17a3781bd8
commit
357102dc6e
|
|
@ -7,7 +7,7 @@
|
|||
<?php else: ?>
|
||||
<section id="analytic-avg-time-column">
|
||||
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics) ?>' data-label="<?= t('Average time spent') ?>"></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>' data-label="<?= t('Average time spent') ?>"></div>
|
||||
|
||||
<table class="table-stripped">
|
||||
<tr>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<p class="alert"><?= t('You need at least 2 days of data to show the chart.') ?></p>
|
||||
<?php else: ?>
|
||||
<section id="analytic-burndown">
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics) ?>' data-date-format="<?= e('%%Y-%%m-%%d') ?>" data-label-total="<?= t('Total for all columns') ?>"></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>' data-date-format="<?= e('%%Y-%%m-%%d') ?>" data-label-total="<?= t('Total for all columns') ?>"></div>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<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) ?>' data-date-format="<?= e('%%Y-%%m-%%d') ?>"></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>' data-date-format="<?= e('%%Y-%%m-%%d') ?>"></div>
|
||||
</section>
|
||||
<?php endif ?>
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
<?php else: ?>
|
||||
<section id="analytic-lead-cycle-time">
|
||||
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics) ?>' data-label-cycle="<?= t('Cycle Time') ?>" data-label-lead="<?= t('Lead Time') ?>"></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>' data-label-cycle="<?= t('Cycle Time') ?>" data-label-lead="<?= t('Lead Time') ?>"></div>
|
||||
|
||||
<form method="post" class="form-inline" action="<?= $this->url->href('analytic', 'leadAndCycleTime', array('project_id' => $project['id'])) ?>" autocomplete="off">
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
<?php else: ?>
|
||||
<section id="analytic-task-repartition">
|
||||
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics) ?>'></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>'></div>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
<?php else: ?>
|
||||
<section id="analytic-user-repartition">
|
||||
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics) ?>'></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($metrics, JSON_HEX_APOS) ?>'></div>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@
|
|||
<div id="budget-chart">
|
||||
<div id="chart"
|
||||
data-date-format="<?= e('%%Y-%%m-%%d') ?>"
|
||||
data-metrics='<?= json_encode($daily_budget) ?>'
|
||||
data-labels='<?= json_encode(array('in' => t('Budget line'), 'out' => t('Expenses'), 'left' => t('Remaining'), 'value' => t('Amount'), 'date' => t('Date'), 'type' => t('Type'))) ?>'></div>
|
||||
data-metrics='<?= json_encode($daily_budget, JSON_HEX_APOS) ?>'
|
||||
data-labels='<?= json_encode(array('in' => t('Budget line'), 'out' => t('Expenses'), 'left' => t('Remaining'), 'value' => t('Amount'), 'date' => t('Date'), 'type' => t('Type')), JSON_HEX_APOS) ?>'></div>
|
||||
</div>
|
||||
<hr/>
|
||||
<table class="table-fixed table-stripped">
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@
|
|||
<?php if (! empty($tasks)): ?>
|
||||
<div
|
||||
id="gantt-chart"
|
||||
data-tasks='<?= json_encode($tasks) ?>'
|
||||
data-tasks='<?= json_encode($tasks, JSON_HEX_APOS) ?>'
|
||||
data-save-url="<?= $this->url->href('gantt', 'saveDate', array('project_id' => $project['id'])) ?>"
|
||||
data-label-start-date="<?= t('Start date:') ?>"
|
||||
data-label-end-date="<?= t('Due date:') ?>"
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
</div>
|
||||
|
||||
<h3 id="analytic-task-time-column"><?= t('Time spent into each column') ?></h3>
|
||||
<div id="chart" data-metrics='<?= json_encode($time_spent_columns) ?>' data-label="<?= t('Time spent') ?>"></div>
|
||||
<div id="chart" data-metrics='<?= json_encode($time_spent_columns, JSON_HEX_APOS) ?>' data-label="<?= t('Time spent') ?>"></div>
|
||||
<table class="table-stripped">
|
||||
<tr>
|
||||
<th><?= t('Column') ?></th>
|
||||
|
|
|
|||
Loading…
Reference in New Issue