Skip to content

Commit

Permalink
Getting back into a working state
Browse files Browse the repository at this point in the history
  • Loading branch information
mistercrunch committed Sep 15, 2015
1 parent 0bc2e71 commit 359a81e
Show file tree
Hide file tree
Showing 8 changed files with 315 additions and 333 deletions.
11 changes: 8 additions & 3 deletions panoramix/highchart.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,17 @@ class BaseHighchart(object):
target_div = 'chart'

@property
def javascript_cmd(self):
def json(self):
js = dumps(self.chart)
js = (
return (
js.replace('"{{TOOLTIP_FORMATTER}}"', self.tooltip_formatter)
.replace("\n", " ")
)


@property
def javascript_cmd(self):
js = self.json
if self.stockchart:
return "new Highcharts.StockChart(%s);" % js
return "new Highcharts.Chart(%s);" % js
Expand Down Expand Up @@ -83,7 +88,7 @@ def __init__(
if sort_legend_y:
if 'tooltip' not in chart:
chart['tooltip'] = {
'formatter': "{{TOOLTIP_FORMATTER}}"
#'formatter': "{{TOOLTIP_FORMATTER}}"
}
if self.zoom:
chart["zoomType"] = self.zoom
Expand Down
Loading

0 comments on commit 359a81e

Please sign in to comment.