feat: [quality] 수주처 선택 UI + client_id 연동 + 수정 저장 개선
- 수주처를 텍스트 입력에서 거래처 검색 선택으로 변경 - 수주 선택 시 거래처+모델 필터 연동 (양방향) - ProductInspection/Api에 clientId 매핑 추가 - 수정 시 새 개소 locations 필터 (NaN ID 에러 해결) - SupplierSearchModal 콜백에 id 반환 추가
This commit is contained in:
@@ -27,7 +27,7 @@ interface SupplierItem {
|
||||
interface SupplierSearchModalProps {
|
||||
open: boolean;
|
||||
onOpenChange: (open: boolean) => void;
|
||||
onSelectSupplier: (supplier: { name: string; code?: string }) => void;
|
||||
onSelectSupplier: (supplier: { id: number | string; name: string; code?: string }) => void;
|
||||
}
|
||||
|
||||
// =============================================================================
|
||||
@@ -115,7 +115,7 @@ export function SupplierSearchModal({
|
||||
}, []);
|
||||
|
||||
const handleSelect = useCallback((supplier: SupplierItem) => {
|
||||
onSelectSupplier({ name: supplier.name, code: supplier.clientCode });
|
||||
onSelectSupplier({ id: supplier.id, name: supplier.name, code: supplier.clientCode });
|
||||
}, [onSelectSupplier]);
|
||||
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user