{% extends 'base.html' %}
{% block content %}
<h1>Posts</h1>
<p><a href="/admin/posts/new">Neuer Post</a></p>
<table border="1" cellpadding="6" cellspacing="0">
  <tr>
    <th>ID</th><th>Titel</th><th>Slug</th><th>Locale</th><th>Publiziert</th><th>Geändert</th><th></th>
  </tr>
  {% for p in posts %}
  <tr>
    <td>{{ p.id }}</td>
    <td>{{ p.title }}</td>
    <td>{{ p.slug }}</td>
    <td>{{ p.locale }}</td>
    <td>{{ 'yes' if p.is_published else 'no' }}</td>
    <td>{{ p.updated_at or '' }}</td>
    <td><a href="/admin/posts/{{ p.id }}/edit">Edit</a></td>
  </tr>
  {% endfor %}
</table>
{% endblock %}
