{% extends "layout.jinja2" %}

{% block content %}

<div class="card mb-0">
    <div class="card-body">

	<form id="search-form" class="form-horizontal" role="form" action="/blog_search" method="post">

		<div class="mb-3">
				<div class="input-group mb-3">
				<input type="text" class="form-control" name="criteria">
				<button class="btn btn-primary" type="submit" name="form.submitted">Rechercher</button>

		</div>
	</form>

	<div class="row">
		<table class="table table-sm">
			<thead>
				<tr>
					<th>Titre</th>
					<th>Tags</th>
					<th>Date</th>
					<th></th>
				</tr>
			</thead>
			<tbody class="table-group-divider">
				{% for entry in items %}
					<tr>
						<td>
							<a href="{{ request.route_url('blog', id=entry.id, slug='slug') }}">
								{{ entry.title }}
							</a>
						</td>
						<td>{{ entry.tag }}</td>
						<td>{{ entry.edit_date }}</td>
					</tr>
				{% endfor %}
			</tbody>
		</table>
	</div> 
	<br />
	<br />
	
	</div>
</div>
{% endblock %}
