🐛 Fix entityType handling in attribute-hooks
- Add entityType to AttributeDefinitionFilters interface - Fix queryKey type casting to use proper entityType 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
98a4f2a568
commit
68609f55ea
1 changed files with 2 additions and 1 deletions
|
|
@ -308,6 +308,7 @@ export function useMetaCategorizedAttributes(
|
|||
}
|
||||
|
||||
export interface AttributeDefinitionFilters {
|
||||
entityType?: EntityType;
|
||||
isActive?: boolean;
|
||||
metaCategory?: MetaCategory;
|
||||
grouping?: string;
|
||||
|
|
@ -332,7 +333,7 @@ export function useAttributeDefinitions(
|
|||
: filters;
|
||||
|
||||
const query = useQuery({
|
||||
queryKey: attributeKeys.list({ ...normalizedFilters, entityType: entityType as unknown as undefined }),
|
||||
queryKey: attributeKeys.list({ ...normalizedFilters, entityType }),
|
||||
queryFn: () => fetchAttributeDefinitions(entityType, normalizedFilters),
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue