Merge branch 'matej-fix-korektury-komentare' into stable
This commit is contained in:
commit
73d8ed51bf
1 changed files with 22 additions and 9 deletions
|
@ -168,7 +168,7 @@
|
||||||
{% for k in o.komentare %}
|
{% for k in o.komentare %}
|
||||||
<hr>
|
<hr>
|
||||||
<div class='comment' id='k{{k.id}}'>
|
<div class='comment' id='k{{k.id}}'>
|
||||||
<span class='corr-header'>
|
<div class='corr-header'>
|
||||||
<div class='author'>{{k.autor}}</div>
|
<div class='author'>{{k.autor}}</div>
|
||||||
<span class="float-right">
|
<span class="float-right">
|
||||||
<!-- Komentar !-->
|
<!-- Komentar !-->
|
||||||
|
@ -177,17 +177,30 @@
|
||||||
<input type='hidden' name='pdf' value='{{pdf.id}}'>
|
<input type='hidden' name='pdf' value='{{pdf.id}}'>
|
||||||
<input type='hidden' name='id' value='{{k.id}}'>
|
<input type='hidden' name='id' value='{{k.id}}'>
|
||||||
<input type='hidden' name='scroll'>
|
<input type='hidden' name='scroll'>
|
||||||
<button type='submit' name='action' value='del-comment' title='Smaž komentář'
|
{% if forloop.last %}
|
||||||
onclick='return confirm("Opravdu smazat komentář?")'>
|
<button type='submit' name='action' value='del-comment' title='Smaž komentář'
|
||||||
<img src="{% static "korektury/imgs/delete.png" %}"/>
|
onclick='return confirm("Opravdu smazat komentář?")'>
|
||||||
</button>
|
<img src="{% static "korektury/imgs/delete.png" %}"/>
|
||||||
|
</button>
|
||||||
|
{% else %}
|
||||||
|
<button name='action' value='del-comment' type='button'
|
||||||
|
title="Komentář nelze smazat – existuje novější">
|
||||||
|
<img src="{% static "korektury/imgs/delete-gr.png"%}"/>
|
||||||
|
</button>
|
||||||
|
{% endif %}
|
||||||
</form>
|
</form>
|
||||||
<!-- /Komentar !-->
|
<!-- /Komentar !-->
|
||||||
<button type='button' onclick='update_comment(this);' title='Uprav komentář'>
|
{% if forloop.last %}
|
||||||
<img src="{% static "korektury/imgs/edit.png"%}"/>
|
<button type='button' onclick='update_comment(this);' title='Uprav komentář'>
|
||||||
</button>
|
<img src="{% static "korektury/imgs/edit.png"%}"/>
|
||||||
|
</button>
|
||||||
|
{% else %}
|
||||||
|
<button type='button' title="Komentář nelze upravit – existuje novější">
|
||||||
|
<img src="{% static "korektury/imgs/edit-gr.png" %}"/>
|
||||||
|
</button>
|
||||||
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
</span>
|
</div>
|
||||||
<div id='kt{{k.id}}'>{{k.text}}</div>
|
<div id='kt{{k.id}}'>{{k.text}}</div>
|
||||||
</div>
|
</div>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
Loading…
Reference in a new issue