added a footer

This commit is contained in:
Feliciaan De Palmenaer 2015-03-30 00:23:59 +02:00
parent c3d776a985
commit 79063f8bdf
3 changed files with 22 additions and 3 deletions

View file

@ -9,13 +9,13 @@
<h3>This is the home page for FoodBot</h3>
</div>
<div class="row">
<div class="col-md-4">
<div class="col-sm-5">
<h3>Open orders:</h3>
{% for order in orders %}
{{ util.render_order(order) }}
{% endfor %}
</div>
<div class="col-md-4 col-md-push-4">
<div class="col-sm-5 col-sm-push-2">
<h3>Recently closed orders:</h3>
{% for order in recently_closed %}
{{ util.render_order(order) }}

View file

@ -13,12 +13,18 @@
{% set active_page = active_page|default('index') -%}
{% block title %}
FoodBot
FoodBot - {{ active_page|capitalize }}
{% endblock %}
{% block styles %}
{{ super() }}
<link rel="stylesheet" href="{{ url_for('static', filename='css/main.css') }}">
{% endblock %}
{% block scripts %}
<script async defer id="github-bjs" src="https://buttons.github.io/buttons.js"></script>
{% endblock %}
{% block navbar %}
<nav class="navbar navbar-default navbar-fixed-top">
<div class="container">
@ -59,4 +65,13 @@
{% block container -%}
{%- endblock %}
</div>
<footer>
<hr>
<div class="container">
<div class="pull-right">Made with ❤ by <a href="http://zeus.ugent.be">Zeus WPI</a></div>
<div class="pull-left"><a class="github-button" href="https://github.com/ZeusWPI/FoodBot" data-icon="octicon-star" data-style="mega" data-count-href="/ZeusWPI/FoodBot/stargazers" data-count-api="/repos/ZeusWPI/FoodBot#stargazers_count" data-count-aria-label="# stargazers on GitHub" aria-label="Star ZeusWPI/FoodBot on GitHub">Star</a></div>
<div class="text-center">© {{ ""|year }}<a href="http://github.com/ZeusWPI/FoodBot"></a></div>
</div>
</footer>
{%- endblock %}

View file

@ -23,6 +23,10 @@ def countdown(value, only_positive=True, show_text=True):
return 'closes in ' + time
return time
@app.template_filter('year')
def current_year(value):
return str(datetime.now().year)
@app.errorhandler(404)
def handle404(e):
return render_template('errors/404.html'), 404