{% load oai %}
{% load url from future %}
  <metadata>
    <oai_qdc:qdc xmlns:oai_qdc="http://www.enssib.fr/bibliotheque-numerique/oai_qdc/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd http://www.enssib.fr/bibliotheque-numerique/oai_qdc/ http://www.enssib.fr/bibliotheque-numerique/oai_qdc.xsd">
      <dc:title>{{ poly_request.name }}</dc:title>
      <dc:creator>{{ poly_request.user.display_name }}{% if poly_request.sponsor %} - {{poly_request.sponsor}}{% endif %}</dc:creator>
      <dc:identifier>{{ base_url }}{% url 'public-document' pk=poly_request.pk %}</dc:identifier>
      <dc:description>{{ poly_request.nb_pages }}p</dc:description>
      <dc:format xsi:type="dcterms:IMT">application/pdf</dc:format>
      <dcterms:created xsi:type="dcterms:W3CDTF">{{ poly_request.creation_date|date:"c" }}</dcterms:created>
      <dc:rights>{{ poly_request.copyright_status }}</dc:rights>
      <dcterms:accessRights>{{ poly_request.licence.name }}</dcterms:accessRights>
      <dc:type>{{ poly_request.usage.name }}</dc:type>
      <dcterms:audience>{{ poly_request.entity.code }}</dcterms:audience>
      {% for key, value in settings.OAI_DC_EXTRA %}
      <dc:{{key}}>{{value}}</dc:{{key}}>
      {% endfor %}
    </oai_qdc:qdc>
  </metadata>
