Merge pull request #122 from juliengk/layout
Add version and current year to the layout
This commit is contained in:
@@ -58,6 +58,14 @@ def stream_template(template_name, **context):
|
|||||||
return rv
|
return rv
|
||||||
|
|
||||||
|
|
||||||
|
@app.context_processor
|
||||||
|
def utility_processor():
|
||||||
|
def now(format='%m/%d/%Y %H:%M:%S'):
|
||||||
|
"""returns the formated datetime"""
|
||||||
|
return datetime.now().strftime(format)
|
||||||
|
return dict(now=now)
|
||||||
|
|
||||||
|
|
||||||
@app.errorhandler(400)
|
@app.errorhandler(400)
|
||||||
def bad_request(e):
|
def bad_request(e):
|
||||||
return render_template('400.html'), 400
|
return render_template('400.html'), 400
|
||||||
|
|||||||
@@ -38,6 +38,7 @@
|
|||||||
<a {% if endpoint == request.endpoint %} class="active item" {% else %} class="item" {% endif %}
|
<a {% if endpoint == request.endpoint %} class="active item" {% else %} class="item" {% endif %}
|
||||||
href="{{ url_for(endpoint) }}">{{ caption }}</a>
|
href="{{ url_for(endpoint) }}">{{ caption }}</a>
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
|
<div class="item" style="float:right"><a href="https://github.com/puppet-community/puppetboard" target="_blank">v0.0.4</a></div>
|
||||||
</nav>
|
</nav>
|
||||||
<div class="ui grid padding-bottom">
|
<div class="ui grid padding-bottom">
|
||||||
<div class="one wide column"></div>
|
<div class="one wide column"></div>
|
||||||
@@ -53,7 +54,7 @@
|
|||||||
|
|
||||||
<footer class="ui absolute fixed bottom">
|
<footer class="ui absolute fixed bottom">
|
||||||
<div>
|
<div>
|
||||||
Copyright © 2013-2014 <a href="https://github.com/daenney">Daniele Sluijters</a>. <span style="float:right">Live from PuppetDB.</span>
|
Copyright © 2013-{{ now('%Y') }} <a href="https://github.com/daenney" target="_blank">Daniele Sluijters</a>. <span style="float:right">Live from PuppetDB.</span>
|
||||||
</div>
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user