From 9d2333bfb154f8e515bbda6e17bcac826aad0f5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9C=A0=EB=B3=91=EC=B2=A0?= Date: Mon, 16 Mar 2026 10:47:33 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20[approval]=20=EB=AC=B8=EC=84=9C=EB=B2=88?= =?UTF-8?q?=ED=98=B8=20=EC=83=9D=EC=84=B1=20=EC=8B=9C=20=EC=82=AD=EC=A0=9C?= =?UTF-8?q?=EB=90=9C=20=EB=AC=B8=EC=84=9C=EB=8F=84=20=ED=8F=AC=ED=95=A8?= =?UTF-8?q?=ED=95=98=EC=97=AC=20=EC=A4=91=EB=B3=B5=20=EB=B0=A9=EC=A7=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - generateDocumentNumber()에서 query() → withTrashed()로 변경 - soft-deleted 결재문서 번호와의 충돌 방지 Co-Authored-By: Claude Opus 4.6 (1M context) --- app/Services/ApprovalService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Services/ApprovalService.php b/app/Services/ApprovalService.php index 419debb..456ea19 100644 --- a/app/Services/ApprovalService.php +++ b/app/Services/ApprovalService.php @@ -1536,7 +1536,7 @@ private function generateDocumentNumber(int $tenantId): string $prefix = 'AP'; $date = now()->format('Ymd'); - $lastNumber = Approval::query() + $lastNumber = Approval::withTrashed() ->where('tenant_id', $tenantId) ->where('document_number', 'like', "{$prefix}-{$date}-%") ->orderByDesc('document_number')