nekrochan/templates/macros/post-actions.html

189 řádky
6.5 KiB
HTML
Surový Normální zobrazení Historie

2023-12-25 13:53:44 +00:00
{% macro post_actions() %}
2023-12-11 15:18:43 +00:00
<details>
<summary class="box">Uživatelské akce</summary>
<table class="form-table">
<tr>
<td class="label">Odstranit příspěvky</td>
<td>
<div class="input-wrapper">
<input name="remove_posts" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Odstranit soubory</td>
<td>
<div class="input-wrapper">
<input name="remove_files" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Přidat/odstranit spoiler</td>
<td>
<div class="input-wrapper">
<input name="toggle_spoiler" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Heslo</td>
<td>
<input
name="password"
type="text"
autocomplete="new-password"
value="{{ tcx.password }}"
required=""
>
</td>
</tr>
<tr>
<td class="submit" colspan="2">
<input
class="button"
type="submit"
formaction="/actions/user-post-actions"
value="Odeslat"
>
</td>
</tr>
</table>
<table class="form-table">
<tr>
<td class="label">Důvod hlášení</td>
<td><textarea name="report_reason"></textarea></td>
</tr>
<tr>
<td class="submit" colspan="2">
<input
class="button"
type="submit"
formaction="/actions/report-posts"
value="Nahlásit"
>
</td>
</tr>
</table>
</details>
<br>
2023-12-25 13:53:44 +00:00
{% if tcx.perms.owner() || tcx.perms.manage_posts() || tcx.perms.bans() || tcx.perms.edit_posts() %}
2023-12-11 15:18:43 +00:00
<details>
<summary class="box">Uklízečské akce</summary>
<table class="form-table">
2023-12-25 13:53:44 +00:00
{% if tcx.perms.owner() || tcx.perms.manage_posts() %}
2023-12-11 15:18:43 +00:00
<tr>
<td class="label">Odstranit příspěvky</td>
<td>
<div class="input-wrapper">
<input name="staff_remove_posts" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Odstranit soubory</td>
<td>
<div class="input-wrapper">
<input name="staff_remove_files" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Přidat/odstranit spoiler</td>
<td>
<div class="input-wrapper">
<input name="staff_toggle_spoiler" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Připnout/odepnout</td>
<td>
<div class="input-wrapper">
<input name="toggle_sticky" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Uzamknout/odemknout</td>
<td>
<div class="input-wrapper">
<input name="toggle_lock" type="checkbox">
</div>
</td>
</tr>
{% endif %}
2023-12-25 13:53:44 +00:00
{% if tcx.perms.owner() || tcx.perms.bans() %}
2023-12-11 15:18:43 +00:00
<tr>
<td class="label">Zabanovat uživatele</td>
<td>
<div class="input-wrapper">
<input name="ban_user" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Globální ban</td>
<td>
<div class="input-wrapper">
<input name="global_ban" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Neodvolatelný ban</td>
<td>
<div class="input-wrapper">
<input name="unappealable_ban" type="checkbox">
</div>
</td>
</tr>
<tr>
<td class="label">Důvod banu</td>
<td><textarea name="ban_reason"></textarea></td>
</tr>
<tr>
<td class="label">Délka banu (dny)</td>
<td><input name="ban_duration" type="number" min="0" placeholder="0 = trvalý ban"></td>
</tr>
<tr>
<td class="label">Rozsah banu</td>
<td>
<select name="ban_range">
<option value="ip" selected="selected">IP adresa</option>
<option value="lan">LAN</option>
<option value="isp">ISP</option>
</select>
</td>
</tr>
{% endif %}
<tr>
<td class="submit" colspan="2">
<input
class="button"
type="submit"
formaction="/actions/staff-post-actions"
value="Odeslat"
>
</td>
</tr>
</table>
2023-12-25 13:53:44 +00:00
{% if tcx.perms.owner() || tcx.perms.edit_posts() %}
2023-12-11 15:18:43 +00:00
<table class="form-table">
<tr>
<td class="submit">
<input
class="button"
type="submit"
formaction="/edit-posts"
value="Upravit příspěvky"
>
</td>
</tr>
</table>
{% endif %}
</details>
{% endif %}
{% endmacro %}