mirror of
https://github.com/hexastack/hexabot
synced 2025-06-26 18:27:28 +00:00
fix(frontend): persist search param nlpEntity
This commit is contained in:
parent
56149999f1
commit
1818f01437
@ -80,8 +80,9 @@ const NlpEntity = () => {
|
||||
},
|
||||
});
|
||||
const [selectedNlpEntities, setSelectedNlpEntities] = useState<string[]>([]);
|
||||
const { onSearch, searchPayload } = useSearch<INlpEntity>({
|
||||
const { ref, onSearch, searchPayload } = useSearch<INlpEntity>({
|
||||
$or: ["name", "doc"],
|
||||
queryParam: { key: "search", defaultValue: "" },
|
||||
});
|
||||
const { dataGridProps: nlpEntityGrid } = useFind(
|
||||
{
|
||||
@ -224,7 +225,7 @@ const NlpEntity = () => {
|
||||
flexShrink={0}
|
||||
>
|
||||
<Grid item>
|
||||
<FilterTextfield onChange={onSearch} />
|
||||
<FilterTextfield inputRef={ref} onChange={onSearch} />
|
||||
</Grid>
|
||||
|
||||
{hasPermission(EntityType.NLP_ENTITY, PermissionAction.CREATE) ? (
|
||||
|
Loading…
Reference in New Issue
Block a user