- [ORDER] ERP 날짜 동기화 버그 수정.
This commit is contained in:
Hyojin Ahn 2026-06-15 10:59:43 -04:00
parent b25e55d1be
commit 2c175b63cf
1 changed files with 2 additions and 2 deletions

View File

@ -3,7 +3,7 @@ class erpDailyOrderMapper
{
public static function map($payload)
{
$data = $payload['after'] ?? $payload['before'] ?? [];
$after = $payload['after'] ?? $payload['before'] ?? [];
$isDelete = strtoupper($payload['action'] ?? '') === 'DELETED';
return [
@ -19,7 +19,7 @@ class erpDailyOrderMapper
"cdoPaymentType" => $after['d_paymenttype'] ?? null,
"cdoCycle" => $after['d_cycle'] ?? null,
"cdoRate" => isset($after['d_rate']) ? (float)$after['d_rate'] : null,
"cdoStatus" => $isDelete ? 'D' : ($data['d_status'] ?? 'A'),
"cdoStatus" => $isDelete ? 'D' : ($after['d_status'] ?? 'A'),
"cdoVisitFlag" => $after['d_visit'] ?? 'N',
"cdoEstimatedQty" => isset($after['d_estquantity']) ? (float)$after['d_estquantity'] : null,
"cdoPickupAt" => ($after['d_status'] ?? '') === 'F' ? self::datetime($after['d_modifydate'] ?? null) : null,