diff options
| author | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-11-11 08:44:22 +0000 |
|---|---|---|
| committer | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-11-11 08:44:22 +0000 |
| commit | d76ab1855ec68432a1b362c5d922af7235658d10 (patch) | |
| tree | e85c266c3667bcb2ce060823bce66218ae88a5a5 /lib/soap | |
| parent | da6606ef891d8498a4479cadb82e270e52b19166 (diff) | |
(임수민) 구매 피드백 수정사항들
PO 금액 표시, RFQ 품목 컬럼 추가, 스크롤 시 헤더 고정, 납기일과 SAP 한국시간, 히스토리 수정
Diffstat (limited to 'lib/soap')
| -rw-r--r-- | lib/soap/ecc/mapper/rfq-and-pr-mapper.ts | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/lib/soap/ecc/mapper/rfq-and-pr-mapper.ts b/lib/soap/ecc/mapper/rfq-and-pr-mapper.ts index cc241aa6..85fbb918 100644 --- a/lib/soap/ecc/mapper/rfq-and-pr-mapper.ts +++ b/lib/soap/ecc/mapper/rfq-and-pr-mapper.ts @@ -240,9 +240,20 @@ export function mapECCRfqItemToRfqPrItem( // 날짜 파싱 let deliveryDate: Date | null = null; - if (eccItem.LFDAT) { - const dateStr = parseSAPDateTime(eccItem.LFDAT, '000000'); - deliveryDate = dateStr; + if (eccItem.LFDAT && eccItem.LFDAT.length === 8) { + try { + // YYYYMMDD 형식을 YYYY-MM-DD로 변환 후 한국 시간 기준으로 설정 + const year = eccItem.LFDAT.substring(0, 4); + const month = eccItem.LFDAT.substring(4, 6); + const day = eccItem.LFDAT.substring(6, 8); + // 한국 시간(KST, UTC+9) 기준으로 날짜 생성 + deliveryDate = new Date(`${year}-${month}-${day}T00:00:00+09:00`); + } catch (error) { + debugError('SAP 날짜 파싱 오류', { + lfdat: eccItem.LFDAT, + error, + }); + } } const mappedData: RfqPrItemData = { |
