You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/09/29 08:09:11 UTC

[GitHub] [superset] villebro commented on a change in pull request #16510: chore: Select component refactoring - SelectControl - Iteration 5

villebro commented on a change in pull request #16510:
URL: https://github.com/apache/superset/pull/16510#discussion_r718258113



##########
File path: superset-frontend/src/datasource/DatasourceEditor.jsx
##########
@@ -121,7 +121,12 @@ const StyledLabelWrapper = styled.div`
 const checkboxGenerator = (d, onChange) => (
   <CheckboxControl value={d} onChange={onChange} />
 );
-const DATA_TYPES = ['STRING', 'NUMERIC', 'DATETIME', 'BOOLEAN'];
+const DATA_TYPES = [
+  { value: 'STRING', label: 'STRING' },
+  { value: 'NUMERIC', label: 'NUMERIC' },
+  { value: 'DATETIME', label: 'DATETIME' },
+  { value: 'BOOLEAN', label: 'BOOLEAN' },
+];

Review comment:
       Not for this PR, but this probably shouldn't be a Select component at all, but rather a text field. These should be raw column types coming from the database, hence a typical `STRING` will be `VARCHAR(x)`, `TEXT` etc.




-- 
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: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org