Skip to content

Commit

Permalink
Added setFilter(), containerID and getFilter() to (#1360)
Browse files Browse the repository at this point in the history
mock slice object in exploreV2

 - filter_box in exploreV2 was broken because containerID and
   getFilter() were not defined in the mock of slice object
  • Loading branch information
vera-liu authored Nov 4, 2016
1 parent ea18979 commit 98afc3e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions caravel/assets/javascripts/explorev2/components/ChartContainer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ class ChartContainer extends React.Component {

getMockedSliceObject() {
return {
containerId: this.props.containerId,

jsonEndpoint: () => this.props.jsonEndpoint,

container: {
Expand Down Expand Up @@ -62,6 +64,16 @@ class ChartContainer extends React.Component {

selector: this.state.selector,

setFilter: () => {
// set filter according to data in store
// used in FilterBox.onChange()
},

getFilters: () => (
// return filter objects from viz.formData
{}
),

done: () => {
// finished rendering callback
},
Expand Down

0 comments on commit 98afc3e

Please sign in to comment.