feat: add boxes templates
This commit is contained in:
parent
083187c15b
commit
bc5ccfe221
25
back-end/src/templates/box.ejs
Normal file
25
back-end/src/templates/box.ejs
Normal file
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>
|
||||
<%= box.title %>
|
||||
</title>
|
||||
|
||||
<%- include('partials/links.ejs') %>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<%- include('partials/header.ejs') %>
|
||||
<h1>
|
||||
<%= box.title %>
|
||||
</h1>
|
||||
<pre>
|
||||
id : <%= box.id %>
|
||||
date : <%= box.date %>
|
||||
</pre>
|
||||
</body>
|
||||
|
||||
</html>
|
39
back-end/src/templates/boxes.ejs
Normal file
39
back-end/src/templates/boxes.ejs
Normal file
@ -0,0 +1,39 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>
|
||||
Liste des boîtes
|
||||
</title>
|
||||
|
||||
<%- include('partials/links.ejs') %>
|
||||
</head>
|
||||
<body>
|
||||
<%- include('partials/header.ejs') %>
|
||||
|
||||
<h1>
|
||||
Liste des boîtes
|
||||
</h1>
|
||||
|
||||
<div class="fromDate">
|
||||
<label for="fromDate">À partir de : </label>
|
||||
<input type="date" name="fromDate" id="fromDate">
|
||||
<input type="submit" value="Filtrer" onclick="window.location.pathname = '/boxes/from/' + document.getElementById('fromDate').value;">
|
||||
</div>
|
||||
|
||||
<hr>
|
||||
|
||||
<ul>
|
||||
<% boxes.forEach(function(box) { %>
|
||||
<li>
|
||||
<a href="/boxes/<%=box.title%>">
|
||||
<%=box.title%>
|
||||
</a>
|
||||
</li>
|
||||
<% }); %>
|
||||
</ul>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
@ -12,6 +12,12 @@
|
||||
Modèles
|
||||
</li>
|
||||
</a>
|
||||
|
||||
<a href="/boxes">
|
||||
<li>
|
||||
Boîtes
|
||||
</li>
|
||||
</a>
|
||||
</ul>
|
||||
</nav>
|
||||
</header>
|
||||
|
Loading…
x
Reference in New Issue
Block a user