templates/admin_url/index.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block title %}Urls{% endblock %}
  3. {% block body %}
  4.     <h1>Urls</h1>
  5.     <div class="d-grid gap-2 d-md-flex justify-content-md-end">
  6.         <a class="btn btn-success" href="{{ path('app_admin_url_new') }}">Ajouter</a>
  7.     </div>
  8.     <form method="post" action="{{ path('app_admin_urls_actions') }}">
  9.         <input type="hidden" name="_token" value="{{ csrf_token('urls') }}">
  10.         <input class="btn btn-warning" type="submit" name="supprimerUrls" value="Supprimer les urls" />
  11.         <input class="btn btn-info" type="submit" name="noError" value="Retirer l'erreur" />
  12.         <table class="table">
  13.             <thead>
  14.             <tr>
  15.                 <th>Selection</th>
  16.                 <th>Id</th>
  17.                 <th>Url</th>
  18.                 <th>Prix</th>
  19.                 <th>DateTimeMaj</th>
  20.                 <th>Erreur</th>
  21.                 <th>actions</th>
  22.             </tr>
  23.             </thead>
  24.             <tbody>
  25.             {% for url in urls %}
  26.                 <tr>
  27.                     <td>
  28.                         <input type="checkbox" name="urls[]" value="{{ url.id }}" style="width:30px; height:30px;"/>
  29.                     </td>
  30.                     <td>{{ url.id }}</td>
  31.                     <td><a href="{{ url.adresse }}" target="_blank">{{ url.adresse }}</a>
  32.                         <br/>
  33.                         <small>{{ url.commentaire }}</small>
  34.                     </td>
  35.                     <td>{{ url.prix }}</td>
  36.                     <td>{{ url.dateTimeMaj ? url.dateTimeMaj|date('Y-m-d H:i:s') : '' }}</td>
  37.                     <td>{{ url.erreur }}</td>
  38.                     <td>
  39.                         <a class="link-dark" href="{{ path('app_admin_url_show', {'id': url.id}) }}">Voir</a>
  40.                         <a class="link-primary" href="{{ path('app_admin_url_edit', {'id': url.id}) }}">Editer</a>
  41.                         <a class="link-danger" href="{{ path('crawl-force-url', {'id': url.id}) }}">Forcer</a>
  42.                     </td>
  43.                 </tr>
  44.             {% else %}
  45.                 <tr>
  46.                     <td colspan="6">no records found</td>
  47.                 </tr>
  48.             {% endfor %}
  49.             </tbody>
  50.         </table>
  51.     </form>
  52. {% endblock %}