- $('#data_selector').jstree({
- plugins: ['checkbox'],
- checkbox: {
- three_state: false,
- whole_node: true,
- tie_selection: false,
- },
- core: {
- themes: {
- icons: false,
- stripes: true,
- },
- data: {{jstree_nodes|safe}},
- },
- });
-
- $('#data_selector').on('check_node.jstree uncheck_node.jstree', function(e, data) {
- var selected_leaves = [];
- for (var i = 0; i < data.selected.length; i++) {
- var node = data.instance.get_node(data.selected[i]);
- if (node.children.length == 0) {
- var point = {name: node.id, data: arr[node.id]};
- selected_leaves.push(point);
- }
- }
-
- $('#graph').highcharts({
- title: {
- text: 'Yardstick Graphs',
- x: -20, //center
- },
- chart: {
- marginLeft: 400,
- zoomType: 'x',
- type: 'spline',
- },
- xAxis: {
- crosshair: {
- width: 1,
- color: 'black',
- },
- title: {
- text: 'Timestamp',
- },
- categories: {{Timestamps|safe}},
- },
- yAxis: {
- crosshair: {
- width: 1,
- color: 'black',
- },
- plotLines: [{
- value: 0,
- width: 1,
- color: '#808080',
- }],
- },
- plotOptions: {
- series: {
- showCheckbox: false,
- visible: false,
- },
- },
- tooltip: {
- valueSuffix: '',
- },
- legend: {
- enabled: true,
- },
- series: selected_leaves,
- });
+ var tblMetrics = $('#tblMetrics');
+ var cnvGraph = $('#cnvGraph');
+ var divTree = $('#divTree');