From 0490516836b9e067612d7c385ca5591a94593501 Mon Sep 17 00:00:00 2001 From: dhanabalan Date: Fri, 26 Dec 2025 12:27:03 +0530 Subject: [PATCH] Added proper logic in sticker reprint controller --- app/Http/Controllers/ProductionStickerReprintController.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/Http/Controllers/ProductionStickerReprintController.php b/app/Http/Controllers/ProductionStickerReprintController.php index 4599c53..7bcbb53 100644 --- a/app/Http/Controllers/ProductionStickerReprintController.php +++ b/app/Http/Controllers/ProductionStickerReprintController.php @@ -24,6 +24,8 @@ class ProductionStickerReprintController extends Controller { $palletNo = urldecode($palletNo); + $qrPayload = rtrim($palletNo, '|') . '|'; + $parts = explode('|', $palletNo); $itemCode = trim($parts[0]); $serialNumberRaw = isset($parts[1]) ? trim($parts[1]) : null; @@ -79,7 +81,7 @@ class ProductionStickerReprintController extends Controller // $palletNo = preg_replace('/\/.*/', '', $palletNo); // 5. Generate QR Code (base64) - $qrCode = new QrCode($palletNo); + $qrCode = new QrCode($qrPayload); $output = new Output\Png(); $qrBinary = $output->output($qrCode, 100); // 100 = size $qrBase64 = base64_encode($qrBinary);