{% extends "passerelle/manage.html" %}
{% load i18n passerelle %}

{% block breadcrumb %}
  {{ block.super }}
  <a href="{{object.get_absolute_url}}">{{ object.title }}</a>
  <a href="#">{% trans "Jobs" %}</a>
{% endblock %}

{% block appbar %}
  <h2>{% trans "Jobs" %}</h2>
{% endblock %}

{% block content %}

  <div id="jobs">

    <form>
      <p><input name="q" type="search" value="{{query}}"> <button>{% trans 'Search' %}</button>
        <span class="help_text">{% trans "(supports text search in job name or dates)" %}</span>
      </p>
    </form>

    {% include "passerelle/includes/resource-jobs-table.html" with jobs=page_obj %}
  </div>

  {% if job_target %}
    <script>
      $(function () {
        open_job_window($('table.main').data('job-base-url'), {{ job_target.pk }});
      });
    </script>
  {% endif %}

{% endblock %}
