feat: service deleting and rest categories placeholders

This commit is contained in:
2024-10-09 02:03:52 +03:00
parent dea1221016
commit 891b6cff9f
9 changed files with 41 additions and 21 deletions

View File

@@ -16,7 +16,7 @@ type RestProps = {
};
type Props = Omit<ObjectSelectProps<ServiceSchema>, "data"> & RestProps;
const ServiceSelectNew: FC<Props> = (props: Props) => {
const { services } = useServicesList();
const { services } = useServicesList({ withPlaceholders: false });
const data = props.filterType
? services.filter(service => service.serviceType === props.filterType)
: services;
@@ -28,10 +28,10 @@ const ServiceSelectNew: FC<Props> = (props: Props) => {
return {
...option,
items: option.items.filter((item: ComboboxItem) =>
item.label.toLowerCase().includes(search.toLowerCase())
item.label.toLowerCase().includes(search.toLowerCase()),
),
};
}
},
);
};
return (