fix: [QMS] 제품검사 성적서 렌더링 개선 (FQC + inspection_data fallback)
- InspectionModal: FQC 문서 없을 때 inspection_data JSON으로 레거시 리포트 렌더링 - InspectionReportDocument 컴포넌트 재활용 (기존 검사 페이지와 동일 포맷) - mockData: convertJudgment, mapInspectionDataToItems export 추가
This commit is contained in:
@@ -477,14 +477,14 @@ export const mockReportInspectionItems: ReportInspectionItem[] = [
|
||||
];
|
||||
|
||||
/** pass/fail → 적합/부적합 변환 */
|
||||
const convertJudgment = (value: 'pass' | 'fail' | null): '적합' | '부적합' | undefined => {
|
||||
export const convertJudgment = (value: 'pass' | 'fail' | null): '적합' | '부적합' | undefined => {
|
||||
if (value === 'pass') return '적합';
|
||||
if (value === 'fail') return '부적합';
|
||||
return undefined;
|
||||
};
|
||||
|
||||
/** 검사 데이터를 검사항목에 매핑 */
|
||||
const mapInspectionDataToItems = (
|
||||
export const mapInspectionDataToItems = (
|
||||
items: ReportInspectionItem[],
|
||||
inspectionData?: ProductInspectionData
|
||||
): ReportInspectionItem[] => {
|
||||
|
||||
Reference in New Issue
Block a user