Skip to content

Commit

Permalink
[bugfix] numeric value for date fields in table viz (#3036)
Browse files Browse the repository at this point in the history
Bug was present only when using the NOT GROUPED BY option

fixes #3027
  • Loading branch information
mistercrunch authored Jul 26, 2017
1 parent 4268513 commit 0ec9cd4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions superset/viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,12 @@ def get_data(self, df):
columns=list(df.columns),
)

def json_dumps(self, obj):
if self.form_data.get('all_columns'):
return json.dumps(obj, default=utils.json_iso_dttm_ser)
else:
return super(TableViz, self).json_dumps(obj)


class PivotTableViz(BaseViz):

Expand Down

0 comments on commit 0ec9cd4

Please sign in to comment.