From ecc95c6e6c3b8d91ac813719a217ed684b23f3db Mon Sep 17 00:00:00 2001 From: Andreas <6977712+AndreasK79@users.noreply.github.com> Date: Fri, 16 Jun 2023 09:04:50 +0200 Subject: [PATCH] [QSL Labels] Added message to define and set label to use for print. --- application/controllers/Labels.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application/controllers/Labels.php b/application/controllers/Labels.php index 37ea0fea..628b4dcd 100644 --- a/application/controllers/Labels.php +++ b/application/controllers/Labels.php @@ -119,8 +119,8 @@ class Labels extends CI_Controller { 'font-size' => $label->font_size )); } else { - // Standard format - $pdf = new PDF_Label('3422'); + $this->session->set_flashdata('error', 'You need to create a label and set it to be used for print.'); + redirect('labels'); } } catch (\Throwable $th) { $this->session->set_flashdata('error', 'Something went wrong! The label could not be generated. Check label size and font size.');