From 3be455de723d8b14e6418dd7a3c270fe7aaa0e8a Mon Sep 17 00:00:00 2001 From: Daniel Bedeleanu Date: Wed, 22 Apr 2026 18:47:21 +0300 Subject: [PATCH] fix(6): use shared Item type from db.ts in SearchModal - Remove duplicate Item interface from SearchModal - Import Item from @/lib/db to ensure type consistency - Fixes TypeScript error with missing category/min_quantity fields --- frontend/components/inventory/SearchModal.tsx | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/frontend/components/inventory/SearchModal.tsx b/frontend/components/inventory/SearchModal.tsx index 90a3f79c..f714478f 100644 --- a/frontend/components/inventory/SearchModal.tsx +++ b/frontend/components/inventory/SearchModal.tsx @@ -2,14 +2,7 @@ import { useState, useEffect, useRef, useCallback } from 'react'; import { X, Search } from 'lucide-react'; - -interface Item { - id: number; - name: string; - part_number?: string; - barcode?: string; - quantity: number; -} +import { Item } from '@/lib/db'; interface SearchModalProps { isOpen: boolean;