|
|
|
@ -8,6 +8,7 @@ from django.template import RequestContext |
|
|
|
from django.http import HttpResponse |
|
|
|
from django.http import HttpResponse |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# TODO: merge with src/commons/xls/xls_to_response.py => common def |
|
|
|
def pdf_to_response(content, filename=None): |
|
|
|
def pdf_to_response(content, filename=None): |
|
|
|
"""Выводит content в django.http.HttpResponse, который и возвращает.""" |
|
|
|
"""Выводит content в django.http.HttpResponse, который и возвращает.""" |
|
|
|
response = HttpResponse(content, content_type='application/pdf') |
|
|
|
response = HttpResponse(content, content_type='application/pdf') |
|
|
|
|