1 {% extends "documents/base.html" %}
2 {% load book_list i18n %}
8 {% block titleextra %}{{ book.title }}{% endblock %}
13 <div class="card mt-4">
14 <div class="card-header">
15 <h1>{{ book.title }}</h1>
17 <div class="card-body">
19 <div class="col-md-8">
22 {% if editable %}<form method='POST'>{% csrf_token %}{% endif %}
23 {% bootstrap_form form %}
26 <button type="submit" class="btn btn-primary">{% trans "Save" %}</button>
29 {% if editable %}</form>{% endif %}
33 <p><a href="{% url 'documents_book_gallery' book.slug %}">{% trans "Edit gallery" %}</a></p>
36 <p style="text-align:right"><a class="btn btn-sm btn-danger" href="{% url 'documents_book_append' book.slug %}">{% trans "Append to other book" %}</a></p>
41 <div class="col-md-4">
42 {% with cbook=book.catalogue_book %}
45 <a href="{% url 'catalogue_book' cbook.slug %}">{{ cbook }}</a>
53 <div class="card mt-4">
54 <div class="card-header">
55 <h2>{% trans "Chunks" %}</h2>
57 <div class="card-body">
59 <table class='single-book-list table'><tbody>
60 {% for chunk in book %}
61 {% include 'documents/book_list/chunk.html' %}
70 <div class='card mt-4'>
72 <div class="card-header">
74 {% trans "Publication" %}
77 {% if book.project.can_sell %}
78 <span title="Książka do sprzedaży">💶</span>
80 <span title="Książka nie do sprzedaży">🙅</span>
83 <span title="Brak informacji o możliwości sprzedaży">❓</span>
87 {% if can_sell_audio %}
88 <span title="Audiobook do sprzedaży">💶</span>
90 <span title="Audiobook nie do sprzedaży">🙅</span>
96 <div class="card-body">
98 <div class="col-lg-3">
99 <img class="cover-preview" src="{% url 'cover_preview' book.slug %}" />
100 {% if book.dc_cover_image %}
101 <a href="{{ book.dc_cover_image.get_absolute_url }}">{{ book.dc_cover_image }}</a>
105 <form action="{% url 'cover_quick_import' book.pk %}" method="post">
107 <div class="input-group">
108 <input type="url" name="url" class="form-control" placeholder="URL okładki">
109 <button type="submit" class="btn btn-sm btn-info">Ustaw</button>
115 <form action="{% url 'cover_preview' book.slug %}">
116 <input type="hidden" name="download" value="1">
118 <div class="input-group">
119 <select class="form-control" name='cover_class'>
120 <option value="default">nowa</option>
121 <option value="m-label">nowa + label</option>
122 <option value="legacy">dawna</option>
124 <input class="form-control" name="width" type="number" required value="600" size="3" placeholder="szer.">
125 <input class="form-control" name="height" type="number" size="3" placeholder="wys.">
126 <button type="submit" class="btn btn-sm btn-primary">🡇</button>
130 <div class="col-lg-9">
131 <p>{% trans "Last published" %}:
132 {% if book.last_published %}
133 {{ book.last_published }}
141 <a href="{% url 'documents_book_xml' book.slug %}" rel="nofollow">{% trans "Full XML" %}</a><br/>
142 <a target="_blank" href="{% url 'documents_book_html' book.slug %}" rel="nofollow">{% trans "HTML version" %}</a><br/>
143 <a href="{% url 'documents_book_txt' book.slug %}" rel="nofollow">{% trans "TXT version" %}</a><br/>
144 <a href="{% url 'documents_book_pdf' book.slug %}" rel="nofollow">{% trans "PDF version" %}</a><br/>
145 <a href="{% url 'documents_book_pdf_mobile' book.slug %}" rel="nofollow">{% trans "PDF version for mobiles" %}</a><br/>
146 <a href="{% url 'documents_book_epub' book.slug %}" rel="nofollow">{% trans "EPUB version" %}</a>
147 <a href="{% url 'documents_book_epubcheck' book.slug %}" rel="nofollow">sprawdź</a><br/>
148 <a href="{% url 'documents_book_mobi' book.slug %}" rel="nofollow">{% trans "MOBI version" %}</a><br/>
151 <p><a href="./synchro">Sprawdź synchronizację</a></p>
153 {% isbn_status book %}
155 {% if user.is_authenticated %}
158 Angels in Ely Cathedral (http://www.flickr.com/photos/21804434@N02/4483220595/) /
159 mira66 (http://www.flickr.com/photos/21804434@N02/) /
160 CC BY 2.0 (http://creativecommons.org/licenses/by/2.0/)
162 <form method="POST" action="{% url 'documents_publish' book.slug %}">{% csrf_token %}
163 {{ publish_options_form.as_p }}
164 <img src="{{ STATIC_URL }}img/angel-left.png" style="vertical-align: middle" />
165 <button id="publish-button" type="submit">
166 <span>{% trans "Publish" %}</span></button>
167 <img src="{{ STATIC_URL }}img/angel-right.png" style="vertical-align: middle" />
171 {% if perms.depot.add_sitebookpublish %}
172 {% depot_sites book as sites %}
173 {% for site in sites %}
175 <h3 class="mb-3">{{ site.name }}</h3>
176 {% if not site.errors %}
177 <form method="post" action="{% url 'depot_site_publish' site.site_id book.pk %}">
179 <button class="btn btn-primary mb-3" type="submit">
180 Opublikuj na {{ site.name }}
183 {% for info in site.info %}
184 <div class="alert alert-info">
189 {% for error in site.errors %}
190 <div class="alert alert-danger">
195 {% for warning in site.warnings %}
196 <div class="alert alert-warning">
203 {% with last=site.last %}
205 {{ last.created_at }} →
206 {{ last.started_at }} →
207 {{ last.finished_at }}
208 <span title="{{ last.error }}">
209 ({{ last.get_status_display }})
211 <!-- {{ site.last.id }} -->
218 <a href="{% url 'cas_ng_login' %}">{% trans "Log in to publish." %}</a>
221 <p>{% trans "This book can't be published yet, because:" %}</p>
222 <ul><li>{{ publishable_error }}</li></ul>
231 <div class="card mt-4">
232 <div class="card-header">
233 <h2>{% trans "Statistics" %}</h2>
235 <div class="card-body">
236 <table class="table">
242 <th>{% trans "characters" %}</th>
243 <th>{% trans "characters (with footnotes)" %}</th>
244 <th>{% trans "words" %}</th>
245 <th>{% trans "words (with footnotes)" %}</th>
246 <th>{% trans "wiersze (+ inne znaki)" %}</th>
247 <th>{% trans "wiersze (+ inne znaki, z przypisami)" %}</th>
251 {% include 'documents/book_stats.html' with book=doc stats=stats depth=0 %}
257 {% endblock content %}