2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-01 19:20:55 +00:00

Refactoring label printing

This commit is contained in:
Oliver Walters
2021-02-22 16:12:13 +11:00
parent caf4c293d9
commit da715d7381
7 changed files with 228 additions and 122 deletions

View File

@ -164,7 +164,7 @@ class ReportPrintMixin:
report.object_to_print = item
if debug_mode:
outputs.append(report.render_to_string(request))
outputs.append(report.render_as_string(request))
else:
outputs.append(report.render(request))

View File

@ -221,7 +221,7 @@ class ReportTemplateBase(ReportBase):
return context
def render_to_string(self, request, **kwargs):
def render_as_string(self, request, **kwargs):
"""
Render the report to a HTML stiring.