Fix PDF print URL using batch_number instead of id for route model binding

This commit is contained in:
ramram1515
2026-07-03 12:16:41 +08:00
parent f4d8a1f963
commit cbe074cfb4

View File

@@ -43,7 +43,7 @@ class QrCodeBatchResource extends JsonResource
'print_url' => URL::temporarySignedRoute(
'api.v1.admin.qr-batches.print-pdf',
now()->addHours(24),
['qr_code_batch' => $this->id]
['qr_code_batch' => $this->batch_number]
),
'created_at' => $this->created_at?->toIso8601String(),
];