Module: chartView

chartView

new require("chartView")() → {function}

Highcharts-extended Backbone.View
Source:
Requires:
  • module:Backbone
  • module:framework
  • module:Highcharts
Returns:
Backbone.View constructor
Type
function
Source:

Members

chartOptions :object

Chart options extensions
Type:
  • object
Properties:
Type Description
Source:

type :string

Chart type identifier
Type:
  • string
Source:

Methods

create(node, type, options) → {Object}

Creates a new highcharts instance
Parameters:
Name Type Argument Description
node String | jQuery | DOM_Element <optional>
Node selector or this.$el if undefined
type String <optional>
Chart type or "spline" if undefined
options Object <optional>
Additional options
Source:
Returns:
Highcharts instance
Type
Object

flush() → {null}

Destroys this.chart instance. View instance is still available
Source:
Returns:
null
Type
null

getWidget() → {Object}

Returns widget view link
Source:
Returns:
widget view
Type
Object

redraw(delay) → {Object}

Delayed chart redraw
Parameters:
Name Type Description
delay number delay in ms
Source:
Returns:
widget view
Type
Object

render() → {object}

Render template and append to DOM. .render() also triggers this.update()
Source:
Returns:
view current view instance
Type
object

update() → {boolean}

Updates chart state by new data
Source:
Returns:
true
Type
boolean

updateCol(arg) → {Object|Null}

Updates column type chart
Parameters:
Name Type Description
arg * Data arguments
Source:
Returns:
series updated series or null
Type
Object | Null

updatePie(arg) → {Object|Null}

Updates pie type chart
Parameters:
Name Type Description
arg * Data arguments
Source:
Returns:
series updated series or null
Type
Object | Null

updateSeries(data, index) → {Object|Null}

Sets data to chart.series specified by index
Parameters:
Name Type Description
data Array
index Number
Source:
Returns:
series updated series or null
Type
Object | Null

updateSpline(arg) → {Object|Null}

Updates spline type chart
Parameters:
Name Type Description
arg * Data arguments
Source:
Returns:
series updated series or null
Type
Object | Null