Included version number in base template.
This commit is contained in:
parent
6db093437b
commit
e618f06d11
2 changed files with 4 additions and 2 deletions
|
@ -1,6 +1,8 @@
|
|||
|
||||
from jinja2 import Environment, Template
|
||||
|
||||
from matemat import __version__
|
||||
|
||||
|
||||
class PageletResponse:
|
||||
"""
|
||||
|
@ -60,4 +62,4 @@ class TemplateResponse(PageletResponse):
|
|||
:return: An UTF-8 encoded bytes object containing the template rendering result.
|
||||
"""
|
||||
template: Template = jinja_env.get_template(self.name)
|
||||
return template.render(**self.kwargs).encode('utf-8')
|
||||
return template.render(**self.kwargs, __version__=__version__).encode('utf-8')
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
<footer>
|
||||
{% block footer %}
|
||||
<ul>
|
||||
<li> Matemat
|
||||
<li> Matemat {{__version__}}
|
||||
<li> © 2018 s3lph
|
||||
<li> MIT License
|
||||
<li> <a href="https://gitlab.com/s3lph/matemat">Source & Documentation</a>
|
||||
|
|
Loading…
Reference in a new issue