From 3c9a2a34d44aefbcd6787f825acd5a0167181e24 Mon Sep 17 00:00:00 2001 From: René 'Necoro' Neumann Date: Sun, 1 May 2016 16:08:14 +0200 Subject: Fix stat-chart layout --- static/js/kosten.js | 18 +++++++++++------- static/js/kosten.ls | 12 ++++++++---- 2 files changed, 19 insertions(+), 11 deletions(-) (limited to 'static') diff --git a/static/js/kosten.js b/static/js/kosten.js index 936e38c..7d6582c 100644 --- a/static/js/kosten.js +++ b/static/js/kosten.js @@ -26,7 +26,8 @@ weekdays: ['Sonntag', 'Montag', 'Dienstag', 'Mittwoch', 'Donnerstag', 'Freitag', 'Samstag'], rangeSelectorFrom: 'von', rangeSelectorTo: 'bis', - rangeSelectorZoom: null + rangeSelectorZoom: null, + numericSymbols: null } }); }; @@ -152,9 +153,6 @@ var x$; x$ = $(this); x$.highcharts('StockChart', { - title: { - text: null - }, credits: { enabled: false }, @@ -169,7 +167,11 @@ }, plotOptions: { series: { - stacking: 'normal' + stacking: 'normal', + marker: { + enabled: false, + radius: 2 + } } }, chart: { @@ -192,7 +194,10 @@ }, yAxis: { reversedStacks: false, - tickInterval: 250 + labels: { + x: 5, + align: 'left' + } }, series: [ { @@ -211,7 +216,6 @@ } ], tooltip: { - shared: true, formatter: function(){ var header, body, p, footer; header = "" + df('%B %Y', this.x) + "
"; diff --git a/static/js/kosten.ls b/static/js/kosten.ls index 699fcd4..ea433a4 100644 --- a/static/js/kosten.ls +++ b/static/js/kosten.ls @@ -25,6 +25,7 @@ set-lang = !-> range-selector-from: \von range-selector-to: \bis range-selector-zoom: null + numeric-symbols: null extend-date = (input) !-> if input.val! is //^ @@ -125,8 +126,7 @@ export statJS = jq !-> <-! $ \.stats .each $ @ - ..highcharts 'StockChart' do - title: text: null + ..highcharts \StockChart do credits: enabled: false range-selector: buttons: [] @@ -141,6 +141,9 @@ export statJS = jq !-> plot-options: series: stacking: \normal + marker: + enabled: false + radius: 2 chart: events: click: !-> @@ -153,7 +156,9 @@ export statJS = jq !-> min-range: month y-axis: reversed-stacks: false - tick-interval: 250 + labels: + x: 5 + align: \left series: [ # const * data: ..data \consts @@ -166,7 +171,6 @@ export statJS = jq !-> step: \left ] tooltip: - shared: true formatter: -> header = "#{df '%B %Y' @x}
" body = ["#{p.series.name}: #{p.point.y} €
" for p in @points] .join '' -- cgit v1.2.3-70-g09d2