diff --git a/claudedocs/[REF] template-migration-status.md b/claudedocs/[REF] template-migration-status.md new file mode 100644 index 00000000..d688cf23 --- /dev/null +++ b/claudedocs/[REF] template-migration-status.md @@ -0,0 +1,260 @@ +# 템플릿 마이그레이션 현황 + +> 작성일: 2025-01-20 +> 목적: IntegratedListTemplate / IntegratedDetailTemplate 적용 현황 파악 + +--- + +## 📊 전체 통계 + +| 구분 | 수량 | +|------|------| +| 전체 Protected 페이지 | 203개 | +| IntegratedListTemplate 사용 | 48개 | +| IntegratedDetailTemplate 사용 | 57개 | + +--- + +## ✅ 마이그레이션 완료 + +### 리스트 페이지 (IntegratedListTemplateV2) +대부분의 리스트 페이지가 IntegratedListTemplateV2로 마이그레이션 완료. +- 필터, 테이블, 페이지네이션, 헤더 버튼 공통화 적용 + +### 상세/수정/등록 페이지 (IntegratedDetailTemplate) + +#### App 페이지 (17개) +``` +src/app/[locale]/(protected)/settings/popup-management/new/page.tsx +src/app/[locale]/(protected)/settings/popup-management/[id]/page.tsx +src/app/[locale]/(protected)/settings/accounts/new/page.tsx +src/app/[locale]/(protected)/settings/accounts/[id]/page.tsx +src/app/[locale]/(protected)/sales/client-management-sales-admin/new/page.tsx +src/app/[locale]/(protected)/sales/client-management-sales-admin/[id]/page.tsx +src/app/[locale]/(protected)/sales/quote-management/test/[id]/page.tsx +src/app/[locale]/(protected)/sales/order-management-sales/[id]/edit/page.tsx +src/app/[locale]/(protected)/sales/order-management-sales/[id]/page.tsx +src/app/[locale]/(protected)/board/board-management/new/page.tsx +src/app/[locale]/(protected)/board/board-management/[id]/page.tsx +src/app/[locale]/(protected)/master-data/process-management/new/page.tsx +src/app/[locale]/(protected)/master-data/process-management/[id]/page.tsx +src/app/[locale]/(protected)/hr/card-management/new/page.tsx +src/app/[locale]/(protected)/hr/card-management/[id]/edit/page.tsx +src/app/[locale]/(protected)/hr/card-management/[id]/page.tsx +src/app/[locale]/(protected)/construction/order/base-info/labor/[id]/page.tsx +``` + +#### 컴포넌트 (주요 40개) +``` +# 회계 +src/components/accounting/BillManagement/BillDetail.tsx +src/components/accounting/SalesManagement/SalesDetail.tsx +src/components/accounting/PurchaseManagement/PurchaseDetail.tsx +src/components/accounting/VendorLedger/VendorLedgerDetail.tsx +src/components/accounting/VendorManagement/VendorDetail.tsx +src/components/accounting/BadDebtCollection/BadDebtDetail.tsx +src/components/accounting/WithdrawalManagement/WithdrawalDetailClientV2.tsx +src/components/accounting/DepositManagement/DepositDetailClientV2.tsx + +# 영업/고객 +src/components/clients/ClientDetailClientV2.tsx +src/components/quotes/QuoteRegistrationV2.tsx +src/components/orders/OrderSalesDetailView.tsx +src/components/orders/OrderSalesDetailEdit.tsx + +# 설정 +src/components/settings/PopupManagement/PopupDetailClientV2.tsx +src/components/settings/PermissionManagement/PermissionDetail.tsx + +# 건설/프로젝트 +src/components/business/construction/contract/ContractDetailForm.tsx +src/components/business/construction/site-briefings/SiteBriefingForm.tsx +src/components/business/construction/order-management/OrderDetailForm.tsx +src/components/business/construction/handover-report/HandoverReportDetailForm.tsx +src/components/business/construction/item-management/ItemDetailClient.tsx +src/components/business/construction/estimates/EstimateDetailForm.tsx +src/components/business/construction/management/ConstructionDetailClient.tsx +src/components/business/construction/site-management/SiteDetailForm.tsx +src/components/business/construction/partners/PartnerForm.tsx +src/components/business/construction/structure-review/StructureReviewDetailForm.tsx +src/components/business/construction/issue-management/IssueDetailForm.tsx +src/components/business/construction/bidding/BiddingDetailForm.tsx +src/components/business/construction/pricing-management/PricingDetailClientV2.tsx +src/components/business/construction/labor-management/LaborDetailClientV2.tsx +src/components/business/construction/progress-billing/ProgressBillingDetailForm.tsx + +# 고객센터 +src/components/customer-center/NoticeManagement/NoticeDetail.tsx +src/components/customer-center/InquiryManagement/InquiryDetail.tsx +src/components/customer-center/EventManagement/EventDetail.tsx + +# HR +src/components/hr/EmployeeManagement/EmployeeDetail.tsx + +# 생산/물류 +src/components/production/WorkOrders/WorkOrderDetail.tsx +src/components/outbound/ShipmentManagement/ShipmentDetail.tsx +src/components/material/ReceivingManagement/ReceivingDetail.tsx +src/components/material/StockStatus/StockStatusDetail.tsx + +# 품질 +src/components/quality/InspectionManagement/InspectionDetail.tsx +``` + +--- + +## ❌ 마이그레이션 미완료 + +### App 페이지 (PageLayout 직접 사용) + +| 경로 | 유형 | 비고 | +|------|------|------| +| `sales/order-management-sales/production-orders/[id]/page.tsx` | 상세 | 생산지시 상세 | +| `sales/order-management-sales/[id]/production-order/page.tsx` | 상세 | 생산지시 | +| `boards/[boardCode]/create/page.tsx` | 등록 | 게시판 글쓰기 | +| `boards/[boardCode]/[postId]/edit/page.tsx` | 수정 | 게시판 글수정 | +| `boards/[boardCode]/[postId]/page.tsx` | 상세 | 게시판 글상세 | +| `test/popup/page.tsx` | 테스트 | 테스트 페이지 | +| `dev/editable-table/page.tsx` | 개발 | 개발용 페이지 | + +### 컴포넌트 (PageLayout 직접 사용) + +#### 회계 +``` +src/components/accounting/DailyReport/index.tsx # 일일보고서 (특수 레이아웃) +src/components/accounting/ReceivablesStatus/index.tsx # 미수금현황 (특수 레이아웃) +src/components/accounting/WithdrawalManagement/WithdrawalDetail.tsx # V2로 대체됨 +src/components/accounting/DepositManagement/DepositDetail.tsx # V2로 대체됨 +``` + +#### 설정 +``` +src/components/settings/CompanyInfoManagement/index.tsx # 회사정보 (설정 페이지) +src/components/settings/RankManagement/index.tsx # 직급관리 (설정 페이지) +src/components/settings/LeavePolicyManagement/index.tsx # 휴가정책 (설정 페이지) +src/components/settings/AccountInfoManagement/index.tsx # 계정정보 (설정 페이지) +src/components/settings/NotificationSettings/index.tsx # 알림설정 (설정 페이지) +src/components/settings/TitleManagement/index.tsx # 직책관리 (설정 페이지) +src/components/settings/WorkScheduleManagement/index.tsx # 근무일정 (설정 페이지) +src/components/settings/AttendanceSettingsManagement/index.tsx # 근태설정 (설정 페이지) +src/components/settings/PopupManagement/PopupForm.tsx # V2로 대체됨 +src/components/settings/PopupManagement/PopupDetail.tsx # V2로 대체됨 +src/components/settings/AccountManagement/AccountDetail.tsx # V2로 대체됨 +src/components/settings/PermissionManagement/PermissionDetailClient.tsx # 레거시 +src/components/settings/SubscriptionManagement/SubscriptionManagement.tsx # 구독관리 +src/components/settings/SubscriptionManagement/SubscriptionClient.tsx +``` + +#### 건설/프로젝트 +``` +src/components/business/construction/management/ProjectListClient.tsx # 리스트 (별도) +src/components/business/construction/management/ProjectDetailClient.tsx # 레거시 +src/components/business/construction/category-management/index.tsx # 카테고리 (특수) +src/components/business/construction/pricing-management/PricingDetailClient.tsx # V2로 대체됨 +src/components/business/construction/labor-management/LaborDetailClient.tsx # V2로 대체됨 +``` + +#### 게시판 +``` +src/components/board/BoardManagement/BoardForm.tsx # V2로 대체됨 +src/components/board/BoardManagement/BoardDetail.tsx # V2로 대체됨 +src/components/board/BoardDetail/index.tsx # 동적 게시판 상세 +src/components/board/BoardForm/index.tsx # 동적 게시판 폼 +``` + +#### HR +``` +src/components/hr/DepartmentManagement/index.tsx # 부서관리 (트리 구조) +src/components/hr/EmployeeManagement/EmployeeForm.tsx # 직원등록 폼 +src/components/hr/EmployeeManagement/CSVUploadPage.tsx # CSV 업로드 (특수) +``` + +#### 생산 +``` +src/components/production/ProductionDashboard/index.tsx # 대시보드 (제외) +src/components/production/WorkerScreen/index.tsx # 작업자화면 (특수 UI) +src/components/production/WorkOrders/WorkOrderCreate.tsx # 작업지시 등록 +src/components/production/WorkOrders/WorkOrderEdit.tsx # 작업지시 수정 +``` + +#### 고객센터 +``` +src/components/customer-center/InquiryManagement/InquiryForm.tsx # 문의등록 +src/components/customer-center/FAQManagement/FAQList.tsx # FAQ 리스트 +``` + +#### 기타 +``` +src/components/clients/ClientDetail.tsx # V2로 대체됨 +src/components/process-management/ProcessForm.tsx # 공정등록 +src/components/process-management/ProcessDetail.tsx # V2로 대체됨 +src/components/outbound/ShipmentManagement/ShipmentEdit.tsx # 출고수정 +src/components/outbound/ShipmentManagement/ShipmentCreate.tsx # 출고등록 +src/components/items/ItemMasterDataManagement.tsx # 품목마스터 (특수) +src/components/material/ReceivingManagement/InspectionCreate.tsx # 검수등록 +src/components/quality/InspectionManagement/InspectionCreate.tsx # 품질검사등록 +``` + +--- + +## 🚫 마이그레이션 제외 대상 + +### 대시보드/특수 페이지 +``` +src/app/[locale]/(protected)/dashboard/page.tsx # CEO 대시보드 +src/app/[locale]/(protected)/production/dashboard/page.tsx # 생산 대시보드 +src/app/[locale]/(protected)/reports/comprehensive-analysis/page.tsx # 종합분석 +src/components/business/CEODashboard/CEODashboard.tsx # CEO 대시보드 +``` + +### 레거시 파일 (_legacy 폴더) +``` +src/components/settings/AccountManagement/_legacy/AccountDetail.tsx +src/components/hr/CardManagement/_legacy/CardDetail.tsx +src/components/hr/CardManagement/_legacy/CardForm.tsx +``` + +### 테스트/개발용 +``` +src/app/[locale]/(protected)/test/popup/page.tsx +src/app/[locale]/(protected)/dev/editable-table/page.tsx +``` + +--- + +## 📋 마이그레이션 우선순위 권장 + +### 높음 (실사용 페이지) +1. `boards/[boardCode]/*` - 동적 게시판 페이지들 +2. `production/WorkOrders/WorkOrderCreate.tsx` - 작업지시 등록 +3. `production/WorkOrders/WorkOrderEdit.tsx` - 작업지시 수정 +4. `outbound/ShipmentManagement/ShipmentCreate.tsx` - 출고 등록 +5. `outbound/ShipmentManagement/ShipmentEdit.tsx` - 출고 수정 + +### 중간 (설정 페이지 - 템플릿 적용 검토 필요) +- `settings/` 하위 관리 페이지들 (트리/특수 레이아웃 많음) + +### 낮음 (V2 대체 완료) +- V2 파일이 있는 레거시 컴포넌트들 (삭제 검토) + +### 제외 +- 대시보드, 특수 UI, 테스트/개발 페이지 + +--- + +## 🔧 템플릿 수정 시 일괄 적용 범위 + +템플릿 파일 수정 시 아래 파일들에 자동 적용: + +| 템플릿 | 영향 파일 수 | +|--------|-------------| +| `IntegratedListTemplateV2` | 48개 | +| `IntegratedDetailTemplate` | 57개 | +| **합계** | **105개** | + +수정 가능 요소: +- 타이틀 위치/스타일 +- 버튼 배치/디자인 +- 입력필드 공통 스타일 +- 레이아웃 구조 +- 반응형 처리 diff --git a/src/components/outbound/ShipmentManagement/ShipmentDetail.tsx b/src/components/outbound/ShipmentManagement/ShipmentDetail.tsx index a35241c2..08156853 100644 --- a/src/components/outbound/ShipmentManagement/ShipmentDetail.tsx +++ b/src/components/outbound/ShipmentManagement/ShipmentDetail.tsx @@ -3,12 +3,12 @@ /** * 출하 상세 페이지 * API 연동 완료 (2025-12-26) + * IntegratedDetailTemplate 마이그레이션 (2025-01-20) */ import { useState, useCallback, useEffect } from 'react'; import { useRouter } from 'next/navigation'; import { - Truck, FileText, Receipt, ClipboardList, @@ -16,12 +16,9 @@ import { Printer, X, Loader2, - AlertCircle, Trash2, ArrowRight, - ChevronDown, } from 'lucide-react'; -import { ContentLoadingSpinner } from '@/components/ui/loading-spinner'; import { Button } from '@/components/ui/button'; import { Badge } from '@/components/ui/badge'; import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'; @@ -48,12 +45,6 @@ import { AlertDialogHeader, AlertDialogTitle, } from '@/components/ui/alert-dialog'; -import { - DropdownMenu, - DropdownMenuContent, - DropdownMenuItem, - DropdownMenuTrigger, -} from '@/components/ui/dropdown-menu'; import { DialogDescription, DialogFooter, @@ -62,7 +53,8 @@ import { import { Input } from '@/components/ui/input'; import { Label } from '@/components/ui/label'; import { VisuallyHidden } from '@radix-ui/react-visually-hidden'; -import { PageLayout } from '@/components/organisms/PageLayout'; +import { IntegratedDetailTemplate } from '@/components/templates/IntegratedDetailTemplate'; +import { shipmentConfig } from './shipmentConfig'; import { getShipmentById, deleteShipment, updateShipmentStatus } from './actions'; import { SHIPMENT_STATUS_LABELS, @@ -111,7 +103,7 @@ export function ShipmentDetail({ id }: ShipmentDetailProps) { // API 데이터 상태 const [detail, setDetail] = useState(null); const [isLoading, setIsLoading] = useState(true); - const [error, setError] = useState(null); + const [_error, setError] = useState(null); // API 데이터 로드 const loadData = useCallback(async () => { @@ -241,480 +233,475 @@ export function ShipmentDetail({ id }: ShipmentDetailProps) { ); - // 로딩 상태 표시 - if (isLoading) { - return ( - - - - ); - } - - // 에러 상태 표시 - if (error || !detail) { - return ( - -
- -

