Skip to content

Commit

Permalink
Post rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
mistercrunch committed Oct 27, 2017
1 parent 6e533ed commit a5a401a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion superset/assets/visualizations/horizon.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@
text-shadow: 1px 1px rgba(255, 255, 255, 0.75);
}

.horizon.main {
.horizon .slice_container {
overflow: auto;
}
9 changes: 6 additions & 3 deletions superset/assets/visualizations/horizon.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,12 @@ const horizonChart = function () {
const horizon = d3.select(this);
const step = width / data.length;

horizon.append('span').text(title);
horizon.append('span').attr('class', 'value');
horizon.append('span')
.attr('class', 'title')
.text(title);

horizon.append('span')
.attr('class', 'value');

canvas = horizon.append('canvas');

Expand Down Expand Up @@ -189,7 +193,6 @@ const horizonChart = function () {
function horizonViz(slice, payload) {
const fd = slice.formData;
const div = d3.select(slice.selector);
div.classed('main', true).style('height', slice.height());
div.selectAll('*').remove();
let extent;
if (fd.horizon_color_scale === 'overall') {
Expand Down
4 changes: 2 additions & 2 deletions superset/connectors/base/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,8 @@ def expression(self):
@property
def data(self):
attrs = (
'column_name', 'verbose_name', 'description', 'expression', 'type',
'filterable', 'groupby')
'column_name', 'verbose_name', 'description', 'expression',
'filterable', 'groupby', 'type')
return {s: getattr(self, s) for s in attrs}


Expand Down
3 changes: 0 additions & 3 deletions superset/connectors/sqla/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,9 +441,6 @@ def get_sqla_query( # sqla
metrics_exprs.append(self.get_sqla_metric(m))

metrics_dict = {m.metric_name: m for m in self.metrics}
for m in metrics:
if m not in metrics_dict:
raise Exception(_("Metric '{}' is not valid".format(m)))

timeseries_limit_metric = metrics_dict.get(timeseries_limit_metric)
if metrics_exprs:
Expand Down

0 comments on commit a5a401a

Please sign in to comment.