Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion rd_ui/app/views/visualization-embed.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ <h3 class="panel-title">
<span class="label label-default">Updated: <span am-time-ago="queryResult.getUpdatedAt()"></span></span>

<span class="pull-right">
<a class="btn btn-default btn-xs" ng-disabled="!queryResult.getData()" query-result-link target="_self">
<a class="btn btn-default btn-xs" ng-href="/queries/{{visualization.query.id}}#{{visualization.id}}" target="_blank" tooltip="Open in re:dash">
<span class="glyphicon glyphicon-link"></span>
</a>
<a class="btn btn-default btn-xs" ng-disabled="!queryResult.getData()" query-result-link target="_self" tooltip="Download as CSV">
<span class="glyphicon glyphicon-cloud-download"></span>
</a>
</span>
Expand All @@ -29,3 +32,5 @@ <h3 class="panel-title">
</div>
</div>
</div>


2 changes: 1 addition & 1 deletion redash/handlers/embed.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def embed(query_id, visualization_id, org_slug=None):

qr = project(qr, ('data', 'id', 'retrieved_at'))
vis = project(vis, ('description', 'name', 'id', 'options', 'query', 'type', 'updated_at'))
vis['query'] = project(vis, ('created_at', 'description', 'name', 'id', 'latest_query_data_id', 'name', 'updated_at'))
vis['query'] = project(vis['query'], ('created_at', 'description', 'name', 'id', 'latest_query_data_id', 'name', 'updated_at'))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😮 oops.


return render_template("embed.html",
name=settings.NAME,
Expand Down