mirror of https://github.com/MISP/MISP
chg: [UI] Asset loader for statistics
parent
b6aac6347a
commit
9827449a37
|
@ -2138,7 +2138,6 @@ class UsersController extends AppController
|
|||
}
|
||||
$treemap['children'][] = $newElement;
|
||||
}
|
||||
$taxonomyColourCodes = array();
|
||||
$taxonomies = array_merge(array('custom'), $taxonomies);
|
||||
if ($this->_isRest()) {
|
||||
$data = array(
|
||||
|
@ -2147,12 +2146,11 @@ class UsersController extends AppController
|
|||
);
|
||||
return $this->RestResponse->viewData($data, $this->response->type());
|
||||
} else {
|
||||
$this->set('taxonomyColourCodes', $taxonomyColourCodes);
|
||||
$this->set('taxonomies', $taxonomies);
|
||||
$this->set('flatData', $flatData);
|
||||
$this->set('treemap', $treemap);
|
||||
$this->set('tags', $tags);
|
||||
$this->layout = 'treemap';
|
||||
$this->layout = false;
|
||||
$this->render('ajax/tag_statistics_graph');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,3 +0,0 @@
|
|||
<?php
|
||||
echo $this->Html->css('treemap');
|
||||
echo $content_for_layout;
|
|
@ -1,5 +1,7 @@
|
|||
<?php
|
||||
echo $this->Html->script('d3');
|
||||
<?= $this->element('genericElements/assetLoader', [
|
||||
'css' => ['treemap'],
|
||||
'js' => ['d3', 'treemap'],
|
||||
]);
|
||||
?>
|
||||
<div id="treemapSettings">
|
||||
<div class="row">
|
||||
|
@ -25,4 +27,3 @@
|
|||
var taxonomies = <?php echo json_encode($taxonomies); ?>;
|
||||
var hiddenTaxonomies = [];
|
||||
</script>
|
||||
<?php echo $this->Html->script('treemap'); ?>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
echo $this->Html->script('d3');
|
||||
echo $this->Html->script('cal-heatmap');
|
||||
echo $this->Html->css('cal-heatmap');
|
||||
<?= $this->element('genericElements/assetLoader', [
|
||||
'css' => ['cal-heatmap'],
|
||||
'js' => ['d3', 'cal-heatmap'],
|
||||
]);
|
||||
?>
|
||||
<div class = "index">
|
||||
<h2><?php echo __('Statistics');?></h2>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
echo $this->Html->script('d3');
|
||||
echo $this->Html->script('cal-heatmap');
|
||||
echo $this->Html->css('cal-heatmap');
|
||||
<?= $this->element('genericElements/assetLoader', [
|
||||
'css' => ['cal-heatmap'],
|
||||
'js' => ['d3', 'cal-heatmap'],
|
||||
]);
|
||||
?>
|
||||
<div class = "index">
|
||||
<h2><?php echo __('Statistics');?></h2>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
echo $this->Html->script('d3');
|
||||
echo $this->Html->script('cal-heatmap');
|
||||
echo $this->Html->css('cal-heatmap');
|
||||
<?= $this->element('genericElements/assetLoader', [
|
||||
'css' => ['cal-heatmap'],
|
||||
'js' => ['d3', 'cal-heatmap'],
|
||||
]);
|
||||
?>
|
||||
<div class = "index">
|
||||
<h2><?php echo __('Statistics');?></h2>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
echo $this->Html->script('d3');
|
||||
echo $this->Html->script('cal-heatmap');
|
||||
echo $this->Html->css('cal-heatmap');
|
||||
<?= $this->element('genericElements/assetLoader', [
|
||||
'css' => ['cal-heatmap'],
|
||||
'js' => ['d3', 'cal-heatmap'],
|
||||
]);
|
||||
?>
|
||||
<div class = "index">
|
||||
<h2><?php echo __('Statistics');?></h2>
|
||||
|
|
Loading…
Reference in New Issue