diff --git a/app/Http/Controllers/TestingPanelController.php b/app/Http/Controllers/TestingPanelController.php
index 8e36438..46818cf 100644
--- a/app/Http/Controllers/TestingPanelController.php
+++ b/app/Http/Controllers/TestingPanelController.php
@@ -24,278 +24,6 @@ class TestingPanelController extends Controller
{
//
}
-public function downloadQrPdf($palletNo)
-{
- // Generate QR code as PNG binary (adjust size as needed)
- $qrCode = new QrCode($palletNo);
- $output = new Output\Png();
- $qrBinary = $output->output($qrCode, 100); // 100px size
- $qrBase64 = base64_encode($qrBinary);
-
- // Prepare HTML with embedded QR code
- $html = '
-
-
-
-
-
-
-
-
-
- |
-
- ' . htmlspecialchars($palletNo) . '
- |
-
-
-
-
- ';
-
- $mpdf = new Mpdf([
- 'mode' => 'utf-8',
- 'format' => [60, 14],
- 'margin_left' => 0,
- 'margin_right' => 0,
- 'margin_top' => 0,
- 'margin_bottom' => 0,
- 'tempDir' => '/var/www/storage/mpdf-tmp',
- ]);
-
- $mpdf->WriteHTML($html);
- $mpdf->Output('qr-label.pdf', 'I');
- exit;
-}
-
- // public function downloadQrPdf($palletNo)
- // {
- // $qrBinary = QrCode::format('png')->size(70)->generate($palletNo); // Adjust size as needed
- // $qrBase64 = base64_encode($qrBinary);
-
- // $html = '
- //
- //
- //
- //
- //
- //
- //
- //
- //
- // |
- //
- // ' . htmlspecialchars($palletNo) . '
- // |
- //
- //
- //
- //
- // ';
-
- // $mpdf = new Mpdf([
- // 'mode' => 'utf-8',
- // 'format' => [60, 14],
- // 'margin_left' => 0,
- // 'margin_right' => 0,
- // 'margin_top' => 0,
- // 'margin_bottom' => 0,
- // ]);
-
- // $mpdf->WriteHTML($html);
- // $mpdf->Output(); // This directly flushes output as PDF
- // exit;
-
- // }
-
-
-// public function downloadQrPdf($palletNo)
-// {
-// // 1. Generate TSPL commands
-// $labelContent = <<&1";
-
-// exec($command, $output, $return_var);
-// $outputStr = implode("\n", $output);
-
-// unlink($tmpFile);
-
-// if ($return_var === 0) {
-// return "Label sent to printer!";
-// }
-// else
-// {
-// return "Failed to send label to printer. Error: " . $outputStr;
-// }
-// }
-
- // public function downloadQrPdf($palletNo)
- // {
- // // TSPL commands for test label
- // $labelContent = <<