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

{% block breadcrumb %}
  {{ block.super }}
  <a href="{{ resource.get_absolute_url }}">{{ resource.title }}</a>
  {% if object.id %}
    <a href="{{ object.id }}">{{ object.slug }}</a>
  {% else %}
    <a href="#">{% trans 'Add Query' %}</a>
  {% endif %}
{% endblock %}

{% block appbar %}
  <h2>{% if object.id %}{% trans 'Query:' %} {{ object.slug }}{% else %}{% trans 'New Query' %}{% endif %}</h2>
{% endblock %}

{% block content %}

  <form method="post" enctype="multipart/form-data">
    <div id="form-content">
      {% csrf_token %}
      {{ form|with_template }}
    </div>
    {% block buttons %}
      <div class="buttons">
        <button class="submit-button">{% trans "Save" %}</button>
        <a class="cancel" href="{{ resource.get_absolute_url }}">{% trans 'Cancel' %}</a>
      </div>
    {% endblock %}
  </form>

{% endblock %}
