Fix server side AJAX template rendering
Signed-off-by: Roberto Rosario <Roberto.Rosario@mayan-edms.com>
This commit is contained in:
@@ -305,10 +305,10 @@ class Template(object):
|
|||||||
context=context,
|
context=context,
|
||||||
).render()
|
).render()
|
||||||
|
|
||||||
content = result.rendered_content.replace('\n', '')
|
# Calculate the hash of the bytes version but return the unicode
|
||||||
|
# version
|
||||||
self.html = content
|
self.html = result.rendered_content.replace('\n', '')
|
||||||
self.hex_hash = hashlib.sha256(content).hexdigest()
|
self.hex_hash = hashlib.sha256(result.content).hexdigest()
|
||||||
return self
|
return self
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user