eschutho commented on a change in pull request #11755:
URL:
https://github.com/apache/incubator-superset/pull/11755#discussion_r537944660
##########
File path: superset-frontend/src/SqlLab/components/ResultSet.tsx
##########
@@ -173,8 +438,43 @@ export default class ResultSet extends React.PureComponent<
if (this.props.cache && this.props.query.cached) {
({ data } = this.state);
}
+
+ // Added compute logic to stop user from being able to Save & Explore
+ const {
+ saveDatasetRadioBtnState,
+ newSaveDatasetName,
+ datasetToOverwrite,
+ saveModalAutocompleteValue,
+ shouldOverwriteDataSet,
+ userDatasetOptions,
+ showSaveDatasetModal,
+ } = this.state;
+ const disableSaveAndExploreBtn =
+ (saveDatasetRadioBtnState === 1 && newSaveDatasetName.length === 0) ||
+ (saveDatasetRadioBtnState === 2 &&
Review comment:
do you want to use the enum `DatasetRadioState` here?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]