madhushreeag commented on code in PR #37555:
URL: https://github.com/apache/superset/pull/37555#discussion_r2843328074


##########
superset-frontend/src/components/Datasource/components/DatasourceEditor/DatasourceEditor.tsx:
##########
@@ -2349,9 +2377,28 @@ class DatasourceEditor extends PureComponent<
                       </Button>
                     </StyledButtonWrapper>
                   </ColumnButtonWrapper>
+                  <Input.Search
+                    placeholder={t('Search columns by name')}
+                    value={this.state.columnSearchTerm}
+                    onChange={e =>
+                      this.setState({ columnSearchTerm: e.target.value })
+                    }
+                    style={{ marginBottom: 16, width: 300 }}
+                    allowClear
+                  />
                   <ColumnCollectionTable
                     className="columns-table"
-                    columns={this.state.databaseColumns}
+                    columns={
+                      this.state.columnSearchTerm
+                        ? this.state.databaseColumns.filter(col =>
+                            col.column_name
+                              ?.toLowerCase()
+                              .includes(
+                                this.state.columnSearchTerm.toLowerCase(),
+                              ),
+                          )
+                        : this.state.databaseColumns
+                    }

Review Comment:
   fixed - 
   now passing columns={this.state.databaseColumns} (full list) with filterTerm 
and filterFields for display-only filtering inside CollectionTable
                      



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