{error || '데이터를 찾을 수 없습니다.'}

- -
-
- ); - } - // 수정/삭제 가능 여부 (scheduled, ready 상태에서만) - const canEdit = detail.status === 'scheduled' || detail.status === 'ready'; - const canDelete = detail.status === 'scheduled' || detail.status === 'ready'; + const canEdit = detail ? (detail.status === 'scheduled' || detail.status === 'ready') : false; + const canDelete = detail ? (detail.status === 'scheduled' || detail.status === 'ready') : false; + + // 헤더 액션 버튼 렌더링 + const renderHeaderActions = useCallback(() => { + if (!detail) return null; + + return ( +
+ {/* 문서 미리보기 버튼 */} + + + + {canDelete && ( + <> +
+ + + )} + {/* 상태 변경 버튼 */} + {STATUS_TRANSITIONS[detail.status] && ( + <> +
+ + + )} +
+ ); + }, [detail, canDelete, handleOpenStatusDialog]); + + // 컨텐츠 렌더링 + const renderViewContent = useCallback(() => { + if (!detail) return null; + + return ( +
+ {/* 출고 정보 */} + + + 출고 정보 + + +
+ {renderInfoField('출고번호', detail.shipmentNo)} + {renderInfoField('출고예정일', detail.scheduledDate)} + {renderInfoField('로트번호', detail.lotNo)} + {renderInfoField( + '출고상태', + + {SHIPMENT_STATUS_LABELS[detail.status]} + + )} + {renderInfoField( + '출고 우선순위', + + {PRIORITY_LABELS[detail.priority]} + + )} + {renderInfoField( + '배송방식', + + {DELIVERY_METHOD_LABELS[detail.deliveryMethod]} + + )} + {renderInfoField( + '입금확인', + detail.depositConfirmed ? ( + + + 확인됨 + + ) : ( + 미확인 + ) + )} + {renderInfoField( + '세금계산서', + detail.invoiceIssued ? ( + + + 발행됨 + + ) : ( + 미발행 + ) + )} + {renderInfoField('거래처 등급', detail.customerGrade)} + {renderInfoField( + '출하가능', + detail.canShip ? ( + + + 가능 + + ) : ( + + + 불가 + + ) + )} + {renderInfoField('상차담당자', detail.loadingManager || '-')} + {renderInfoField( + '상차완료', + detail.loadingCompleted ? ( + + + 완료 ({detail.loadingCompleted}) + + ) : ( + - + ) + )} + {renderInfoField('등록자', detail.registrant || '-')} +
+
+
+ + {/* 발주처/배송 정보 */} + + + 발주처/배송 정보 + + +
+ {renderInfoField('발주처', detail.customerName)} + {renderInfoField('현장명', detail.siteName)} + {renderInfoField('배송주소', detail.deliveryAddress, 'md:col-span-2')} + {renderInfoField('인수자', detail.receiver || '-')} + {renderInfoField('연락처', detail.receiverContact || '-')} +
+
+
+ + {/* 출고 품목 */} + + + 출고 품목 + + + + + + No + 품목코드 + 품목명 + 층/M호 + 규격 + 수량 + LOT번호 + + + + {detail.products.map((product) => ( + + {product.no} + {product.itemCode} + {product.itemName} + {product.floorUnit} + {product.specification} + {product.quantity} + {product.lotNo} + + ))} + +
+
+
+ + {/* 배차 정보 */} + + + 배차 정보 + + +
+ {renderInfoField('배송방식', DELIVERY_METHOD_LABELS[detail.deliveryMethod])} + {renderInfoField('물류사', detail.logisticsCompany || '-')} + {renderInfoField('차량 톤수', detail.vehicleTonnage || '-')} + {renderInfoField('운송비', detail.shippingCost !== undefined ? `${detail.shippingCost.toLocaleString()}원` : '-')} +
+
+
+ + {/* 차량/운전자 정보 */} + + + 차량/운전자 정보 + + +
+ {renderInfoField('차량번호', detail.vehicleNo || '-')} + {renderInfoField('운전자', detail.driverName || '-')} + {renderInfoField('운전자 연락처', detail.driverContact || '-')} +
+
+
+ + {/* 비고 */} + {detail.remarks && ( + + + 비고 + + +

{detail.remarks}

+
+
+ )} +
+ ); + }, [detail]); return ( - -
- {/* 헤더 */} -
-
- -

출하 상세

-
-
- {/* 문서 미리보기 버튼 */} - - - -
- - {canEdit && ( - - )} - {canDelete && ( - - )} - {/* 상태 변경 버튼 */} - {STATUS_TRANSITIONS[detail.status] && ( - <> -
- - - )} -
-
+ <> + - {/* 메인 콘텐츠 */} -
- {/* 출고 정보 */} - - - 출고 정보 - - -
- {renderInfoField('출고번호', detail.shipmentNo)} - {renderInfoField('출고예정일', detail.scheduledDate)} - {renderInfoField('로트번호', detail.lotNo)} - {renderInfoField( - '출고상태', - - {SHIPMENT_STATUS_LABELS[detail.status]} - - )} - {renderInfoField( - '출고 우선순위', - - {PRIORITY_LABELS[detail.priority]} - - )} - {renderInfoField( - '배송방식', - - {DELIVERY_METHOD_LABELS[detail.deliveryMethod]} - - )} - {renderInfoField( - '입금확인', - detail.depositConfirmed ? ( - - - 확인됨 - - ) : ( - 미확인 - ) - )} - {renderInfoField( - '세금계산서', - detail.invoiceIssued ? ( - - - 발행됨 - - ) : ( - 미발행 - ) - )} - {renderInfoField('거래처 등급', detail.customerGrade)} - {renderInfoField( - '출하가능', - detail.canShip ? ( - - - 가능 - - ) : ( - - - 불가 - - ) - )} - {renderInfoField('상차담당자', detail.loadingManager || '-')} - {renderInfoField( - '상차완료', - detail.loadingCompleted ? ( - - - 완료 ({detail.loadingCompleted}) - - ) : ( - - - ) - )} - {renderInfoField('등록자', detail.registrant || '-')} -
-
-
+ {/* 문서 미리보기 다이얼로그 - 작업일지 모달 패턴 적용 */} + setPreviewDocument(null)}> + + {/* 접근성을 위한 숨겨진 타이틀 */} + + + {previewDocument === 'shipping' && '출고증'} + {previewDocument === 'transaction' && '거래명세서'} + {previewDocument === 'delivery' && '납품확인서'} + + - {/* 발주처/배송 정보 */} - - - 발주처/배송 정보 - - -
- {renderInfoField('발주처', detail.customerName)} - {renderInfoField('현장명', detail.siteName)} - {renderInfoField('배송주소', detail.deliveryAddress, 'md:col-span-2')} - {renderInfoField('인수자', detail.receiver || '-')} - {renderInfoField('연락처', detail.receiverContact || '-')} -
-
-
- - {/* 출고 품목 */} - - - 출고 품목 - - - - - - No - 품목코드 - 품목명 - 층/M호 - 규격 - 수량 - LOT번호 - - - - {detail.products.map((product) => ( - - {product.no} - {product.itemCode} - {product.itemName} - {product.floorUnit} - {product.specification} - {product.quantity} - {product.lotNo} - - ))} - -
-
-
- - {/* 배차 정보 */} - - - 배차 정보 - - -
- {renderInfoField('배송방식', DELIVERY_METHOD_LABELS[detail.deliveryMethod])} - {renderInfoField('물류사', detail.logisticsCompany || '-')} - {renderInfoField('차량 톤수', detail.vehicleTonnage || '-')} - {renderInfoField('운송비', detail.shippingCost !== undefined ? `${detail.shippingCost.toLocaleString()}원` : '-')} -
-
-
- - {/* 차량/운전자 정보 */} - - - 차량/운전자 정보 - - -
- {renderInfoField('차량번호', detail.vehicleNo || '-')} - {renderInfoField('운전자', detail.driverName || '-')} - {renderInfoField('운전자 연락처', detail.driverContact || '-')} -
-
-
- - {/* 비고 */} - {detail.remarks && ( - - - 비고 - - -

{detail.remarks}

-
-
- )} - -
- - {/* 문서 미리보기 다이얼로그 - 작업일지 모달 패턴 적용 */} - setPreviewDocument(null)}> - - {/* 접근성을 위한 숨겨진 타이틀 */} - - - {previewDocument === 'shipping' && '출고증'} - {previewDocument === 'transaction' && '거래명세서'} + {/* 모달 헤더 - 작업일지 스타일 (인쇄 시 숨김) */} +
+
+ + {previewDocument === 'shipping' && '출고증 미리보기'} + {previewDocument === 'transaction' && '거래명세서 미리보기'} {previewDocument === 'delivery' && '납품확인서'} - - - - {/* 모달 헤더 - 작업일지 스타일 (인쇄 시 숨김) */} -
-
- - {previewDocument === 'shipping' && '출고증 미리보기'} - {previewDocument === 'transaction' && '거래명세서 미리보기'} - {previewDocument === 'delivery' && '납품확인서'} - - - {detail.customerName} - - - ({detail.shipmentNo}) - -
-
- - -
+ + {detail && ( + <> + + {detail.customerName} + + + ({detail.shipmentNo}) + + + )}
+
+ + +
+
- {/* 문서 본문 - 흰색 카드 형태 (인쇄 시 이 영역만 출력) */} + {/* 문서 본문 - 흰색 카드 형태 (인쇄 시 이 영역만 출력) */} + {detail && (
{previewDocument === 'shipping' && } {previewDocument === 'transaction' && } {previewDocument === 'delivery' && }
- -
+ )} + + - {/* 삭제 확인 다이얼로그 */} - - - - 출하 정보 삭제 - - 출하번호 {detail.shipmentNo}을(를) 삭제하시겠습니까? -
- 이 작업은 되돌릴 수 없습니다. -
-
- - 취소 - - {isDeleting ? ( - <> - - 삭제 중... - - ) : ( - '삭제' - )} - - -
-
- - {/* 상태 변경 다이얼로그 */} - - - - 출하 상태 변경 - - {detail.status && targetStatus && ( - - - {SHIPMENT_STATUS_LABELS[detail.status]} - - - - {SHIPMENT_STATUS_LABELS[targetStatus]} - - - )} - - - -
- {/* 출하대기로 변경 시 - 상차 시간 */} - {targetStatus === 'ready' && ( -
- - - setStatusFormData((prev) => ({ ...prev, loadingTime: e.target.value })) - } - /> -
- )} - - {/* 배송중으로 변경 시 - 차량/운전자 정보 */} - {targetStatus === 'shipping' && ( + {/* 삭제 확인 다이얼로그 */} + + + + 출하 정보 삭제 + + 출하번호 {detail?.shipmentNo}을(를) 삭제하시겠습니까? +
+ 이 작업은 되돌릴 수 없습니다. +
+
+ + 취소 + + {isDeleting ? ( <> -
- - - setStatusFormData((prev) => ({ ...prev, vehicleNo: e.target.value })) - } - /> -
-
- - - setStatusFormData((prev) => ({ ...prev, driverName: e.target.value })) - } - /> -
-
- - - setStatusFormData((prev) => ({ ...prev, driverContact: e.target.value })) - } - /> -
+ + 삭제 중... + ) : ( + '삭제' )} +
+
+
+
- {/* 배송완료로 변경 시 - 도착 확인 시간 */} - {targetStatus === 'completed' && ( + {/* 상태 변경 다이얼로그 */} + + + + 출하 상태 변경 + + {detail?.status && targetStatus && ( + + + {SHIPMENT_STATUS_LABELS[detail.status]} + + + + {SHIPMENT_STATUS_LABELS[targetStatus]} + + + )} + + + +
+ {/* 출하대기로 변경 시 - 상차 시간 */} + {targetStatus === 'ready' && ( +
+ + + setStatusFormData((prev) => ({ ...prev, loadingTime: e.target.value })) + } + /> +
+ )} + + {/* 배송중으로 변경 시 - 차량/운전자 정보 */} + {targetStatus === 'shipping' && ( + <>
- + - setStatusFormData((prev) => ({ ...prev, confirmedArrival: e.target.value })) + setStatusFormData((prev) => ({ ...prev, vehicleNo: e.target.value })) } />
- )} -
+
+ + + setStatusFormData((prev) => ({ ...prev, driverName: e.target.value })) + } + /> +
+
+ + + setStatusFormData((prev) => ({ ...prev, driverContact: e.target.value })) + } + /> +
+ + )} - - - - -
-
-
- + {/* 배송완료로 변경 시 - 도착 확인 시간 */} + {targetStatus === 'completed' && ( +
+ + + setStatusFormData((prev) => ({ ...prev, confirmedArrival: e.target.value })) + } + /> +
+ )} +
+ + + + + + + + ); }