1 {% extends "documents/base.html" %}
2 {% load book_list i18n %}
6 {% block titleextra %}{{ book.title }}{% endblock %}
11 <div class="card mt-4">
12 <div class="card-header">
13 <h1>{{ book.title }}</h1>
15 <div class="card-body">
17 <div class="col-md-8">
20 {% if editable %}<form method='POST'>{% csrf_token %}{% endif %}
21 {% bootstrap_form form %}
24 <button type="submit" class="btn btn-primary">{% trans "Save" %}</button>
27 {% if editable %}</form>{% endif %}
31 <p><a href="{% url 'documents_book_gallery' book.slug %}">{% trans "Edit gallery" %}</a></p>
34 <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>
39 <div class="col-md-4">
40 {% with cbook=book.catalogue_book %}
43 <a href="{% url 'catalogue_book' cbook.slug %}">{{ cbook }}</a>
51 <div class="card mt-4">
52 <div class="card-header">
53 <h2>{% trans "Chunks" %}</h2>
55 <div class="card-body">
57 <table class='single-book-list table'><tbody>
58 {% for chunk in book %}
59 {% include 'documents/book_list/chunk.html' %}
68 <div class='card mt-4'>
70 <div class="card-header">
71 <h2>{% trans "Publication" %}</h2>
73 <div class="card-body">
75 <div class="col-lg-3">
76 <img class="cover-preview" src="{% url 'cover_preview' book.slug %}" />
77 {% if book.dc_cover_image %}
78 <a href="{{ book.dc_cover_image.get_absolute_url }}">{{ book.dc_cover_image }}</a>
82 <form action="{% url 'cover_quick_import' book.pk %}" method="post">
84 <div class="input-group">
85 <input type="url" name="url" class="form-control" placeholder="URL okładki">
86 <button type="submit" class="btn btn-sm btn-info">Ustaw</button>
92 <form action="{% url 'cover_preview' book.slug %}">
93 <input type="hidden" name="download" value="1">
95 <div class="input-group">
96 <select class="form-control" name='cover_class'>
97 <option value="default">nowa</option>
98 <option value="m-label">nowa + label</option>
99 <option value="legacy">dawna</option>
101 <input class="form-control" name="width" type="number" required value="600" size="3" placeholder="szer.">
102 <input class="form-control" name="height" type="number" size="3" placeholder="wys.">
103 <button type="submit" class="btn btn-sm btn-primary">🡇</button>
107 <div class="col-lg-9">
108 <p>{% trans "Last published" %}:
109 {% if book.last_published %}
110 {{ book.last_published }}
118 <a href="{% url 'documents_book_xml' book.slug %}" rel="nofollow">{% trans "Full XML" %}</a><br/>
119 <a target="_blank" href="{% url 'documents_book_html' book.slug %}" rel="nofollow">{% trans "HTML version" %}</a><br/>
120 <a href="{% url 'documents_book_txt' book.slug %}" rel="nofollow">{% trans "TXT version" %}</a><br/>
121 <a href="{% url 'documents_book_pdf' book.slug %}" rel="nofollow">{% trans "PDF version" %}</a><br/>
122 <a href="{% url 'documents_book_pdf_mobile' book.slug %}" rel="nofollow">{% trans "PDF version for mobiles" %}</a><br/>
123 <a href="{% url 'documents_book_epub' book.slug %}" rel="nofollow">{% trans "EPUB version" %}</a><br/>
124 <a href="{% url 'documents_book_mobi' book.slug %}" rel="nofollow">{% trans "MOBI version" %}</a><br/>
127 {% if user.is_authenticated %}
130 Angels in Ely Cathedral (http://www.flickr.com/photos/21804434@N02/4483220595/) /
131 mira66 (http://www.flickr.com/photos/21804434@N02/) /
132 CC BY 2.0 (http://creativecommons.org/licenses/by/2.0/)
134 <form method="POST" action="{% url 'documents_publish' book.slug %}">{% csrf_token %}
135 {{ publish_options_form.as_p }}
136 <img src="{{ STATIC_URL }}img/angel-left.png" style="vertical-align: middle" />
137 <button id="publish-button" type="submit">
138 <span>{% trans "Publish" %}</span></button>
139 <img src="{{ STATIC_URL }}img/angel-right.png" style="vertical-align: middle" />
142 {% if perms.depot.add_legimibookpublish %}
144 {% with thema=doc.book_info.thema %}
146 <form method="post" action="{% url 'depot_legimi_publish' book.pk %}">
148 <button class="btn btn-primary" type="submit">
149 Opublikuj na Legimi<br><small>w kategorii:
152 {% if not forloop.last %}, {% endif %}
155 {% with llp=book.last_legimi_publish %}
157 {{ llp.created_at }} →
158 {{ llp.started_at }} →
159 {{ llp.finished_at }}
160 ({{ llp.get_status_display }})
161 <!-- {{ llp.id }} -->
166 <div class="alert alert-warning">Nie można opublikować na Legimi, ponieważ nie ustaiono kategorii Thema.</div>
172 <a href="{% url 'cas_ng_login' %}">{% trans "Log in to publish." %}</a>
175 <p>{% trans "This book can't be published yet, because:" %}</p>
176 <ul><li>{{ publishable_error }}</li></ul>
188 <div class="card mt-4">
189 <div class="card-header">
190 <h2>{% trans "Statistics" %}</h2>
192 <div class="card-body">
193 <table class="table">
199 <th>{% trans "characters" %}</th>
200 <th>{% trans "characters (with footnotes)" %}</th>
201 <th>{% trans "words" %}</th>
202 <th>{% trans "words (with footnotes)" %}</th>
203 <th>{% trans "wiersze (+ inne znaki)" %}</th>
204 <th>{% trans "wiersze (+ inne znaki, z przypisami)" %}</th>
208 {% with stats=doc.get_statistics %}
209 {% include 'documents/book_stats.html' with book=book stats=stats depth=0 %}
216 {% endblock content %}