mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 06:55:50 +00:00
fix: remove search by packageName (#2901)
This commit is contained in:
parent
ab9457c7fc
commit
741e220fd3
@ -75,14 +75,17 @@ const LocalPlugins = () => {
|
||||
|
||||
const pluginList = useMemo(() => {
|
||||
let list = filterList[filterIndex]?.list || [];
|
||||
if (debouncedSearchValue) {
|
||||
const searchLowerCaseValue = debouncedSearchValue.toLocaleLowerCase().trim();
|
||||
if (searchLowerCaseValue) {
|
||||
list = _.filter(
|
||||
list,
|
||||
(item) =>
|
||||
item.name?.includes(debouncedSearchValue) ||
|
||||
item.description?.includes(debouncedSearchValue) ||
|
||||
item.displayName?.includes(debouncedSearchValue) ||
|
||||
item.packageName?.includes(debouncedSearchValue),
|
||||
String(item.displayName || '')
|
||||
.toLocaleLowerCase()
|
||||
.includes(searchLowerCaseValue) ||
|
||||
String(item.description || '')
|
||||
.toLocaleLowerCase()
|
||||
.includes(searchLowerCaseValue),
|
||||
);
|
||||
}
|
||||
return list;
|
||||
|
Loading…
Reference in New Issue
Block a user