mirror of
https://github.com/ae-utbm/sith.git
synced 2026-09-09 14:04:36 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
35a55ff95a
|
||
|
|
00cae33a33
|
||
|
|
4bfcb6a267
|
@@ -15,9 +15,6 @@
|
||||
{% endblock %}
|
||||
{% else %}
|
||||
{% extends "core/base.jinja" %}
|
||||
{% block additional_css %}
|
||||
<link rel="stylesheet" href="{{ static("club/list.scss") }}">
|
||||
{% endblock %}
|
||||
{% block description -%}
|
||||
{% trans %}The list of all clubs existing at UTBM.{% endtrans %}
|
||||
{%- endblock %}
|
||||
@@ -26,6 +23,12 @@
|
||||
{%- endblock %}
|
||||
{% endif %}
|
||||
|
||||
{% block additional_css %}
|
||||
{% if not is_fragment %}
|
||||
<link rel="stylesheet" href="{{ static("club/list.scss") }}">
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% from "core/macros.jinja" import paginate_htmx %}
|
||||
|
||||
{% block content %}
|
||||
@@ -33,15 +36,17 @@
|
||||
<h3>{% trans %}Filters{% endtrans %}</h3>
|
||||
<form
|
||||
id="club-list-filters"
|
||||
hx-get="{{ url("club:club_list") }}"
|
||||
method="GET"
|
||||
hx-action="{{ url("club:club_list") }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
hx-push-url="true"
|
||||
hx-disable="find input, find button"
|
||||
>
|
||||
<div class="row gap-4x">
|
||||
{{ form }}
|
||||
</div>
|
||||
<button type="submit" class="btn btn-blue margin-bottom">
|
||||
<button class="btn btn-blue margin-bottom">
|
||||
<i class="fa fa-magnifying-glass"></i>{% trans %}Search{% endtrans %}
|
||||
</button>
|
||||
</form>
|
||||
|
||||
@@ -62,6 +62,7 @@ document.body.addEventListener(
|
||||
},
|
||||
);
|
||||
|
||||
htmx.config.transitions = true;
|
||||
Object.assign(window, { htmx });
|
||||
|
||||
/**
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
{% if is_fragment %}
|
||||
hx-post="{{ action }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
{% endif %}
|
||||
>{% trans %}Confirm{% endtrans %}</button>
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
{% if is_fragment %}
|
||||
hx-get="{{ previous }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
{% else %}
|
||||
action="window.history.back()"
|
||||
{% endif %}
|
||||
|
||||
@@ -39,13 +39,13 @@
|
||||
<p><button
|
||||
hx-get="{{ url('core:file_moderate', file_id=f.id) }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
>{% trans %}Moderate{% endtrans %}</button> -
|
||||
{% set current_page = url('core:file_moderation') + "?page=" + page_obj.number | string %}
|
||||
<button
|
||||
hx-get="{{ url('core:file_delete', file_id=f.id) }}?next={{ current_page | urlencode }}&previous={{ current_page | urlencode }}"
|
||||
hx-target="#file-{{ loop.index }}"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
>{% trans %}Delete{% endtrans %}</button></p>
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
Reference in New Issue
Block a user