Skip to content

Commit

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

fixes apache#3027
  • Loading branch information
mistercrunch committed Jul 26, 2017
1 parent 95509f2 commit 8b5ac64
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 8b5ac64

Please sign in to comment.