4 changed files with 52 additions and 52 deletions
@ -1,14 +1,18 @@ |
|||||
{% extends 'base.html' %} |
{% extends 'base.html' %} |
||||
|
{% load bootstrap3 %} |
||||
{% block content %} |
{% block content %} |
||||
{% if title %} |
{% if title %} |
||||
<h1>{{title}}</h1> |
<h1>{{title}}</h1> |
||||
{% endif %} |
{% endif %} |
||||
<form action="" method="post">{% csrf_token %} |
<form action="" method="post">{% csrf_token %} |
||||
{{ form.as_p }} |
{% bootstrap_form form %} |
||||
{% if validate %} |
<button type="submit" class="btn btn-primary"> |
||||
<input type="submit" value="{{validate}}" /> |
{% bootstrap_icon "star" %} |
||||
{% else %} |
{% if validate %} |
||||
<input type="submit" value="Mettre à jour" /> |
{{validate}} |
||||
{% endif %} |
{% else %} |
||||
|
Mettre à jour |
||||
|
{% endif %} |
||||
|
</button> |
||||
</form> |
</form> |
||||
{% endblock %} |
{% endblock %} |
||||
|
|||||
@ -1,33 +1,19 @@ |
|||||
{% load categories %} |
{% load categories %} |
||||
{% load_categories %} |
{% load_categories %} |
||||
<nav class="navbar navbar-default navbar-inverse"> |
<nav class="navbar navbar-expand-lg navbar-light bg-light"> |
||||
<div class="container-fluid"> |
<a class="navbar-brand" href="{% url "home"%}">Il était une fois à l'est</a> |
||||
<!-- Brand and toggle get grouped for better mobile display --> |
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarText" aria-controls="navbarText" aria-expanded="false" aria-label="Toggle navigation"> |
||||
<div class="navbar-header"> |
<span class="navbar-toggler-icon"></span> |
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false"> |
</button> |
||||
<span class="sr-only">Toggle navigation</span> |
<div class="collapse navbar-collapse" id="navbarText"> |
||||
<span class="icon-bar"></span> |
<ul class="navbar-nav mr-auto"> |
||||
<span class="icon-bar"></span> |
|
||||
<span class="icon-bar"></span> |
|
||||
</button> |
|
||||
<a class="navbar-brand" href="#">Brand</a> |
|
||||
</div> |
|
||||
|
|
||||
<!-- Collect the nav links, forms, and other content for toggling --> |
|
||||
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> |
|
||||
<ul class="nav navbar-nav"> |
|
||||
{% for c in categories %} |
{% for c in categories %} |
||||
{% if category.pk == c.pk %} |
<li class="nav-item |
||||
<li class="active"> |
{% if category.pk == c.pk %}active{%endif%}"> |
||||
{%else%} |
<a class="nav-link" href="{% url 'content:category-list' c.pk %}">{{c.name}} |
||||
<li> |
|
||||
{%endif%} |
|
||||
<a href="{% url 'content:category-list' c.pk %}">{{c.name}} |
|
||||
</a></li> |
</a></li> |
||||
{% endfor %} |
{% endfor %} |
||||
<li><a href="{% url 'vote:home' %}">Vote</a></li> |
|
||||
<li><a href="{% url 'settings:index' %}">Administration</a></li> |
<li class="nav-item {% if vote %}active{% endif %}"><a class="nav-link" href="{% url 'vote:home' %}">Vote</a></li> |
||||
</ul> |
<li class="nav-item {% if settings %}active{% endif %}"><a class="nav-link" href="{% url 'settings:index' %}">Administration</a></li> |
||||
</div><!-- /.navbar-collapse --> |
|
||||
</div><!-- /.container-fluid --> |
|
||||
</nav> |
</nav> |
||||
|
|||||
Loading…
Reference in new issue