show.html.twig 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. {% extends 'base.html.twig' %}
  2. {% block title %}Article{% endblock %}
  3. {% block body %}
  4. <h1>Article</h1>
  5. <table class="table">
  6. <tbody>
  7. <tr>
  8. <th>Id</th>
  9. <td>{{ article.id }}</td>
  10. </tr>
  11. <tr>
  12. <th>Titre</th>
  13. <td>{{ article.title }}</td>
  14. </tr>
  15. <tr>
  16. <th>Permalien</th>
  17. <td>{{ url('app_view', {slug: article.slug}) }}</td>
  18. </tr>
  19. <tr>
  20. <th>Date de publication</th>
  21. <td>{{ article.publicationDate ? article.publicationDate|date('Y-m-d H:i:s') : '' }}</td>
  22. </tr>
  23. <tr>
  24. <th>Etat</th>
  25. <td><span class="badge badge-{{ article.state }}">{{ article.state | trans }}</span></td>
  26. </tr>
  27. <tr>
  28. <th>Contenu</th>
  29. <td>
  30. {{ article.content | markdown }}
  31. </td>
  32. </tr>
  33. </tbody>
  34. </table>
  35. <a href="{{ path('app_article_index') }}">Retour à la liste</a>
  36. <a href="{{ path('app_article_edit', {'id': article.id}) }}" class="btn btn-blue">Editer</a>
  37. <a href="{{ path('app_view', {'slug': article.slug}) }}" class="btn btn-green">Aperçu</a>
  38. {{ include('article/_delete_form.html.twig') }}
  39. {{ include('article/_bouton_agrandir.html.twig') }}
  40. {% endblock %}