diff --git a/app/Services/PdfMaker/PdfMaker.php b/app/Services/PdfMaker/PdfMaker.php index 2f50f9882ddb..55c600fe4480 100644 --- a/app/Services/PdfMaker/PdfMaker.php +++ b/app/Services/PdfMaker/PdfMaker.php @@ -77,8 +77,6 @@ class PdfMaker $this->updateVariables($this->data['variables']); } - $this->processOptions(); - return $this; } diff --git a/app/Services/PdfMaker/PdfMakerUtilities.php b/app/Services/PdfMaker/PdfMakerUtilities.php index c90005e43b28..ab72d76d3745 100644 --- a/app/Services/PdfMaker/PdfMakerUtilities.php +++ b/app/Services/PdfMaker/PdfMakerUtilities.php @@ -163,144 +163,6 @@ trait PdfMakerUtilities return $element; } - public function processOptions() - { - if (!isset($this->options['all_pages_header']) || $this->options['all_pages_header'] == false) { - return; - } - - if (!isset($this->options['all_pages_footer']) || $this->options['all_pages_footer'] == false) { - return; - } - - $this->insertPrintCSS(); - $this->wrapIntoTable(); - } - - public function insertPrintCSS() - { - $css = <<<'EOT' - table.page-container { - page-break-after: always; - min-width: 100%; - } - - thead.page-header { - display: table-header-group; - } - - tfoot.page-footer { - display: table-footer-group; - } - EOT; - - $css_node = $this->document->createTextNode($css); - - $style = $this->document->getElementsByTagName('style')->item(0); - - if ($style) { - return $style->appendChild($css_node); - } - - $head = $this->document->getElementsByTagName('head')->item(0); - - if ($head) { - $style_node = $this->document->createElement('style', $css); - - return $head->appendChild($style_node); - } - - return $this; - } - - public function wrapIntoTable() - { - $markup = <<<'EOT' -
- - | -
---|
- - | -
- - | -