diff --git a/opds/templates/opds/base.xml b/opds/templates/opds/base.xml new file mode 100644 index 0000000..8b0655a --- /dev/null +++ b/opds/templates/opds/base.xml @@ -0,0 +1,15 @@ + + + {% block id_and_title %}{% endblock%} + {{ Lastchange|date:"Y-m-d" }}T00:00:00Z + {{request.scheme}}://{{ request.site }}/static/assets/images/favicon.png + + {{ request.site.name }} + {{request.scheme}}://{{request.site}} + + {% block link_rel_self %}{% endblock%} + +{% block content %}{% endblock %} + diff --git a/opds/templates/opds/root.xml b/opds/templates/opds/root.xml new file mode 100644 index 0000000..156d7aa --- /dev/null +++ b/opds/templates/opds/root.xml @@ -0,0 +1,24 @@ +{% extends "opds/base.xml" %} +{% block id_and_title %} + {{request.scheme}}://{{ request.site }}/opds/root.atom + EBook Catalogue of {{request.site.name}} +{% endblock%} + +{% block link_rel_self %} + +{% endblock%} + +{% block content %} +{% for serie in Series %} + + {{ serie.name }} + + {{ Lastchange|date:"Y-m-d" }}T00:00:00Z + {{request.scheme}}://{{ request.site }}/opds/{{ serie|lower }}.atom + {{ serie.description }} + +{% endfor %} +{% endblock %} diff --git a/opds/templates/opds/series.xml b/opds/templates/opds/series.xml new file mode 100644 index 0000000..4bc6c51 --- /dev/null +++ b/opds/templates/opds/series.xml @@ -0,0 +1,80 @@ +{% extends "opds/base.xml" %} + +{% block id_and_title %} + {{request.scheme}}://{{ request.site }}/opds/{{ Series }}.atom + EBook Catalogue of {{request.site.name}} {{ Series|capfirst }} +{% endblock%} + +{% block link_rel_self %} + + +{% endblock%} + +{% block content %} +{% for book in Books %} + + {{ book.Title }} + {{request.scheme}}://{{ request.site }}/{{ book.Serie }}/{{ book.Number }}/index.html + urn:ISBN:{{ book.Isbn }} + {% if book.Publicationauthor1 %} + + {{ book.Publicationauthor1 }} + {{request.scheme}}://{{ request.site }}/author/{{ book.Publicationauthor1number }}.html + + {% endif %} +{% if book.Publicationauthor2 %} + + {{ book.Publicationauthor2 }} + {{request.scheme}}://{{ request.site }}/author/{{ book.Publicationauthor2number }}.html + +{% endif %} +{% if book.Publicationauthor3 %} + + {{ book.Publicationauthor3 }} + {{request.scheme}}://{{ request.site }}/author/{{ book.Publicationauthor3number }}.html + +{% endif %} +{% if book.Publicationauthor4 %} + + {{ book.Publicationauthor4 }} + {{request.scheme}}://{{ request.site }}/author/{{ book.Publicationauthor4number }}.html + +{% endif %} +{% if book.Publicationauthor5 %} + + {{ book.Publicationauthor5 }} + {{request.scheme}}://{{ request.site }}/author/{{ book.Publicationauthor5number }}.html + +{% endif %} + {{ book.Datepublished |date:"Y-m-d" }}T00:00:00Z + {{ book.Datepublished |date:"Y-m-d" }}T00:00:00Z + {{ book.Language }} + {{ request.site.name }} + {{ book.Datepublished |date:"Y-m-d" }} + {{ book.Descriptionlong }} + + + + +{% if book.Shoplink %} + + {{ book.Price }} + + + + + {% endif %} +{% if book.Publicationebookfile %} + +{% endif %} +{% if book.Publicationpdffile %} + +{% endif %} + +{% endfor %} +{% endblock %}