From e5defd870b4fd46377dbd7793fe99f9bd0ef6c4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Tue, 4 Aug 2020 16:56:17 +0200 Subject: [PATCH] implement design interface --- app/Services/PdfMaker/Designs/Plain.php | 5 ++-- .../Designs/Utilities/DesignInterface.php | 28 +++++++++++++++++++ resources/views/pdf-designs/plain.html | 1 + 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 app/Services/PdfMaker/Designs/Utilities/DesignInterface.php diff --git a/app/Services/PdfMaker/Designs/Plain.php b/app/Services/PdfMaker/Designs/Plain.php index 4e71d91112fc..4d947f8d0aa2 100644 --- a/app/Services/PdfMaker/Designs/Plain.php +++ b/app/Services/PdfMaker/Designs/Plain.php @@ -13,9 +13,10 @@ namespace App\Services\PdfMaker\Designs; use App\Services\PdfMaker\Designs\Utilities\BuildTableHeader; +use App\Services\PdfMaker\Designs\Utilities\DesignInterface; use App\Utils\Traits\MakesInvoiceValues; -class Plain +class Plain implements DesignInterface { use MakesInvoiceValues, BuildTableHeader; @@ -65,7 +66,7 @@ class Plain ]; } - public function productTable() + public function productTable(): array { return [ 'id' => 'product-table', diff --git a/app/Services/PdfMaker/Designs/Utilities/DesignInterface.php b/app/Services/PdfMaker/Designs/Utilities/DesignInterface.php new file mode 100644 index 000000000000..07f1cf376341 --- /dev/null +++ b/app/Services/PdfMaker/Designs/Utilities/DesignInterface.php @@ -0,0 +1,28 @@ + +