<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title>Pending commits for the current run</title>
    <link rel="stylesheet" href="styles.css">
  </head>
  <body>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.5.1/jquery.min.js" integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=" crossorigin="anonymous"></script>
    <script src="https://cdn.datatables.net/1.10.22/js/jquery.dataTables.js" integrity="sha384-qPGCkCPOuGBUt/edB/0Dab3wE62dCo5HskKmbabea0YxTq2fhWoKXO8ItrP6qZu+" crossorigin="anonymous"></script>
    <h1>
      <i class='fa fa-chevron-circle-right pull-left'></i>
      Pending commits for the current run: {{ target | capitalize }} ({{ src }})
    </h1>
    <table id="dlrn" class="pf-c-table pf-m-compact pf-m-grid-md cell-border hover" role="grid" aria-label="dlrntable">
     <thead>
      <tr>
        <th>Commit Date Time</th>
        <th>Project Name</th>
        <th>Commit Hash</th>
      </tr>
     </thead>
     <tbody>
      {% for commit in commits %}
        <tr {% if commit.status == "FAILED" %}class="failure"{% endif %}>
          <td>{{ commit.dt_commit | strftime }}</td>
          <td>{{ commit.project_name }}</td>
          <td class="commit">
            <i class="fas fa-code-branch pull-left"></i>
              <a href="{{ commit | get_commit_url }}{{ commit.commit_hash }}">
                {{ commit.commit_hash }}
              </a>
          </td>
        </tr>
      {% endfor %}
     </tbody>
    </table>
    <script>
        $(document).ready( function () {
            $('#dlrn').DataTable({
              "paging": false,
              "searching": false,
               "order": [[0, 'desc']],
            });
         } );
    </script>
  </body>
</html>
