Skip to content

Commit a42e092

Browse files
authored
Add printToPDF function
1 parent a4605f0 commit a42e092

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/System.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,12 @@ public function print(string $html, Printer $printer = null): void
4949
'printer' => $printer->name ?? '',
5050
]);
5151
}
52+
53+
public function printToPDF(string $html, $path = null): void
54+
{
55+
$this->client->post('system/print-to-pdf', [
56+
'html' => $html,
57+
'path' => $path ?? '',
58+
]);
59+
}
5260
}

0 commit comments

Comments
 (0)