lyndsiWilliams commented on code in PR #20299:
URL: https://github.com/apache/superset/pull/20299#discussion_r891781218


##########
superset-frontend/src/explore/components/controls/DatasourceControl/index.jsx:
##########
@@ -232,6 +262,20 @@ class DatasourceControl extends React.PureComponent {
       </Menu>
     );
 
+    const queryDatasourceMenu = (
+      <Menu onClick={this.handleMenuItemClick}>
+        <Menu.Item key={QUERY_PREVIEW}>{t('Query preview')}</Menu.Item>
+        <Menu.Item key={VIEW_IN_SQL_LAB}>{t('View in SQL Lab')}</Menu.Item>
+        <Menu.Item key={SAVE_AS_DATASET}>{t('Save as dataset')}</Menu.Item>
+      </Menu>
+    );
+
+    const datasourceTypeCheck =

Review Comment:
   Oh whoops, good catch! This already exists as `isValidDatasourceType` in 
`DatasourcePanel/index.tsx` here: 
https://github.com/apache/superset/blob/master/superset-frontend/src/explore/components/DatasourcePanel/index.tsx#L310-L314
   
   So I'll move/export/use that one instead.
   
   But it does include SlTable, as well as Dataset. I think it was set up that 
way to check for any of the DatasourceTypes (minus table and druid). Should I 
remove it?



-- 
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]

Reply via email to