Fix file format in real expor

This commit is contained in:
Raphael Michel
2018-11-27 15:52:57 +01:00
parent 631307a4d5
commit b1019672b0
2 changed files with 19 additions and 28 deletions

View File

@@ -83,8 +83,6 @@ class AllTicketsPDF(BaseExporter):
continue
with language(op.order.locale):
buffer = BytesIO()
p = o._create_canvas(buffer)
layout = o.layout_map.get(
(op.item_id, op.order.sales_channel),
o.layout_map.get(
@@ -92,9 +90,7 @@ class AllTicketsPDF(BaseExporter):
o.default_layout
)
)
o._draw_page(layout, p, op, op.order)
p.save()
outbuffer = o._render_with_background(layout, buffer)
outbuffer = o._draw_page(layout, op, op.order)
merger.append(ContentFile(outbuffer.read()))
outbuffer = BytesIO()