Mise en place d'un embryon de template commun
This commit is contained in:
parent
0af45f6d23
commit
d6836d3661
0
src/agenda_culturel/static/css/style.css
Normal file
0
src/agenda_culturel/static/css/style.css
Normal file
68
src/agenda_culturel/static/images/favicon-dev.svg
Normal file
68
src/agenda_culturel/static/images/favicon-dev.svg
Normal file
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 61 KiB |
61
src/agenda_culturel/static/images/favicon.svg
Normal file
61
src/agenda_culturel/static/images/favicon.svg
Normal file
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 60 KiB |
@ -1,2 +1,10 @@
|
||||
{% extends "agenda_culturel/page.html" %}
|
||||
|
||||
{% block title %}{{ object.title }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<h1>{{ object.title }}</h1>
|
||||
<p>Date : {{ object.start_day }}</p>
|
||||
<p>Date : {{ object.start_day }}</p>
|
||||
|
||||
{% endblock %}
|
@ -1,3 +1,8 @@
|
||||
{% extends "agenda_culturel/page.html" %}
|
||||
|
||||
{% block title %}Accueil{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1>Événements</h1>
|
||||
<ul>
|
||||
{% for event in object_list %}
|
||||
@ -5,4 +10,5 @@
|
||||
{% empty %}
|
||||
<li>Il n'y a pas d'événement.</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</ul>
|
||||
{% endblock %}
|
@ -1 +1,14 @@
|
||||
ça marche
|
||||
{% extends "agenda_culturel/page.html" %}
|
||||
|
||||
{% block title %}Accueil{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1>Événements</h1>
|
||||
<ul>
|
||||
{% for event in object_list %}
|
||||
<li><a href="{{ BASE_URL }}{{ event.get_absolute_url }}">{{ event.start_day|date }} : {{ event.title }}</a></li>
|
||||
{% empty %}
|
||||
<li>Il n'y a pas d'événement.</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock %}
|
22
src/agenda_culturel/templates/agenda_culturel/page.html
Normal file
22
src/agenda_culturel/templates/agenda_culturel/page.html
Normal file
@ -0,0 +1,22 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>{% block title %}{% endblock %}</title>
|
||||
|
||||
{% load static %}
|
||||
{% if debug %}
|
||||
<link rel="icon" type="image/svg+xml" href="{% static 'images/favicon-dev.svg' %}">
|
||||
{% else %}
|
||||
<link rel="icon" type="image/svg+xml" href="{% static 'images/favicon.svg' %}">
|
||||
{% endif %}
|
||||
<link rel="stylesheet" href="{% static 'css/style.css' %}">
|
||||
{% block entete_header %}
|
||||
{% endblock %}
|
||||
</head>
|
||||
<body>
|
||||
<div id="full_content" class="{% block classe_principale %}{% endblock %}">
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
</body>
|
@ -1,15 +1,12 @@
|
||||
<!doctype html>
|
||||
<html lang="fr">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Proposer un événement</title>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Formulaire de proposition d'événement</h2>
|
||||
{% extends "agenda_culturel/page.html" %}
|
||||
|
||||
{% block title %}Proposer un événement{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h1>Formulaire de proposition d'événement</h1>
|
||||
<form method="post" action="">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p }}
|
||||
<input type="submit" value="Proposer un événement">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
{% endblock %}
|
||||
|
Loading…
Reference in New Issue
Block a user