lyndsiWilliams commented on code in PR #20852:
URL: https://github.com/apache/superset/pull/20852#discussion_r929237795
##########
superset-frontend/src/SqlLab/components/ResultSet/index.tsx:
##########
@@ -275,11 +250,19 @@ export default class ResultSet extends
React.PureComponent<
this.props.database?.allows_virtual_table_explore && (
<ExploreResultsButton
database={this.props.database}
- onClick={() => this.setState({ showSaveDatasetModal: true })}
Review Comment:
Added back in [`this
commit`](https://github.com/apache/superset/pull/20852/commits/61bdc42398bc3e8f458d1ba27536a4322b8e5097).
##########
superset-frontend/src/SqlLab/components/ResultSet/index.tsx:
##########
@@ -275,11 +250,19 @@ export default class ResultSet extends
React.PureComponent<
this.props.database?.allows_virtual_table_explore && (
<ExploreResultsButton
database={this.props.database}
- onClick={() => this.setState({ showSaveDatasetModal: true })}
+ onClick={() => {
+ // There is currently redux / state issue where sometimes
a query will have serverId
+ // and other times it will not. We need this attribute
consistently for this to work
+ // const qid = this.props?.query?.results?.query_id;
+ // if (qid) {
+ // // This will open explore using the query as
datasource
+ // window.location.href =
`/explore/?dataset_type=query&dataset_id=${qid}`;
+ // } else {
+ // this.setState({ showSaveDatasetModal: true });
+ // }
+ this.setState({ showSaveDatasetModal: true });
+ }}
/>
- // In order to use the new workflow for a query powered chart,
replace the
Review Comment:
Added back in [`this
commit`](https://github.com/apache/superset/pull/20852/commits/61bdc42398bc3e8f458d1ba27536a4322b8e5097).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]