修改打印pdf数据
This commit is contained in:
@@ -52,5 +52,8 @@ class JikimoPrinting(models.AbstractModel):
|
||||
"""
|
||||
打印PDF
|
||||
"""
|
||||
if isinstance(pdf_data, str):
|
||||
pdf_data = pdf_data.encode()
|
||||
|
||||
printer = self.env['printing.printer'].get_default()
|
||||
printer.print_document(report=None, content = pdf_data, doc_format='pdf')
|
||||
Reference in New Issue
Block a user