A free open source IT asset/license management system
adds getters for Continuous_Landscape_59mm_A
Godfrey Mcdbbb7250bc1
diff --git a/app/Models/Labels/CustomLabels/CustomTapeLabel.php b/app/Models/Labels/CustomLabels/CustomTapeLabel.phpindex 419125ae6f..e084382e31 100644--- a/app/Models/Labels/CustomLabels/CustomTapeLabel.php+++ b/app/Models/Labels/CustomLabels/CustomTapeLabel.php@@ -479,7 +479,12 @@ abstract class CustomTapeLabel extends Label$this->rotation = method_exists($template, 'getRotation')? (int)$template->getRotation(): $this->rotation;-+ logger()->debug('Template dimensions', [+ 'class' => get_class($template),+ 'unit' => $template->getUnit(),+ 'width' => $template->getWidth(),+ 'height' => $template->getHeight(),+ ]);return $this;}@@ -560,6 +565,11 @@ abstract class CustomTapeLabel extends Label$pa = $this->getPrintableArea();$layout = $this->buildLayout($pdf, $record, $pa);+ logger()->debug('Tape dimensions', [+ 'unit' => $this->getUnit(),+ 'width' => $this->getWidth(),+ 'height' => $this->getHeight(),+ ]);$this->render1DBarcode($pdf, $record, $layout);$this->renderLogo($pdf, $record, $layout);$this->render2DBarcode($pdf, $record, $layout);diff --git a/app/Models/Labels/Tapes/Generic/Continuous_53mm_A.php b/app/Models/Labels/Tapes/Generic/Continuous_53mm_A.phpindex 1df243d96e..1793049092 100644--- a/app/Models/Labels/Tapes/Generic/Continuous_53mm_A.php+++ b/app/Models/Labels/Tapes/Generic/Continuous_53mm_A.php@@ -78,7 +78,6 @@ class Continuous_53mm_A extends Continuous_53mm{return ['barcode_2d_size' => 44.0,- 'barcode2D_h_align' => 'C','barcode2D_v_align' => 'T','barcode2D_placement' => 'stacked',diff --git a/app/Models/Labels/Tapes/Generic/Continuous_Landscape_0_59in_A.php b/app/Models/Labels/Tapes/Generic/Continuous_Landscape_0_59in_A.phpindex 7c09590594..7fb67dd7c6 100644--- a/app/Models/Labels/Tapes/Generic/Continuous_Landscape_0_59in_A.php+++ b/app/Models/Labels/Tapes/Generic/Continuous_Landscape_0_59in_A.php@@ -16,7 +16,7 @@ class Continuous_Landscape_0_59in_A extends Continuous_Landscape_0_59inpublic function getSupport1DBarcode(){- return true;+ return false;}public function getSupport2DBarcode()@@ -39,6 +39,61 @@ class Continuous_Landscape_0_59in_A extends Continuous_Landscape_0_59inreturn false;}+ public function getBarcodeMargin(): float+ {+ return $this->barcodeMargin;+ }++ public function getLabelSize(): float+ {+ return $this->labelSize;+ }++ public function getLabelMargin(): float+ {+ return $this->labelMargin;+ }++ public function getFieldSize(): float+ {+ return $this->fieldSize;+ }++ public function getFieldMargin(): float+ {+ return $this->fieldMargin;+ }++ public function getWidth(): float+ {+ return 2.0;+ }++ public function getHeight(): float+ {+ return .59;+ }++ protected function getContentEditorConfig(): array+ {+ return [+ 'barcode_2d_size' => 12.0,+ 'barcode2D_h_align' => 'L',+ 'barcode2D_v_align' => 'T',++ 'barcode_margin' => $this->getBarcodeMargin(),++ 'field_label_font_size' => $this->getLabelSize(),+ 'field_label_margin' => $this->getLabelMargin(),++ 'field_value_font_size' => $this->getFieldSize(),+ 'field_value_margin' => $this->getFieldMargin(),++ 'text_render_mode' => 'vertical_stack',+ ];+ }++public function preparePDF($pdf){$pdf->SetAutoPageBreak(false);