moonsflyer 4 месяцев назад
Родитель
Сommit
c90e2c4fea
1 измененных файлов с 5 добавлено и 1 удалено
  1. 5 1
      app/common/service/GiftCardQrCodeService.php

+ 5 - 1
app/common/service/GiftCardQrCodeService.php

@@ -39,8 +39,12 @@ class GiftCardQrCodeService
             outFileLog($tempFilePath, 'qr_code', '$tempFilePath');
             // 正确的使用方式
             // 可以直接在一行中完成
+            // 分步骤设置
             $qrcode = new Generator();
-            $qrcode->size(430)->margin(2)->format('png')->generate($qrContent, $tempFilePath);
+            $qrcode->size(430);
+            $qrcode->margin(2);
+            $qrcode->format('png');
+            $qrcode->generate($qrContent, $tempFilePath);
             outFileLog($qrcode, 'qr_code', '$qrcode');
             Log::info('Regular QR code generated successfully', [
                 'cardNo' => $cardNo,