You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by hu...@apache.org on 2020/11/18 03:08:45 UTC
[incubator-superset] 02/02: fix the filteroption
This is an automated email from the ASF dual-hosted git repository.
hugh pushed a commit to branch hugh/SO-1117-modal
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git
commit d3cd168ec939d13a2ec489c98b303c6c59796382
Author: hughhhh <hu...@gmail.com>
AuthorDate: Tue Nov 17 19:07:19 2020 -0800
fix the filteroption
---
superset-frontend/src/SqlLab/components/SaveDatasetModal.tsx | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/superset-frontend/src/SqlLab/components/SaveDatasetModal.tsx b/superset-frontend/src/SqlLab/components/SaveDatasetModal.tsx
index a74258f..58e821a 100644
--- a/superset-frontend/src/SqlLab/components/SaveDatasetModal.tsx
+++ b/superset-frontend/src/SqlLab/components/SaveDatasetModal.tsx
@@ -44,6 +44,10 @@ export const SaveDatasetModal: FunctionComponent<> = ({visible, onOk, onCancel,
);
};
+ const filterAutocompleteOption = (inputValue, option) => {
+ return option.value.includes(inputValue)
+ }
+
const onSelect = (data) => {
console.log('onSelect', data);
};
@@ -96,6 +100,7 @@ export const SaveDatasetModal: FunctionComponent<> = ({visible, onOk, onCancel,
onSelect={onSelect}
onSearch={onSearch}
placeholder="input here"
+ filterOption={filterAutocompleteOption}
/>
</Radio>
</Radio.Group>