Переброс конфига цветов категорий графика в js-скрипт

parent 689e62f7
......@@ -12,13 +12,8 @@ $(document).ready(function(){
toggelDates = [],
//selectedCategoriesId = [],
weekDatesDataStart,
colorsActiveLines = {
'shows' : '#2CA02C',
'clicks' : '#D62728',
'transactions' : '#1F77B4',
'salemoney' : '#FF7F0E',
'admoney' : '#9467BD'
};
colorsActiveLines = $(selectorGraphChartStat).data('colors');
// Добавление впереди 0 у однозначных значений
function pad(number) {
......
......@@ -149,7 +149,7 @@ $system_link = $this->url('adm.system.actions');
<?php /* График */ ?>
<?php if ($report == 'common'): ?>
<div id="chart-graph-stat" style="height: 370px;"></div>
<div id="chart-graph-stat" style="height: 370px;" data-colors=<?= ($colors_active_lines ? json_encode($colors_active_lines) : '')?>></div>
<?php endif ?>
<?php /* Таблица */ ?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment