diff options
| author | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-12-08 03:02:42 +0000 |
|---|---|---|
| committer | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-12-08 03:02:42 +0000 |
| commit | c0e1cc06e0c67cb4a941889a3d63d312d1fb8fce (patch) | |
| tree | 99dc529ed88d762808dc571d4095dc880e1bef02 /lib/bidding/list/biddings-table-columns.tsx | |
| parent | 4a8d125cf60254417d4e2ca75a967ff08cc8567e (diff) | |
(최겸) 구매 입찰계약 수정, 입찰기간수정
Diffstat (limited to 'lib/bidding/list/biddings-table-columns.tsx')
| -rw-r--r-- | lib/bidding/list/biddings-table-columns.tsx | 31 |
1 files changed, 25 insertions, 6 deletions
diff --git a/lib/bidding/list/biddings-table-columns.tsx b/lib/bidding/list/biddings-table-columns.tsx index 62d4dbe7..602bcbb9 100644 --- a/lib/bidding/list/biddings-table-columns.tsx +++ b/lib/bidding/list/biddings-table-columns.tsx @@ -257,21 +257,40 @@ export function getBiddingsColumns({ setRowAction }: GetColumnsProps): ColumnDef id: "submissionPeriod", header: ({ column }) => <DataTableColumnHeaderSimple column={column} title="입찰서제출기간" />, cell: ({ row }) => { + const status = row.original.status + + // 입찰생성 또는 결재진행중 상태일 때는 특별 메시지 표시 + if (status === 'bidding_generated') { + return ( + <div className="text-xs text-orange-600 font-medium"> + 입찰 등록중입니다 + </div> + ) + } + + if (status === 'approval_pending') { + return ( + <div className="text-xs text-blue-600 font-medium"> + 결재 진행중입니다 + </div> + ) + } + const startDate = row.original.submissionStartDate const endDate = row.original.submissionEndDate - + if (!startDate || !endDate) return <span className="text-muted-foreground">-</span> - + const startObj = new Date(startDate) const endObj = new Date(endDate) - // UI 표시용 KST 변환 - const formatKst = (d: Date) => new Date(d.getTime() + 9 * 60 * 60 * 1000).toISOString().slice(0, 16).replace('T', ' ') - + // 입력값 기반: 저장된 UTC 값 그대로 표시 (타임존 가감 없음) + const formatValue = (d: Date) => d.toISOString().slice(0, 16).replace('T', ' ') + return ( <div className="text-xs"> <div> - {formatKst(startObj)} ~ {formatKst(endObj)} + {formatValue(startObj)} ~ {formatValue(endObj)} </div> </div> ) |
